Max_extrude_only_distance

You should look into your workflow and slicer settings. Some things that you need to consider:

  • For the extruder movement in the M600 you are switching to G91, which will subtract it from the current position of the extruder. This should be OK
  • There is no G92 E0 that would null the extruder position
  • In doubt, Klipper’s max extrusion length is 50 mm, so may need to add max_extrude_only_distance: 100.0 in the [extruder] section

In theory, it should be something like this:

    SAVE_GCODE_STATE NAME=M600_state
    PAUSE # When using the default webif macros then it includes parking
          # You can also customize the parking positions: https://github.com/mainsail-crew/mainsail-config?tab=readme-ov-file#customize-macros
    G90 ; switch to absolute positioning
    M82 ; switch to absolute extrusion 
    G92 E0 ; reset extruder
    G1 E-100 F1000 ; retract
    RESTORE_GCODE_STATE NAME=M600_state

Why I prefer the “absolute” approach:

    G90 ; switch to absolute positioning
    M82 ; switch to absolute extrusion 
    G92 E0 ; reset extruder

Personally, I hate working in any relative mode, as it always requires keeping in mind that every action takes the current position as basis. Saving and restoring the gcode state will make sure that you continue with the mode you have started with, so it doesn’t matter that the macro might have switched to another mode.

2 Likes