Fix settings opener config; add confguring sound level

This commit is contained in:
technyon
2022-07-17 10:32:16 +02:00
parent 043cedc790
commit 65a649b9c1
4 changed files with 19 additions and 9 deletions

View File

@@ -260,6 +260,13 @@ void NukiOpenerWrapper::onConfigUpdateReceived(const char *topic, const char *va
_nukiOpener.enableLedFlash(newValue);
_nextConfigUpdateTs = millis() + 300;
}
if(strcmp(topic, mqtt_topic_config_sound_level) == 0)
{
uint8_t newValue = atoi(value);
if(!_nukiAdvancedConfigValid || _nukiAdvancedConfig.soundLevel == newValue) return;
_nukiOpener.setSoundLevel(newValue);
_nextConfigUpdateTs = millis() + 300;
}
}
const NukiOpener::OpenerState &NukiOpenerWrapper::keyTurnerState()