Extent command Knx_Enabled with KNX restart functionality (#22242)

This commit is contained in:
Theo Arends 2024-12-06 17:40:05 +01:00
parent 4ffc53b465
commit 789bbb8b97
1 changed files with 3 additions and 0 deletions

View File

@ -1422,6 +1422,9 @@ void CmndKnxEnabled(void)
{ {
if ((XdrvMailbox.payload >= 0) && (XdrvMailbox.payload <= 1)) { if ((XdrvMailbox.payload >= 0) && (XdrvMailbox.payload <= 1)) {
Settings->flag.knx_enabled = XdrvMailbox.payload; Settings->flag.knx_enabled = XdrvMailbox.payload;
if (!Settings->flag.knx_enabled) {
Knx.started = false;
}
} }
ResponseCmndChar (GetStateText(Settings->flag.knx_enabled) ); ResponseCmndChar (GetStateText(Settings->flag.knx_enabled) );
} }