Update xdrv_12_discovery.ino

This commit is contained in:
Theo Arends 2022-06-10 10:58:32 +02:00
parent c6f51b8ca3
commit baf68fcf6e
1 changed files with 8 additions and 1 deletions

View File

@ -256,6 +256,13 @@ void TasDiscoverInit(void) {
}
}
/*********************************************************************************************\
* Stubs replacing legacy Hass discovery
\*********************************************************************************************/
void HAssPublishStatus(void) { return; }
void HAssDiscover(void) { TasRediscover(); }
/*********************************************************************************************\
* Commands
*
@ -281,7 +288,7 @@ void (* const TasDiscoverCommand[])(void) PROGMEM = {
void CmndTasDiscover(void) {
if (XdrvMailbox.payload >= 0) {
Settings->flag.hass_discovery = !(XdrvMailbox.payload & 1);
Settings->flag.hass_discovery = !(XdrvMailbox.payload & 1); // SetOption19 - Tasmota discovery (0)
TasRediscover();
}
ResponseCmndChar(GetStateText(!Settings->flag.hass_discovery));