#6 UI Updates senden und anzeigen

This commit is contained in:
David Zingg 2019-11-20 21:41:44 +01:00
parent e5f0310ab2
commit 2793457393

View File

@ -49,7 +49,8 @@ class MyStromSwitchPlugin(octoprint.plugin.SettingsPlugin,
self._logger.info(self.ip)
self._logger.info(self.intervall)
self._logger.info("Starting timer.")
if self.intervall >= 1 and self.ip is not None:
self._logger.info("Starting timer")
self._timer = RepeatedTimer(self.intervall, self._timer_task)
self._timer.start()
@ -75,6 +76,10 @@ class MyStromSwitchPlugin(octoprint.plugin.SettingsPlugin,
def on_shutdown(self):
self._logger.info("Hello World!")
def on_settings_load(self):
self._logger.info("on_settings_load")
self.initialize()
def on_settings_initialized(self):
self._logger.info("on_settings_initialized")
self.initialize()