mirror of
https://github.com/arendst/Tasmota.git
synced 2025-07-27 04:36:31 +00:00
[Thermostat] Save and restore XdrvMailbox if output relay is switched off (#20405)
This commit is contained in:
parent
fa959d9f47
commit
345de0aded
@ -1442,7 +1442,9 @@ void CmndThermostatModeSet(void)
|
|||||||
// Make sure the relay is switched to off once if the thermostat is being disabled,
|
// Make sure the relay is switched to off once if the thermostat is being disabled,
|
||||||
// or it will get stuck on (danger!)
|
// or it will get stuck on (danger!)
|
||||||
Thermostat[ctr_output].status.command_output = IFACE_OFF;
|
Thermostat[ctr_output].status.command_output = IFACE_OFF;
|
||||||
|
struct XDRVMAILBOX save_XdrvMailbox = XdrvMailbox;
|
||||||
ThermostatOutputRelay(ctr_output, Thermostat[ctr_output].status.command_output);
|
ThermostatOutputRelay(ctr_output, Thermostat[ctr_output].status.command_output);
|
||||||
|
XdrvMailbox = save_XdrvMailbox;
|
||||||
}
|
}
|
||||||
if ((value > THERMOSTAT_OFF) && (value < THERMOSTAT_MODES_MAX)) {
|
if ((value > THERMOSTAT_OFF) && (value < THERMOSTAT_MODES_MAX)) {
|
||||||
DebugControllerParameters(ctr_output);
|
DebugControllerParameters(ctr_output);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user