Benachrichtigungen
Alles löschen

Octoprint Cancel Print gcode  

  RSS
ALEX
 ALEX
(@alex-17)
Active Member
Octoprint Cancel Print gcode

Hello,

 I have been using the following gcode for cancel print action on my Mini+

G91; Set to Relative position
G1 E-1 F300; retract the filament a bit before lifting the nozzle
G0 Z15; move z axis up 15
G28 X; home X axis
G1 Y150 F5000; move part out for inspection
G90; Set to Absolute position
M104 S0 ; turn off extruder heat
M140 S0 ; turn off heated bed
M106 S0 ; Turn off fan
M18; Move Freely

But it is trying to move Y axis past the limit, forcing the motor and belt.

 

Any tips on what i need to change?

Thanks

Veröffentlicht : 04/02/2021 12:45 pm
towlerg
(@towlerg)
Noble Member
RE: Octoprint Cancel Print gcode

I think the line "G1 Y150 F5000; move part out for inspection" is your problem. You previous set relative mode which means move Y to (current position + 150). Easiest is to move  that line after "G90; Set to Absolute position", which may or may not be what you want.

FWIW heres my code

M84                               ; disable motors
{% snippet 'disable_hotends' %} ; M104 S0
{% snippet 'disable_bed' %} ; M140 S0
M107 ; fan off
G91 ; go relative
G0 Z5 ; uncond clear part
G90 ; go absolute
G0 X0 Y140 Z50 ; move bed forward

Veröffentlicht : 04/02/2021 2:39 pm
DarthMeerkat gefällt das
ALEX
 ALEX
(@alex-17)
Active Member
Themenstarter answered:
RE: Octoprint Cancel Print gcode

@towlerg

Thank you for your reply. i have tried moving it after absolute position, but it seems no matter what i do, it ignores the G90.

If i send it from the terminal the gcodes work just fine.

But in that sequence, it still does a relative move. i've also tried G90 Y, and use G0 instead of G1..no luck

Veröffentlicht : 08/02/2021 8:13 am
towlerg
(@towlerg)
Noble Member
RE: Octoprint Cancel Print gcode

Can you post your modified code?

Veröffentlicht : 08/02/2021 9:00 am
ALEX
 ALEX
(@alex-17)
Active Member
Themenstarter answered:
RE: Octoprint Cancel Print gcode

@towlerg

 

This is what i've tried just now

G91; Set to Relative position
G1 E-1 F300; retract the filament a bit before lifting the nozzle
G0 Z15; move z axis up 15
G28 X; home X axis
G90; Set to Absolute position
M104 S0; turn off extruder heat
M140 S0; turn off heated bed
M106 S0; Turn off fan
G0 Y150;
M18; Move Freely

Veröffentlicht : 08/02/2021 10:53 am
daemon512
(@daemon512)
New Member
My workaround

I was having the same problem.  I just solved it by adding G28 Y; after G28 X; - this homes the Y axis, then tells it to move out for inspection.  I don't know why setting absolute then telling it to go to 180 is a problem, maybe when its cancelled it things that home is where it stopped.

Here's the code:

G91; Set to Relative position
G1 E-1 F300; retract the filament a bit before lifting the nozzle
G0 Z15; move z axis up 15
G90; Set to Absolute position
G28 X; home X axis
G28 Y; home Y axis
G1 Y180 F5000; move part out for inspection
M104 S0 ; turn off extruder heat
M140 S0 ; turn off heated bed
M106 S0 ; Turn off fan
M18; Move Freely

Veröffentlicht : 11/09/2021 3:06 pm
Teilen: