#21 Add PowerOFF when print is finished
This commit is contained in:
parent
5fe040d455
commit
330577cc6e
17
.idea/workspace.xml
generated
17
.idea/workspace.xml
generated
@ -4,6 +4,7 @@
|
|||||||
<list default="true" id="7e2e0eec-b22e-4d48-8f24-196d1ed9b51a" name="Default Changelist" comment="">
|
<list default="true" id="7e2e0eec-b22e-4d48-8f24-196d1ed9b51a" name="Default Changelist" comment="">
|
||||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/octoprint_mystromswitch/__init__.py" beforeDir="false" afterPath="$PROJECT_DIR$/octoprint_mystromswitch/__init__.py" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/octoprint_mystromswitch/__init__.py" beforeDir="false" afterPath="$PROJECT_DIR$/octoprint_mystromswitch/__init__.py" afterDir="false" />
|
||||||
|
<change beforePath="$PROJECT_DIR$/setup.py" beforeDir="false" afterPath="$PROJECT_DIR$/setup.py" afterDir="false" />
|
||||||
</list>
|
</list>
|
||||||
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
@ -48,13 +49,6 @@
|
|||||||
<option name="presentableId" value="Default" />
|
<option name="presentableId" value="Default" />
|
||||||
<updated>1574193087583</updated>
|
<updated>1574193087583</updated>
|
||||||
</task>
|
</task>
|
||||||
<task id="LOCAL-00047" summary="#14 Einstellungen reorganisieren">
|
|
||||||
<created>1574873790898</created>
|
|
||||||
<option name="number" value="00047" />
|
|
||||||
<option name="presentableId" value="LOCAL-00047" />
|
|
||||||
<option name="project" value="LOCAL" />
|
|
||||||
<updated>1574873790898</updated>
|
|
||||||
</task>
|
|
||||||
<task id="LOCAL-00048" summary="#14 Einstellungen reorganisieren">
|
<task id="LOCAL-00048" summary="#14 Einstellungen reorganisieren">
|
||||||
<created>1574873809876</created>
|
<created>1574873809876</created>
|
||||||
<option name="number" value="00048" />
|
<option name="number" value="00048" />
|
||||||
@ -391,7 +385,14 @@
|
|||||||
<option name="project" value="LOCAL" />
|
<option name="project" value="LOCAL" />
|
||||||
<updated>1593629609079</updated>
|
<updated>1593629609079</updated>
|
||||||
</task>
|
</task>
|
||||||
<option name="localTasksCounter" value="96" />
|
<task id="LOCAL-00096" summary="#21 Add PowerOFF when print is finished">
|
||||||
|
<created>1593630096392</created>
|
||||||
|
<option name="number" value="00096" />
|
||||||
|
<option name="presentableId" value="LOCAL-00096" />
|
||||||
|
<option name="project" value="LOCAL" />
|
||||||
|
<updated>1593630096392</updated>
|
||||||
|
</task>
|
||||||
|
<option name="localTasksCounter" value="97" />
|
||||||
<servers />
|
<servers />
|
||||||
</component>
|
</component>
|
||||||
<component name="UnknownFeatures">
|
<component name="UnknownFeatures">
|
||||||
|
@ -281,7 +281,6 @@ class MyStromSwitchPlugin(octoprint.plugin.SettingsPlugin,
|
|||||||
self.lastShutdown = self.shutdownAfterPrintFinished
|
self.lastShutdown = self.shutdownAfterPrintFinished
|
||||||
self._settings.set_boolean(["lastShutdown"], self.lastShutdown)
|
self._settings.set_boolean(["lastShutdown"], self.lastShutdown)
|
||||||
self._settings.save()
|
self._settings.save()
|
||||||
self._logger.info("lastShutdown2: %s" % self.lastShutdown)
|
|
||||||
elif command == "disableShutdownAfterFinish":
|
elif command == "disableShutdownAfterFinish":
|
||||||
self._logger.info("disableShutdownAfterFinish")
|
self._logger.info("disableShutdownAfterFinish")
|
||||||
self.shutdownAfterPrintFinished = False
|
self.shutdownAfterPrintFinished = False
|
||||||
@ -289,7 +288,6 @@ class MyStromSwitchPlugin(octoprint.plugin.SettingsPlugin,
|
|||||||
self.lastShutdown = self.shutdownAfterPrintFinished
|
self.lastShutdown = self.shutdownAfterPrintFinished
|
||||||
self._settings.set_boolean(["lastShutdown"], self.lastShutdown)
|
self._settings.set_boolean(["lastShutdown"], self.lastShutdown)
|
||||||
self._settings.save()
|
self._settings.save()
|
||||||
self._logger.info("lastShutdown2: %s" % self.lastShutdown)
|
|
||||||
elif command == "enablePowerOffAfterFinish":
|
elif command == "enablePowerOffAfterFinish":
|
||||||
self._logger.info("enablePowerOffAfterFinish")
|
self._logger.info("enablePowerOffAfterFinish")
|
||||||
self.powerOffAfterPrintFinished = True
|
self.powerOffAfterPrintFinished = True
|
||||||
@ -297,7 +295,6 @@ class MyStromSwitchPlugin(octoprint.plugin.SettingsPlugin,
|
|||||||
self.lastPowerOff = self.powerOffAfterPrintFinished
|
self.lastPowerOff = self.powerOffAfterPrintFinished
|
||||||
self._settings.set_boolean(["lastPowerOff"], self.lastPowerOff)
|
self._settings.set_boolean(["lastPowerOff"], self.lastPowerOff)
|
||||||
self._settings.save()
|
self._settings.save()
|
||||||
self._logger.info("lastPowerOff2: %s" % self.lastPowerOff)
|
|
||||||
elif command == "disablePowerOffAfterFinish":
|
elif command == "disablePowerOffAfterFinish":
|
||||||
self._logger.info("disablePowerOffAfterFinish")
|
self._logger.info("disablePowerOffAfterFinish")
|
||||||
self.powerOffAfterPrintFinished = False
|
self.powerOffAfterPrintFinished = False
|
||||||
@ -305,7 +302,6 @@ class MyStromSwitchPlugin(octoprint.plugin.SettingsPlugin,
|
|||||||
self.lastPowerOff = self.powerOffAfterPrintFinished
|
self.lastPowerOff = self.powerOffAfterPrintFinished
|
||||||
self._settings.set_boolean(["lastPowerOff"], self.lastPowerOff)
|
self._settings.set_boolean(["lastPowerOff"], self.lastPowerOff)
|
||||||
self._settings.save()
|
self._settings.save()
|
||||||
self._logger.info("lastPowerOff2: %s" % self.lastPowerOff)
|
|
||||||
|
|
||||||
def get_api_commands(self):
|
def get_api_commands(self):
|
||||||
return dict(
|
return dict(
|
||||||
|
2
setup.py
2
setup.py
@ -14,7 +14,7 @@ plugin_package = "octoprint_mystromswitch"
|
|||||||
plugin_name = "OctoPrint-MyStromSwitch"
|
plugin_name = "OctoPrint-MyStromSwitch"
|
||||||
|
|
||||||
# The plugin's version. Can be overwritten within OctoPrint's internal data via __plugin_version__ in the plugin module
|
# The plugin's version. Can be overwritten within OctoPrint's internal data via __plugin_version__ in the plugin module
|
||||||
plugin_version = "1.0.3"
|
plugin_version = "1.0.4"
|
||||||
|
|
||||||
# The plugin's description. Can be overwritten within OctoPrint's internal data via __plugin_description__ in the plugin
|
# The plugin's description. Can be overwritten within OctoPrint's internal data via __plugin_description__ in the plugin
|
||||||
# module
|
# module
|
||||||
|
Loading…
Reference in New Issue
Block a user