Resume after scheduled pause does not heat the nozzle... (with octopi)
Hey guys, I am not sure wether this is the right subform but anyway:
When I schedule a pause with PrusaSlicer by Ctrl-left-clicking the layer slider and selecting "Add pause print (M601)" and then print via octoprint-server the printer stops at the correct layer, moves the extruder out of the way, keeps the bed heating on and switches the extruder heating off. So far that is how I expected it to work - but: When I resume the print via octoprint the print is immediately continued, without preheating the nozzle or even reset of the correct temperature. It just continues with nozzle temp set to zero. I have to manually set the temperature before resuming the print.
I have not tried with the current firmware but if I remember correctly, before I installed my RasPi and octoprint and printed directly via SD the resume after pause behaved like a filament change / power down recovery / MMU-needs-attention and automatically reheated the nozzle before continuing the print.
Does anybody know if there is a way to make the resume after pause work correctly with octoprint?
My config is MK3S/MMU2 with current firmware (3.10.0-4481/1.0.6-372) and RasPi 3B with Octoprint 1.6.1 with OctoDash 2.2.0 connected via USB and PrusaSlicer 2.3.1
Best Answer by Neophyl:
Might want to read https://github.com/prusa3d/Prusa-Firmware/issues/3148
If at first you don't succeed, skydiving is not for you.
Find out why this is pinned in the general section!
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
What text do you have in OctoPrint Settings/GCODE scripts/ for instance mine is
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
Might want to read https://github.com/prusa3d/Prusa-Firmware/issues/3148
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
Thank you both for your input. This seems to be more complicated than I thought.
@towlerg My scripts for pause and resume in OctoPrint are completely empty, since I though the printer knows what to do when receiving M601 via the printed gcode.file. Question 1) Is the "After print job is paused" script executed even if the pause is initiated by the printed code or just when the pause is initiated by Octoprint (meaning: Does Octoprint know the printer is pausing?)? - I think the answer is "yes" since Octoprint shows the "resume"-button during pause. Question 2) Do I need to have anything in there since the pause feature already works as expected (extruder positioning and temperature control)?
@Neophyl Thanks, that was helpful and a bit confusing. If I get this right, the printer pauses correctly with the send M601, but since he does not receive a (prusa specific) M602 it screws up the resume and just continues with the send GCODE. I don't understand what/who is resetting the extruder position (since my resume script in Octoprint is as empty as the pause script) and why whoever that is doesn't also reset the temperature before hand - also I don't get why the resume button on the printer screws things up... Anyway, I'll try to just add on single "M602" to the Octoprint Resume script and try again. Next step would be to add "M601" to the pause script like in the thread you posted (which does not make sense to me since the pause ist executed correctly).
If at first you don't succeed, skydiving is not for you.
Find out why this is pinned in the general section!
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
@robin
I use for such purposes (e.g. defined stop for insertion of magnets or other inserts) a self-written script in Gcode area "Before (or after) Layer Change".
;BEFORE_LAYER_CHANGE ; Plugin DisplayLayerProgress
;[layer_z] ; Plugin DisplayLayerProgress
;
; pause ?
{if layer_z==207}; set pause-z-coordinate (replace 207 with value)
G4 S0
M117 pause printing
M300 S1000 P500; beep
G91
; Lift print head
; {if layer_z < max_print_height}G1 Z{z_offset+min(layer_z+50, max_print_height)}{endif} ; Move print head up
G1 Z50 ; Move print head up
M104 S170; reduce nozzle temp
M0 halt/stop/pause - press knob to continue and resume on octoprint
M109 R[first_layer_temperature]; set and wait for extruder temp
; {if layer_z < max_print_height}G1 Z-{z_offset+min(layer_z+50, max_print_height)}{endif} ; continue, move print head down
G1 Z-50 ; continue, move print head down
M400 ; wait finishing moves
G90
G4 S0
M117 continue printing
{endif}
Works reliably and flawlessly with MK3S FW 3.8.1 and Octoprint 1.6.1
wbr.
Karl
Statt zu klagen, dass wir nicht alles haben, was wir wollen, sollten wir lieber dankbar sein, dass wir nicht alles bekommen, was wir verdienen.
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
@karl-herbert
Great! Thank you, if the M602-solution does not work I'll use this. Looks easy enough, just one question: Why are you resuming first layer temperature ("M109 R[first_layer_temperature]")? Shouldn't that be just "temperature"?
If at first you don't succeed, skydiving is not for you.
Find out why this is pinned in the general section!
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
Ok, here is what I found out: For my specific application (pause initiated by Slicer-inserted M601) all I needed to do is add a single "M602" to "before print job is resumed" in Octoprint gcode-scripts. Nothing more. It makes the printer resume temperature and extruder position and continue as expected.
The additional "M601" in "after print job is paused" is only needed, if you want to use the "pause"-button in Octoprint and want the printer to do the handling (extruder out of the way, nozzle cool down, bed heating still on) for you. Nothing else needed.
Just tested with my above mentioned configuration....
If at first you don't succeed, skydiving is not for you.
Find out why this is pinned in the general section!
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
@robin
Of course, you can arrange this as you like. In my profiles the first layer temp is mostly identical with the subsequent layer temperatures.
Good to know that this works with the additional M602 👍
wbr,
Karl
Statt zu klagen, dass wir nicht alles haben, was wir wollen, sollten wir lieber dankbar sein, dass wir nicht alles bekommen, was wir verdienen.
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
I was so frustrated until I read this thread and your answer to your own question. Thank you @robin! Now if I could just figure out why Octoprint is so keen to send M112 (thermal runaway protection) any time the printer is cooling down from a print I'd really be set!
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
Ran into the same problem. Quick search turned up this thread. I added M602 to 'before print job resumes' script in Octoprint. We'll see what happens soon.
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
Before I run that file again I decided I would search the gcode and see if the M602 command was in there. I found this.
;AFTER_LAYER_CHANGE
;23
;PAUSE_PRINT
M117 Place M6 nut in slot and resume printing
M601
; printing object 2 wing M6 knob.stl id:0 copy 0
G1 X128.476 Y98.984 F10800
G1 Z23 F720
G1 E.8 F2100
M204 S800
;TYPE:Perimeter
G1 F1433
G1 X131.949 Y105 E.28616
G1 X128.476 Y111.018 E.28624
G1 X121.526 Y111.018 E.28628
G1 X118.053 Y105 E.28624
G1 X121.526 Y98.984 E.28616
If M601 is pause how does it know when to resume? I couldn't find anything labeled RESUME_PRINT.
Where should M602 appear, directly after M601?
;PAUSE_PRINT
M117 Place M6 nut in slot and resume printing
M601
M602
; printing object 2 wing M6 knob.stl id:0 copy 0
G1 X128.476 Y98.984 F10800
Sorry, I'm a g-code knucklehead, just learning this stuff and trying to get this one job to pause printing so I can place the nut and continue the print.
RE:
The M602 can never be in your gcode file. If it were in there (after M601) your print would immediately resume.
If you print via octoprint the M602 (and only the M602) goes into the „before print job is resumed“ script in octoprint settings, that allowes you to resume the print via octoprint‘s resume button. (Octoprint sends the M602 before it continues with your gcode, just as the name hints)
If you print directly via SD on the printer only, the M602 goes nowhere because you resume the print via the control knob and the LCD and your MK3 knows that this means M602.
If at first you don't succeed, skydiving is not for you.
Find out why this is pinned in the general section!
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
Thank you, I understand now.
I did put M602 in the OctoPrint "before print job is resumed" script which until then had been blank.
I have not run that print job again yet to see if it solves my problem. Maybe tomorrow, other things to attend to today.
Thank you again for the explanation.
Still learning here. Only been at this a couple months and new stuff (to me) pops up all the time.
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
Worked as expected. I put the pause at the top of the pocket for the nut insertion, dropped it right in, and hit resume on OctoPrint.
I have one other related question. Is it possible to have the printer give an audible signal when it has paused? Sort of like a ^G, the old bell signal used on old RTTY machines. Since the printer is in another room on a different level I don't get to see what it's up to unless I go into that room or take a peek using the webcam. Either way means I am constantly watching when the job gets close to pausing.
Maybe that is something to ask of OctoPrint but just wondering if there is a code that can be inserted when the job is paused.
RE:
I have one other related question. Is it possible to have the printer give an audible signal when it has paused? Sort of like a ^G, the old bell signal used on old RTTY machines. Since the printer is in another room on a different level I don't get to see what it's up to unless I go into that room or take a peek using the webcam. Either way means I am constantly watching when the job gets close to pausing.
I use OctoPod on my mobile and smart watch together with the OctoPod-plugin for OctoPrint. It sends push messages on events like "print paused", "MMU needs attention", "first layer completed", "print finished", "extruder temp below threshold"...
https://github.com/gdombiak/OctoPod
https://apps.apple.com/us/app/octopod-for-octoprint/id1412557625
https://plugins.octoprint.org/plugins/octopod/
Works with IFTTT as well, you could use this to do basically everything on events.
If at first you don't succeed, skydiving is not for you.
Find out why this is pinned in the general section!
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
Thanks. Alerts to my smart watch would be great. From what I see OctoPod is an iPhone only app.
I will look for something like this for Android. An alert on the phone should get passed on to the watch as it does for all other alerts.
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
@robin Thank you so much! I just found out about the pause option in PrusaSlicer earlier tonight and have just been using the color change option for a long time, which of course doesn't slide the bed to the front for easy magnet insertion like the pause option does. Much to my dismay, you know the rest, and that's how I found this thread. I initiated the print from OctoPrint but resumed after the pause using my MK3S+'s LCD controller. I will probably play it safe with this particular print and just resume from OctoPrint, but I'm interested to know if this will also work if the print is resumed from the LCD controller. I would imagine so, since OctoPrint is still the source of the G-code. I'll experiment this weekend and report back. Thanks Robin and everyone else, this was a frustrating one!
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
As a general principle, unless the printer signals the event to Octoprint (pause, resume etc.) it is unsafe to use the LCD controller for anything that changes the operation of the printer core.
RE: Resume after scheduled pause does not heat the nozzle... (with octopi)
Reading through the Prusa G-code commands, I found M300 will do a beep, so for my "After print job is paused", I added
;Beep 5 times
M300
M300
M300
M300
M300
(and at finish of job, 3x)
I havent tried it yet, but tomorrow (Im already up late, cant wait 2 more hours for the pause to insert) I plan to run this print again with this and the M602 in "Before print job is resumed", which is what I was originally looking for when I found this thread (inserting a finish nail as a hinge on a pic-rail-mounted AR brass deflector, when it resumed, I noticed it wasnt laying down any material, nozzle temp was at 0).
So thanks for the M602, and hope the M300 helps!
Jim
Printer: Prusa MK3S+ & MMU2S
Software: Fusion360 & Prusaslicer
OS: Win 7 Pro/CentOS 7