Mercurial > templog
comparison py/sensor_ds18b20.py @ 565:26f20cee71be
emergency change sensor config
add --nowait.
make only look for 28- devices (ds18b20)
author | Matt Johnston <matt@ucc.asn.au> |
---|---|
date | Sun, 05 Jul 2015 00:44:05 +0800 |
parents | c5f8375b12a2 |
children | 97d99eb42d27 |
comparison
equal
deleted
inserted
replaced
564:59cb8449ef97 | 565:26f20cee71be |
---|---|
86 contents = f.read() | 86 contents = f.read() |
87 if 'not found' in contents: | 87 if 'not found' in contents: |
88 E("No W1 sensors found") | 88 E("No W1 sensors found") |
89 return [] | 89 return [] |
90 names = contents.split() | 90 names = contents.split() |
91 # only ds18b20 | |
92 names = [n for n in names if n.startswith('28-')] | |
91 return names | 93 return names |
92 | 94 |
93 def wort_name(self): | 95 def wort_name(self): |
94 return config.WORT_NAME | 96 return config.WORT_NAME |
95 | 97 |