First of all, thank you for this incredible piece of software — it’s been transformative for my printer setup.
I’m currently running Klipper on a PrintMate3D and have encountered a practical limitation with the homing_override feature. By default, Klipper homes axes in the order X → Y → Z, but due to a clamp on my machine, this sequence can sometimes cause collisions if X homes before Y.
To fix this, I’ve added homing_override to change the sequence to Y → X → Z, which works well for full homing (G28). However, once homing_override is active, all G28 commands — including those targeting only a single axis like G28 X - now trigger the full custom homing sequence. This is problematic, especially if an object is already on the bed and a full re-home could cause a crash.
Suggestion:
It would be incredibly helpful if Klipper could restrict the homing_override block to G28 with no parameters, and fall back to Klipper’s default per-axis homing behaviour when using G28 X, G28 Z, etc.
This would allow safe single-axis homing without losing the ability to define a custom full-homing sequence.
Thanks again for all your hard work and continued support of the community.
Definitely changing homing_override is the right approach and by adding a bit of macro code to it like:
[homing_override]
axes: xyz
gcode:
{% set home_all = 'X' not in params and 'Y' not in params and 'Z' not in params %}
{% if home_all or 'X' in params %}
G28 Y # Home Y axis before X
G28 X
{% endif %}
{% if 'Y' in params %}
G28 Y
{% endif %}
{% if home_all or 'Z' in params %}
G28 Z
G1 Z10 # Lift Toolhead after Z Axis Homing
{% endif %}
I think this will give you what you’re looking for.
Just going through the code:
If you just want to home the X axis - it will do the Y axis first.
Note that for the Y axis if statement, I don’t check for home_all because if all axes are to be homed then Y was already homed before X and there’s no reason to do it again
Nothing unusual about the Z axis, except I always like to move the toolhead up a few mm to make sure there’s no chance of a collision with the print surface.
Obviously, this is untested on your printer, hopefully it will do what you’re looking for.