thermferm/server.c

changeset 582
ba340e00aab2
parent 578
d694abd9d809
child 583
9795a16de807
--- a/thermferm/server.c	Sun Mar 31 13:57:25 2019 +0200
+++ b/thermferm/server.c	Sat Apr 27 15:36:16 2019 +0200
@@ -1699,7 +1699,7 @@
 	unit->air_temperature = unit->beer_temperature = unit->chiller_temperature = 20000;
 	unit->beer_set_lo = unit->beer_set_hi = unit->fridge_set_lo = unit->fridge_set_hi = unit->profile_inittemp_lo = unit->profile_inittemp_hi =20.0;
 	unit->heater_state = unit->cooler_state = unit->fan_state = unit->door_state = unit->mode = \
-			     unit->light_state = unit->psu_state = unit->prof_state = unit->stage = 0;
+			     unit->light_state = unit->light_timer = unit->psu_state = unit->prof_state = unit->stage = 0;
 	unit->heater_delay = unit->cooler_delay = unit->fan_delay = 20;	/* 5 minutes delay	*/
 	unit->light_delay = 1;						/* 15 seconds delay	*/
 	unit->heater_wait = unit->cooler_wait = unit->fan_wait = unit->light_wait = 0;
@@ -2205,7 +2205,7 @@
 					/* Allways turn everything off after a mode change */
 					unit->PID_cool->OutP = unit->PID_heat->OutP = 0.0;
 					unit->PID_cool->Mode = unit->PID_heat->Mode = PID_MODE_NONE;
-					unit->heater_state = unit->cooler_state = unit->fan_state = unit->light_state = 0;
+					unit->heater_state = unit->cooler_state = unit->fan_state = unit->light_state = unit->light_timer = 0;
 					unit->heater_wait = unit->cooler_wait = unit->fan_wait = unit->light_wait = 0;
 					device_out(unit->heater_address, unit->heater_state);
 					device_out(unit->cooler_address, unit->cooler_state);

mercurial