Ramblings of an aging IT geek
← Ramblings of an aging IT geek
hardware

i put klipper on the printer and it learned to move

Moving an ageing i3-style printer from stock Marlin to Klipper running on a spare Raspberry Pi, and watching print speeds nearly double with better corners than before.

A 3D printer mid-print with the toolhead moving fast

My printer is an ageing i3-style machine with an 8-bit board, the kind everyone owned at some point. It printed fine. It just printed slowly, and any time I pushed the speed the corners turned to mush and the whole gantry started to ring like a struck tuning fork. I had assumed that was simply the ceiling for hardware of this vintage. It was not. The ceiling was the controller.

The fix was Klipper. The idea is delightfully cheeky: the little 8-bit microcontroller on the printer is far too weak to do the clever motion maths in real time, so Klipper stops asking it to. It moves all the planning onto a Raspberry Pi over USB, the Pi works out the kinematics with a proper processor, and the microcontroller is demoted to a dumb step generator that just does what it is told, precisely, when it is told. Two brains, each doing the bit it is actually good at.

I had a spare Pi 3 in a drawer, which is true of approximately everyone reading this.

Getting it running

Setup is more involved than flashing Marlin, but it is well documented. You flash the Klipper firmware onto the printer board, install the host software and a config on the Pi, and from then on you talk to the printer through the Pi rather than the board directly. I run it with OctoPrint on the same Pi, so the workflow barely changed: I still send G-code from the same web interface, it just gets there via Klipper.

The printer config is one big readable text file rather than a firmware recompile, which on its own is worth the move. Changing a stepper current or a max acceleration is editing a line and restarting, not reflashing:

[printer]
kinematics: cartesian
max_velocity: 200
max_accel: 2000
max_z_velocity: 25
square_corner_velocity: 5.0

That square_corner_velocity line is part of the trick. Klipper does proper look-ahead and "pressure advance", so it eases the extruder pressure into and out of corners instead of blobbing on the way in and starving on the way out.

The printer and Raspberry Pi wired up on the bench

What actually changed

The numbers did the talking. Prints that used to crawl along at 50 mm/s now happily run at 80 to 100, and the corners are sharper at the higher speed than the old setup managed slowly. That last part still feels like cheating. It is the pressure advance and the look-ahead doing work the old firmware simply never attempted on hardware that modest.

Two honest caveats. First, your printer now depends on a Raspberry Pi staying up, which is a new thing to care about. If the Pi falls over mid-print, the print is gone. Second, you will spend an evening tuning pressure advance and resonance, and you will enjoy it more than you expect, but it is an evening.

Worth it, though. I have a printer I had mentally retired, and instead it has become the fast one on the bench. Same motors, same frame, same wobbly bed I keep meaning to replace. The only thing that changed was where the thinking happens.