Automatic nozzle brush cleaner for Artillery Sidewinder X2
Model originally uploaded to Thingiverse at https://www.thingiverse.com/thing:6173230. STL taken from: https://www.thingiverse.com/thing:4624277
Now you can automatically clean the nozzle before printing for a Sidewinder X2 and X1 with a brush. Just print the stl preferably in PETG and install it on the back left screw of the printer, instead of the front left.
Be careful when using the below gcode though. By default, the limit of the bed (y-axis) is 300, but I could see I could reach it to 313 without stretching my parts. So, for klipper, on the [stepper_y] section, I changed "position_max: 300" to "position_max: 313". Test your bed 1 by 1 mm, so you won't get any damage by using the macro. It will check if the printer is homed, and if not, it will home the printer. Probably it can work on the stock printer if it allows movement to 313 y. By the time the macro is working fine, you can then add it to the start_print section. For klipper, I added the line "BRUSH" without quotes, to run the BRUSH macro, before the line purging.
[gcode_macro BRUSH] gcode: {% if printer.toolhead.homed_axes == "xyz" %} G90 G1 X70 Y313 F4000 G1 Z2.5 F1000 #edit the above 2.5 value depending on how low to go to the brush G1 X10 F25000 G1 X70 F25000 G1 X10 F25000 G1 X70 F25000 G1 Y312 F500 G1 X10 F25000 G1 X70 F25000 G1 E-2 F1800 {% else %} G28 G90 G1 X70 Y313 F4000 G1 Z2.5 F1000 G1 X10 F25000 G1 X70 F25000 G1 X10 F25000 G1 X70 F25000 G1 Y312 F500 G1 X10 F25000 G1 X70 F25000 G1 E-2 F1800 #retract 2mm at a speed of 1800/60= 30mm/s {% endif %}