def get_status_string():
with thermostatLock:
sched = "None"
if holdControl.state == "down":
sched = "Hold"
elif useTestSchedule:
sched = "Test"
elif heatControl.state == "down":
sched = "Heat"
elif coolControl.state == "down":
sched = "Cool"
return "[b]System:[/b]\n " + \
"Heat: " + ( "[color=00ff00][b]On[/b][/color]" if GPIO.input( heatPin ) else "Off" ) + "\n " + \
"Cool: " + ( "[color=00ff00][b]On[/b][/color]" if GPIO.input( coolPin ) else "Off" ) + "\n " + \
"Fan: " + ( "[color=00ff00][b]On[/b][/color]" if GPIO.input( fanPin ) else "Auto" ) + "\n " + \
"Sched: " + sched
评论列表
文章目录