Resume print after pause

Hi everyone,

When I pause my print with octoprint, I park the nozzle to the left of my printer. When I want to resume, the nozzle doesn't go to the position where it paused, it goes to the next point of my Gcode.

Imagine 3 points A, B and C where :

  • A is the point where nozzle paused
  • B is the point where the nozzle is park after pause
  • C the next point to go after from the last position before pause.

What I want for my nozzle :
Go from A =>B when pause
Go from B to A when resume
Then go from A to C

What I have :
Go from A =>B when pause
Go from B to C when resume
So I'm missing some material from B to C

What I tested
I go to the rest API of octoprint and take the Gcode script for pause and resume, but not working for me..

Do you have any idea ?

Thanks,

Please enable serial logging

and print something with another pause/resume. Doesn't need to be a big object - a calibration cube for example will do it.
Now upload a systeminfo bundle.

The serial log will show us how the printer reacted to the resume command.

Thanks for you help.
Here is my serial log file : serial.log (10.7 KB)

At line 72, I pausing at position X10 Y50, then until line 100, I park my nozzle and change color of my printer.
When I resume (line 113 to 130), I reset my Z position and go to the next line of my Gcode (position X10 Y10 at line 131 and not at position X10 Y50 when I paused) so the line Y50 to Y10 is not print...

I already try to use this gcode script from the Octoprint rest API website and I have the same behavior.

I don't know why...

Thanks for your answer !

Hi

Looking at the log output, there is no command to return to last position. Such a command is present in the sample / example "beforePrintResumed" script

G1 X{{ pause_position.x }} Y{{ pause_position.y }} Z{{ pause_position.z }} F4500

Hi,

Like I said in my previous post, I already try with this gcode script and I have the same behavior.
I will send the serial log file with the "afterPrintPaused" and "beforePrintResumed" script.

**afterPrintPaused script**
{% 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 X0 Y0
{% endif %}
**beforePrintResumed script**
{% 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 %}

Here is my gcode script after paused and before resumed : serial.log (8.2 KB)

At the line 66, I have the problem... Octoprint didn't receive a readable parse Gcode... but I don't know why...
The M114 event is not fired ? The event is fired but Octoprint can't catch it ?

Your scripts somehow do not appear in the serial.log

How do you get into pause mode? From the printer or OctoPrint?

Might be as simple as changing your M600 command to @pause in the slicer in order for OctoPrint's built in recognition of that pause functionality to work. Otherwise, you need to modify your firmware to support HOST_ACTION_COMMANDS and HOST_PROMPT_SUPPORT.

Looks to be triggered from the Octoprint, but resume script is not triggered. Is the script ok, syntactically? Any interesting stuff in octoprint log?
where is the system bundle?

1 Like

I pause the print from the web interface, by a click on the pause button.

octoprint-systeminfo.zip (12.5 KB)

Here is my system bundle. I also set my gcode script when pause and resume from octoprint button.
It's not juste the resume which is not trigger, but also the pause. While pausing, at line 115 of serial.log, I didn't receive a parseable position data, so I don't execute my script because of the first condition {% if pause_position.x is not none %}

There is a lot of wired things going on in the octoprint.log, including this:

2021-09-15 09:33:01,395 - octoprint.plugins.pi_support - WARNING - This Raspberry Pi is reporting problems that might lead to bad performance or errors caused by overheating or insufficient power.
!!! UNDERVOLTAGE REPORTED !!! Make sure that the power supply and power cable are capable of supplying enough voltage and current to your Pi.

How do you usually shut down the pi?

For my test, I use a phone cable, otherwise, I use Γ  power supply of 5v - 7.5A max

My question was:

When connected to web interface, by using "Shutdown system" button, or when connected in terminal by using command "halt" and I always wait that the led of the Pi stop blinking

2 Likes

This is firmware dependent I think. If OctoPrint can't figure out the position then it would definitely not work as expected.

Make sure you have the right options enabled in OctoPrint to save the position:

I'm not certain if it's your issue, but something else to check.

1 Like

Yes I have it enable

1 Like

I assume you put the scripts
grafik

in here
grafik

Yes, exactly