Skip to content

Commit

Permalink
1.1.4 (#207)
Browse files Browse the repository at this point in the history
* update to plotly.js v2.8.3
* add heaters to ignore for idle timeout processing, #202
* fix ignored heaters split logic, #206
  • Loading branch information
jneilliii authored May 27, 2024
1 parent bdd4db6 commit f9ab913
Show file tree
Hide file tree
Showing 4 changed files with 75 additions and 7 deletions.
8 changes: 5 additions & 3 deletions octoprint_tasmota/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,7 @@ def get_settings_defaults(self):
"powerOffWhenIdle": False,
"idleTimeout": 30,
"idleIgnoreCommands": 'M105',
"idleIgnoreHeaters": '',
"idleTimeoutWaitTemp": 50,
"idleWaitForTimelapse": True,
"event_on_upload_monitoring": False,
Expand Down Expand Up @@ -980,11 +981,12 @@ def _wait_for_timelapse(self):
def _wait_for_heaters(self):
self._waitForHeaters = True
heaters = self._printer.get_current_temperatures()
ignored_heaters = [heater.strip() for heater in self._settings.get(["idleIgnoreHeaters"]).split(',')]

for heater, entry in heaters.items():
target = entry.get("target")
if target is None:
# heater doesn't exist in fw
if target is None or heater in ignored_heaters:
# heater doesn't exist in fw or set to be ignored
continue

try:
Expand All @@ -1010,7 +1012,7 @@ def _wait_for_heaters(self):
highest_temp = 0
heaters_above_waittemp = []
for heater, entry in heaters.items():
if not heater.startswith("tool"):
if not heater.startswith("tool") or heater in ignored_heaters:
continue

actual = entry.get("actual")
Expand Down
64 changes: 61 additions & 3 deletions octoprint_tasmota/static/js/plotly-latest.min.js

Large diffs are not rendered by default.

8 changes: 8 additions & 0 deletions octoprint_tasmota/templates/tasmota_settings.jinja2
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,14 @@
</div>
</div>
</div>
<div class="row-fluid" data-bind="visible: settings.settings.plugins.tasmota.powerOffWhenIdle()">
<div class="control-group">
<label class="control-label">{{ _('Heaters to Ignore for Idle') }}</label>
<div class="controls" data-toggle="tooltip" data-bind="tooltip: {}" title="{{ _('Comma separated list of heaters to ignore for idle temperature. ie, for Prusa MK4 include X.') }}">
<input type="text" class="input-block-level" data-bind="value: settings.settings.plugins.tasmota.idleIgnoreHeaters, enable: settings.settings.plugins.tasmota.powerOffWhenIdle()" disabled />
</div>
</div>
</div>
<div class="row-fluid" data-bind="visible: settings.settings.plugins.tasmota.powerOffWhenIdle()">
<div class="control-group">
<div class="controls">
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
plugin_name = "OctoPrint-Tasmota"

# The plugin's version. Can be overwritten within OctoPrint's internal data via __plugin_version__ in the plugin module
plugin_version = "1.1.3"
plugin_version = "1.1.4"

# The plugin's description. Can be overwritten within OctoPrint's internal data via __plugin_description__ in the plugin
# module
Expand Down

0 comments on commit f9ab913

Please sign in to comment.