-
-
Notifications
You must be signed in to change notification settings - Fork 53
Description
What happened
I've faced an issue when the filament ran out on T1 during the COPY mode print.
I've inserted a new filament as usual, which triggered loading filament on T1.
The extrusion was successful; however, I then unexpectedly got move out-of-range errors, resulting in Klipper shutdown and failed print.
Looking at the filament load code, seems like the issue is with the _CLEANING_MOVE macro:
{% set loading_position = printer["gcode_macro T%s" % toolhead].loading_position|float %}
{% set parking_position = printer["gcode_macro T%s" % toolhead].parking_position|float %}
{% set speed = printer["gcode_macro RatOS"].toolchange_travel_speed|float * 60 %}
{% set cleaning_position = loading_position %}
{% if loading_position == parking_position %}
{% if loading_position > 0 %}
{% set cleaning_position = loading_position - 30 %}
{% else %}
{% set cleaning_position = loading_position + 30 %}
{% endif %}
{% endif %}
# nozzle cleaning
G1 X{parking_position} F{speed}
G1 X{cleaning_position} F{speed}
G1 X{parking_position} F{speed}
G1 X{cleaning_position} F{speed}
G1 X{parking_position} F{speed}
It seems like it doesn't account for COPY/MIRROR modes' coordinate shift.
Since the same operation worked fine on T0 previously and works fine with T1 in single mode, my guess is that the macro tried to move the T1 in absolute coordinates (which are only valid in single toolhead mode) instead of applying COPY/MIRROR mode offset/calculation (e.g., something like x -= bed_size /2).
What did you expect to happen
The filament should have loaded without error.
How to reproduce
Start a print in COPY mode, let filament run out on T1, then insert a new filament.
Additional information
No response