alexverrico / octoprint-thermalrunaway Goto Github PK
View Code? Open in Web Editor NEWOctoprint plugin to provide some basic thermal runaway protection
License: GNU Affero General Public License v3.0
Octoprint plugin to provide some basic thermal runaway protection
License: GNU Affero General Public License v3.0
Describe the bug
Sends M112 kill signal when first connecting to the printer, if the nozzle is already hot before the printer was reset. Sometimes this happens even if the nozzle was not previously hot.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Should be able to heat the hotend and nozzle and print things even if a previous attempted print failed.
Environment information:
Additional context
Temperature is always decreasing when connecting to a machine that was previously heated; the code should detect this when recently connected and not trigger a runaway. There is a setting called "Maximum temp that the hotend is allowed to reach while turned off before triggering a Thermal Runaway" but surely it's not reasonable to set that to 200C? This bug never occurs when heating the bed, only when heating the nozzle.
If I have this plugin enabled and reconnect octoprint to a printer that is already hot, the plugin triggers an emergency kill after less than 2 seconds. I have to wait for the printer to completely cool down or disable the plugin to be able to reconnect the printer.
Describe the bug
for the text:
Maximum amount that the bed / hotend temp is allowed to differ from the set temp before triggering a Thermal Runaway:
I assume you mean to say higher in stead of differ? Because lower is obvious when initiating a print and it wouldn't be a thermal runaway.
So than the text should be: "is allowed to be higher than the set temperature"
To Reproduce
Steps to reproduce the behavior:
Expected behavior
So than the text should be: "is allowed to be higher than the set temperature"
Sorry for nitpicking ;-)
Is your feature request related to a problem? Please describe.
Would like to improve response to possible thermal runaway event.
Describe the solution you'd like
Would like the ability to call an external script and/or system command when thermal runaway is detected. Currently, the response of sending M112 can do nothing if something like a MOSFET failure has occurred.
In my specific case I would want to curl to call an external URL that triggers a notification and kills power to the printer with an external switch.
Would prefer that it not require another plugin to intercept the gcode, as it's not clear if that would work reliably if there are comms issues with the printer.
Describe alternatives you've considered
GCODE System Commands
Additional context
N/A
Plugin does not work for me (OctoPrint 1.4.0 running on OctoPi 0.17.0) Get a lightning bolt in the plugin manager that says the plugin is invalid.
Describe the bug
On hot summer days without AC, the room with my printer can exceed 30 degrees C without issue. Octopi then disconnects shortly after connecting and I see some variation of:
Send: M112
Send: N3 M112*34
Send: N4 M104 T0 S0*37
Send: N5 M140 S0*96
Closing serial port due to emergency stop M112.
Where the first and final messages are always the same
To Reproduce
Steps to reproduce the behavior:
Expected behavior
I expect no issues with octopi and printing, or a message to indicate that this add-on is what sent the emergency stop command.
Screenshots
None
Environment information:
Additional context
I understand that increasing the allowable temperatures in the thermal-runaway add-on will fix this, but there is not any message in the terminal indicating that it was the thermal-runaway add-on that was causing the issue. Can there at least be a message in terminal indicating the reason for the emergency stop? I've had everything running for quite some time without any issues so it was hard to pinpoint why suddenly the system was no longer working.
Describe the bug
I've got 2 printers on marlin running by octoprint. Both printers have this issue.
Settings Octoprint, see picture. One of the printers is set to the 'new' settings, the other to the 'old' settings (check box bottom page). Thanks for the great plugin!
To Reproduce
Steps to reproduce the behavior:
Expected behavior
When the printer is paused, the 'state' of the printer is changed from 'Printing' to something like 'Paused for user'. When state is not printing, it is ok for me that only the 'maxtemp' is triggering a thermal runaway. Not a cooldown from the hotend. I expect that the thermal runaway for this plugin is triggered because the set temp is still showing 200c.
Screenshots
See settings below in picture.
Environment information:
Additional context
Add any other context about the problem here.
Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Describe the solution you'd like
A clear and concise description of what you want to happen.
Add error message, ideally in terminal, that lets the user know why the emergency gcode was sent
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Thanks @bjenkins2009 for suggesting this
Describe the bug
M112 is sent due to a warning a day before.
What happened
When i start my printer together with the raspberry pi, the printer sometimes stops after 20 seconds with M112. Octoprints log shows the following:
Log-File
###Log 2022-02-16
2022-02-16 21:55:44,118 - octoprint.plugins.ThermalRunaway - WARNING - B temperature is now too low, (low=20.62, current=20.62, set=64.0)
2022-02-16 21:55:44,118 - octoprint.plugins.ThermalRunaway - WARNING - T0 temperature is now too low, (low=20.62, current=20.62, set=120.0)
2022-02-16 21:55:44,386 - octoprint.plugins.continuousprint - INFO - Initialized
2022-02-16 21:55:44,387 - octoprint.plugins.continuousprint - INFO - Retry on pause: False (max_retries 3, threshold 3600s)
2022-02-16 21:55:44,388 - octoprint.plugins.continuousprint - INFO - Continuous Print Plugin started
2022-02-16 21:55:44,388 - octoprint.plugins.detailedprogress - INFO - OctoPrint-DetailedProgress loaded!
2022-02-16 21:55:44,388 - octoprint.plugins.draggable_files - INFO - Hello World!
2022-02-16 21:55:44,389 - octoprint.plugins.stats - INFO - Printer Stats
2022-02-16 21:55:44,471 - octoprint.plugins.pluginmanager - INFO - Loaded notice data from disk, was still valid
2022-02-16 21:55:44,846 - octoprint.plugins.toptemp - INFO - TopTemp is initialized
2022-02-16 21:55:45,258 - octoprint.server.preemptive_cache - INFO - Preemptively caching / (ui _default) for {'base_url': 'http://octopi.local/', 'path': '/', 'query_string': 'l10n=de'}
2022-02-16 21:55:46,095 - octoprint.plugins.ThermalRunaway - WARNING - B temperature has been too low for 1.9770498275756836 seconds, (low=20.62, current=20.62, set=64.0)
2022-02-16 21:55:46,096 - octoprint.plugins.ThermalRunaway - INFO - T0 temperature is no longer too low after 1.9771485328674316 seconds, (low=20.62, current=21.87, set=120.0)
###Log 2022-02-17
2022-02-17 16:31:55,480 - octoprint.server.heartbeat - INFO - Server heartbeat <3
2022-02-17 16:31:56,656 - octoprint.plugins.ThermalRunaway - WARNING - B temperature has been too low for 66972.53778862953 seconds, (low=20.62, current=20.62, set=64.0)
2022-02-17 16:31:56,657 - octoprint.util.comm - INFO - Force-sending M112 to the printer
Note
M112 is sent because B-temp was low for 66972 seconds (13 h). So something is not cleared before shutdown.
Environment information:
Maybe it's me...
Installed the plug-in, refreshed the octoprint interface as instructed, but I can't seem to be able to find the plug-in settings to set the proper temp and time limits anywhere. Don't see anything regarding the issue on the readme, either.
Thank for any help.
Describe the bug
TypeError: not all arguments converted during string formatting
To Reproduce
Steps to reproduce the behavior:
Launch the docker container...
Expected behavior
A clear and concise description of what you expected to happen.
Screenshots
If applicable, add screenshots to help explain your problem.
Environment information:
Additional context
octoprint | 2021-01-21T11:21:59.852656992Z Exception in thread Thread-1919:
octoprint | 2021-01-21T11:21:59.852689509Z Traceback (most recent call last):
octoprint | 2021-01-21T11:21:59.852706312Z File "/usr/local/lib/python3.8/threading.py", line 932, in _bootstrap_inner
octoprint | 2021-01-21T11:21:59.852713219Z self.run()
octoprint | 2021-01-21T11:21:59.852726535Z File "/usr/local/lib/python3.8/site-packages/sentry_sdk/integrations/threading.py", line 69, in run
octoprint | 2021-01-21T11:21:59.852733659Z reraise(*_capture_exception())
octoprint | 2021-01-21T11:21:59.852739667Z File "/usr/local/lib/python3.8/site-packages/sentry_sdk/_compat.py", line 54, in reraise
octoprint | 2021-01-21T11:21:59.852746278Z raise value
octoprint | 2021-01-21T11:21:59.852763286Z File "/usr/local/lib/python3.8/site-packages/sentry_sdk/integrations/threading.py", line 67, in run
octoprint | 2021-01-21T11:21:59.852769821Z return old_run_func(self, *a, **kw)
octoprint | 2021-01-21T11:21:59.852775401Z File "/usr/local/lib/python3.8/threading.py", line 1254, in run
octoprint | 2021-01-21T11:21:59.852781282Z self.function(*self.args, **self.kwargs)
octoprint | 2021-01-21T11:21:59.852787031Z File "/octoprint/plugins/lib/python3.8/site-packages/octoprint_ThermalRunaway/__init__.py", line 130, in check_temps
octoprint | 2021-01-21T11:21:59.852792662Z _logger.debug('bTemps: %s' % bTemps)
octoprint | 2021-01-21T11:21:59.852798340Z TypeError: not all arguments converted during string formatting
Describe the bug
Printer gets M112 shutdown command some seconds after print job started
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Print job will be performed
Screenshots
Output from Octoprint.log:
2021-05-16 20:21:40,905 - octoprint.plugins.detailedprogress - INFO - Printing started. Detailed progress started.
2021-05-16 20:21:40,948 - octoprint.plugins.action_command_notification - INFO - Got a notification: Bed Heating...
2021-05-16 20:21:41,952 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:42,600 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:42,944 - octoprint.util.comm - INFO - Printer seems to support the busy protocol, will adjust timeouts and set busy interval accordingly
2021-05-16 20:21:42,952 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:43,953 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:44,601 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:44,952 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:45,953 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:46,601 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:46,953 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:47,954 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:48,607 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:48,953 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:49,954 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:50,601 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:50,912 - octoprint.plugins.detailedprogress - INFO - Message: Good accuracy
2021-05-16 20:21:50,953 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:51,954 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:52,601 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:52,958 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:53,961 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:54,602 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:54,958 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:55,961 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:56,602 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:56,958 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:57,958 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:58,600 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:58,958 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:21:59,960 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:22:00,602 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:22:00,915 - octoprint.plugins.detailedprogress - INFO - Message: Good accuracy
2021-05-16 20:22:00,958 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:22:01,958 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:22:02,602 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:22:02,958 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount == 1 for B
2021-05-16 20:22:03,958 - octoprint.plugins.ThermalRunaway - WARNING - thermalLowCount > 2 for B
2021-05-16 20:22:03,959 - octoprint.util.comm - INFO - Force-sending M112 to the printer
2021-05-16 20:22:03,992 - octoprint.util.comm - INFO - Changing monitoring state from "Printing" to "Offline after error"
2021-05-16 20:22:04,002 - octoprint.plugins.ThermalRunaway - CRITICAL - Thermal Runaway (under temp) caught on heater B. Reported temp is 34.17, set temp is 60.0
Environment information:
Additional context
Mega Zero V2.0 with SKR mini mz, BLTouch and BTT Smart Filament Sensor
Prusa MK3S on 3.10.0 firmware (but this occurred on 3.8.1 as well, so doesnt seem FW related)
Octoprint debug log mentions:
2021-05-18 15:20:33,041 - octoprint.plugins.ThermalRunaway - WARNING - thermalHighCount > 2 for T0
2021-05-18 15:20:33,042 - octoprint.util.comm - INFO - Force-sending M112 to the printer
But the printer was cooling down, observe:
Recv: T:151.8 /0.0 B:49.8 /0.0 T0:151.8 /0.0 @:0 B@:0 P:43.6 A:32.1
Recv: T:150.8 /0.0 B:49.5 /0.0 T0:150.8 /0.0 @:0 B@:0 P:33.1 A:32.1
Recv: T:149.9 /0.0 B:49.5 /0.0 T0:149.9 /0.0 @:0 B@:0 P:32.1 A:32.2
Recv: T:149.2 /0.0 B:49.2 /0.0 T0:149.2 /0.0 @:0 B@:0 P:32.0 A:32.0
Recv: T:148.4 /0.0 B:48.9 /0.0 T0:148.4 /0.0 @:0 B@:0 P:32.0 A:32.0
Recv: T:147.7 /0.0 B:49.0 /0.0 T0:147.7 /0.0 @:0 B@:0 P:31.9 A:31.9
Recv: T:146.9 /0.0 B:48.9 /0.0 T0:146.9 /0.0 @:0 B@:0 P:31.9 A:32.2
Recv: T:146.0 /0.0 B:48.8 /0.0 T0:146.0 /0.0 @:0 B@:0 P:31.9 A:32.0
Recv: T:145.3 /0.0 B:48.4 /0.0 T0:145.3 /0.0 @:0 B@:0 P:31.9 A:32.0
Recv: T:144.5 /0.0 B:48.2 /0.0 T0:144.5 /0.0 @:0 B@:0 P:31.9 A:32.2
Recv: T:143.6 /0.0 B:48.3 /0.0 T0:143.6 /0.0 @:0 B@:0 P:31.9 A:31.9
Send: M112
Send: N2 M112*35
Send: N3 M104 T0 S0*34
Send: N4 M140 S0*97
Recv: KILL: 2
Recv: Error:Printer halted. kill() called!
Changing monitoring state from "Operational" to "Error"
Send: M112
Closing serial port due to emergency stop M112.
Send: N5 M112*36
Send: N6 M104 T0 S0*39
Send: N7 M140 S0*98
Connection closed, closing down monitor
Changing monitoring state from "Error" to "Offline after error"
My thermistor is fine, and the printer/octoprint operate normally without the plugin installed.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.