Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow homing commands to be over-ridden #619

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kerinin
Copy link

@kerinin kerinin commented Jul 10, 2024

Currently, the only way to customize the homing logic is to define a [homing_override] override, which is overkill for some applications. This creates _KLIPAIN_HOME_XXX macros that are called in the existing homing_override and can be overridden to customize homing behavior in a more targeted way.

I made these changes in because I use sensorless homing on one axis only, and I wanted to create a custom macro similar to https://klipper.discourse.group/t/sensorless-homing-macro-suggested-in-klipper-docs/896 that allows me to home twice with a pause between for StallGuard to reset.

Currently, the only way to customize the homing logic is to define a `[homing_override]` override, which is overkill for some applications. This creates `_KLIPAIN_HOME_XXX` macros that are called in the existing `homing_override` and can be overridden to customize homing behavior in a more targeted way.

I made these changes in because I use sensorless homing on one axis only, and I wanted to create a custom macro similar to https://klipper.discourse.group/t/sensorless-homing-macro-suggested-in-klipper-docs/896 that allows me to home twice with a pause between for StallGuard to reset.
@Surion79
Copy link
Contributor

for the beginning, i suggest to write the name of this repo correctly in the functions. there is a letter missing

Copy link

📌 This pull request has been marked as stale because it has not had activity in the past 30 days.
Please update the PR or comment to keep it active. Otherwise, this will be closed in 14 days.
We appreciate your contribution!

2 similar comments
Copy link

📌 This pull request has been marked as stale because it has not had activity in the past 30 days.
Please update the PR or comment to keep it active. Otherwise, this will be closed in 14 days.
We appreciate your contribution!

Copy link

📌 This pull request has been marked as stale because it has not had activity in the past 30 days.
Please update the PR or comment to keep it active. Otherwise, this will be closed in 14 days.
We appreciate your contribution!

@Frix-x
Copy link
Owner

Frix-x commented Jan 8, 2025

Hello, thanks for the PR!

I'm pretty open for this change as it will indeed allow to split and simplify the logic :)
However, let's keep it simple:

  1. Can you change the names to _HOME_X, _HOME_Y and _HOME_Z? No need to add Klippain name here
  2. Since we are in the homing process, there's no macro parameters beside X, Y, Z to specify which axes to home. So in order to keep the _HOME_... macros independent, could you avoid passing parameters and directly read from _USER_VARIABLES and printer object? This will simplify even further and will avoid mistakes.

Then I think I'll be able to merge it :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants