chill wrote: 
> I've tweaked the python script to make it slightly easier to use a
> separate config file under pCP.

Thank you very much. I changed the description accordingly.
I hope everything can be understand, because English is not my native
language.

chill wrote: 
> If I knew anything about python I'd have a go at making it re-load this
> 'argononed.conf' file every time it checks the temperature

I also don't know python, but I would make it the following way:

Code:
--------------------
        while True:
                temp = os.popen("vcgencmd measure_temp").readline()
                temp = temp.replace("temp=","")
                val = float(temp.replace("'C",""))
                fanconfig = load_config("/home/tc/argononed.conf")
                block = get_fanspeed(val, fanconfig)
                if block < prevblock:
                        time.sleep(30)
                prevblock = block
                try:
                        bus.write_byte(address,block)
                except IOError:
                        temp=""
                time.sleep(30)
  
--------------------


But I don't know what happens to the performance then, because every 30
seconds the file has to be opened, read and closed.
You can try it. :-)



pi4 4gb picoreplayer with lms and squeezelite for usb inside an argon
one case
pi3b+ (7\" display, hifiberry dac+ pro) picoreplayer with
squeezlite/jivelite for hifiberry and bluetooth headphone inside a
smartipi touch case
two airport express
ikea symfonisk
------------------------------------------------------------------------
carsten_h's Profile: http://forums.slimdevices.com/member.php?userid=69113
View this thread: http://forums.slimdevices.com/showthread.php?t=113575

_______________________________________________
unix mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/unix

Reply via email to