3D printer G-code · Klipper

SET_RETRACTION: Change firmware retraction (Klipper)

Change firmware retraction — Changes the values used by G10/G11 while printing. Needs [firmware_retraction].

By cnccode · Updated
On this page
  1. What does SET_RETRACTION do?
  2. Parameters
  3. Example
  4. Related commands
  5. More extrusion commands
  6. Frequently asked questions
PropertyValue
CommandSET_RETRACTION
FunctionChange firmware retraction
FirmwareKlipper
GroupExtrusion
SyntaxSET_RETRACTION [RETRACT_LENGTH] [RETRACT_SPEED] [UNRETRACT_EXTRA_LENGTH] [UNRETRACT_SPEED]

What does SET_RETRACTION do?

Changes the values used by G10/G11 while printing. Needs [firmware_retraction].

Parameters

ParameterMeaning
RETRACT_LENGTHmm
RETRACT_SPEEDmm/s
UNRETRACT_EXTRA_LENGTHExtra after unretract
UNRETRACT_SPEEDmm/s

Example

Klipper
SET_RETRACTION RETRACT_LENGTH=0.6 RETRACT_SPEED=35

Klipper. Extended commands need their section in printer.cfg. Results of calibration commands are kept only after SAVE_CONFIG.

More extrusion commands

CommandFunctionFirmware
G10Firmware retract (G10 / G11)Marlin and Klipper
G92Set position (G92 E0)Marlin and Klipper
M82Absolute extrusion (M82 / M83)Marlin and Klipper
M221Flow percentageMarlin and Klipper
M900Linear advance factorMarlin
SET_PRESSURE_ADVANCEPressure advance (Klipper)Klipper

Test it before you print

Paste your start code or a whole file into the 3D printer simulator. It plans every move, shows the time and finds missing waits, cold extrusion and moves outside the bed.

Open the simulator

Frequently asked questions

What does SET_RETRACTION do on a 3D printer?
SET_RETRACTION is change firmware retraction. Changes the values used by G10/G11 while printing. Needs [firmware_retraction].
Does SET_RETRACTION work in Klipper and Marlin?
SET_RETRACTION is a Klipper command. Marlin printers use other G-codes for this task.
Was this page helpful?