comparison py/sensor_ds18b20.py @ 266:20c89630be6c

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 26eee8591f61
children 97d99eb42d27
comparison
equal deleted inserted replaced
265:78c542f03030 266:20c89630be6c
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