Filament Sensor to Pause Print Results in NO ACTION. #383

Open
opened 2021-01-05 03:30:32 +00:00 by Cortexian · 3 comments
Cortexian commented 2021-01-05 03:30:32 +00:00 (Migrated from github.com)

I have a Creality Ender 5 Plus. Using the latest Kersey Fabrications firmware, basically the stock Creality firmware but with a fixed probe offset...

To Reproduce
Steps to reproduce the behavior:

  1. Start Print.
  2. Run out of filament.
  3. Filament sensor falls (verified detected using your troubleshooting python script).
  4. Print continues.
  5. Print never pauses.

Expected behavior
Print pauses, as configured, when filament sensor falls. Then runs the "After print is paused" script in the Octoprint settings.

Additional context
Here's some configuration info:
trimmed-octoprint.log

"After print job is cancelled" script (from Octoprint examples):

{% if pause_position.x is not none %}
; relative XYZE
G91
M83

; retract filament, move Z slightly upwards
G1 Z+5 E-5 F4500

; absolute XYZE
M82
G90

; move to a safe rest position, adjust as necessary
G1 X175 Y350
{% endif %}

"Before print job is resumed" script (also from Octoprint documentation examples):

{% if pause_position.x is not none %}
; relative extruder
M83

; prime nozzle
G1 E-5 F4500
G1 E5 F4500
G1 E5 F4500

; absolute E
M82

; absolute XYZ
G90

; reset E
G92 E{{ pause_position.e }}

; move back to pause position XYZ
G1 X{{ pause_position.x }} Y{{ pause_position.y }} Z{{ pause_position.z }} F4500

; reset to feed rate before pause if available
{% if pause_position.f is not none %}G1 F{{ pause_position.f }}{% endif %}
{% endif %}

enclosure-advanced1
enclosure-advanced2
enclosure-input

I'm using the stock Ender 5 Plus filament sensor. The weird thing is that when I first set this up (without GCODE scripts), the print paused perfectly (just froze in place, which I didn't like, hence the scripts).

It's 100% detecting the filament runout every time I remove it from the sensor manually while running the troubleshooting python script:
troubleshooting_python_script

I have a Creality Ender 5 Plus. Using the latest Kersey Fabrications firmware, basically the stock Creality firmware but with a fixed probe offset... **To Reproduce** Steps to reproduce the behavior: 1. Start Print. 2. Run out of filament. 3. Filament sensor falls (verified detected using your troubleshooting python script). 4. Print continues. 5. Print never pauses. **Expected behavior** Print pauses, as configured, when filament sensor falls. Then runs the "After print is paused" script in the Octoprint settings. **Additional context** Here's some configuration info: [trimmed-octoprint.log](https://github.com/vitormhenrique/OctoPrint-Enclosure/files/5767930/trimmed-octoprint.log) "After print job is cancelled" script (from Octoprint examples): >{% if pause_position.x is not none %} >; relative XYZE >G91 >M83 > >; retract filament, move Z slightly upwards >G1 Z+5 E-5 F4500 > >; absolute XYZE >M82 >G90 > >; move to a safe rest position, adjust as necessary >G1 X175 Y350 >{% endif %} "Before print job is resumed" script (also from Octoprint documentation examples): >{% if pause_position.x is not none %} >; relative extruder >M83 > >; prime nozzle >G1 E-5 F4500 >G1 E5 F4500 >G1 E5 F4500 > >; absolute E >M82 > >; absolute XYZ >G90 > >; reset E >G92 E{{ pause_position.e }} > >; move back to pause position XYZ >G1 X{{ pause_position.x }} Y{{ pause_position.y }} Z{{ pause_position.z }} F4500 > >; reset to feed rate before pause if available >{% if pause_position.f is not none %}G1 F{{ pause_position.f }}{% endif %} >{% endif %} ![enclosure-advanced1](https://user-images.githubusercontent.com/76460985/103603153-24f07c80-4ecb-11eb-8903-8afa0fa28ca8.jpg) ![enclosure-advanced2](https://user-images.githubusercontent.com/76460985/103603154-25891300-4ecb-11eb-904d-ace9a65372fe.jpg) ![enclosure-input](https://user-images.githubusercontent.com/76460985/103603155-25891300-4ecb-11eb-9fa5-19b155f8f1fa.jpg) I'm using the stock Ender 5 Plus filament sensor. The weird thing is that when I first set this up (without GCODE scripts), the print paused perfectly (just froze in place, which I didn't like, hence the scripts). It's 100% detecting the filament runout every time I remove it from the sensor manually while running the troubleshooting python script: ![troubleshooting_python_script](https://user-images.githubusercontent.com/76460985/103603322-96302f80-4ecb-11eb-9d24-41101b1c0a9e.jpg)
Cortexian commented 2021-01-06 09:18:28 +00:00 (Migrated from github.com)

Update: The sensor is definitely working. I redid all my wiring connections today with correct DuPont connectors to attach to the GPIO pins. I'm getting emails from IFTTT when I do filament changes.

Pause just isn't triggering for some reason.

Update: The sensor is definitely working. I redid all my wiring connections today with correct DuPont connectors to attach to the GPIO pins. I'm getting emails from IFTTT when I do filament changes. Pause just isn't triggering for some reason.
vitormhenrique commented 2021-01-11 06:06:15 +00:00 (Migrated from github.com)

I'm working on a new verison of the plugin with python 3 compatibility and better logging etc, we will need that in order to get some logging and see if the plugin is sending commands to the printer. If it is and the printer is not responding there is no much I can do.
Because of the major refactor for python 3 I'm not going to support this legacy python 2 plugin anymore, and the new version will include better configuration interface and embedded libraries for temperature sensors etc...
Unfortunately it's a balance of how much I can code a day with my day job, masters and other projects, so for now I would recommend either you trying to add some logs on the source code and debug or wait for a new release in a few months.

I'm working on a new verison of the plugin with python 3 compatibility and better logging etc, we will need that in order to get some logging and see if the plugin is sending commands to the printer. If it is and the printer is not responding there is no much I can do. Because of the major refactor for python 3 I'm not going to support this legacy python 2 plugin anymore, and the new version will include better configuration interface and embedded libraries for temperature sensors etc... Unfortunately it's a balance of how much I can code a day with my day job, masters and other projects, so for now I would recommend either you trying to add some logs on the source code and debug or wait for a new release in a few months.
mockendon commented 2021-01-13 12:37:51 +00:00 (Migrated from github.com)

Thank you for your hard work on this - a key part of the Octoprint functionality. UnfortunatelyI have the same issue. I have set up scripts in octoprint that handle pause and resume very well. I would like my filament sensor to trigger an octoprint 'pause' just like pressing the pause button and my options are set exactly as above. Like Cortexian nothing happens when the sensor triggers in this configuration.

In this set up no command is sent to the printer from the enclosure plugin - all that should be sent is an @pause to octoprint which will handle the rest. I'm sure that is the intended function of the Printer Action (Printer Pause) option.

Thank you for your hard work on this - a key part of the Octoprint functionality. UnfortunatelyI have the same issue. I have set up scripts in octoprint that handle pause and resume very well. I would like my filament sensor to trigger an octoprint 'pause' just like pressing the pause button and my options are set exactly as above. Like Cortexian nothing happens when the sensor triggers in this configuration. In this set up no command is sent to the printer from the enclosure plugin - all that should be sent is an @pause to octoprint which will handle the rest. I'm sure that is the intended function of the Printer Action (Printer Pause) option.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Gandalf/OctoPrint-Enclosure#383