Sida 1 av 1
Läsa temp direkt för 1-wire enheter med w1_therm
Postat: 04 jan 2011, 14:32
av mikaelogren
Jag köpte nyligen ett 1-wiresystem med en USB-master. Det strulade för mig med digitemp, så jag surfade runt och upptäckte att det ju går att köra direkt med modulen
w1_therm... Skrev några rader på Wiki:n
http://wiki.temperatur.nu/index.php/W1_therm.
Vet någon varför det spottar ur sig två temperaturer från varje givare?
Mikael
Re: Läsa temp direkt för 1-wire enheter med w1_therm
Postat: 29 jun 2011, 12:50
av ladekribs
här kan du läsa svaret:
http://www.kernel.org/doc/Documentation ... s/w1_therm
Support is provided through the sysfs w1_slave file. Each open and
read sequence will initiate a temperature conversion then provide two
lines of ASCII output. The first line contains the nine hex bytes
read along with a calculated crc value and YES or NO if it matched.
If the crc matched the returned values are retained. The second line
displays the retained values along with a temperature in millidegrees
Centigrade after t=.
MVH Stefan