Skip to content

Conversation

@ddkohler
Copy link
Contributor

The homing signals can exhibit hysteresis, so a more stable solution is to take care when measuring the HOME level, and also to overshoot the first measured instance of home.

Also, it seems important to take care when stepping that motor steps are given adequate time before the next step. In the recently-introduced non-blocking main loop, it was never guaranteed that there was a reasonable wait time between step commands.

This is a first example and changes were grown into this branch through troubleshooting; it is likely that some of the changes introduced here are not necessary. Hopefully we can troubleshoot different aspects of these changes before merging.

if (digitalRead(HOME) == 0) remaining[i] = 0;
setSelect(i);
// read homed twice to make sure
if (carefulReadHome()) remaining[i] = 1; // go one past the limit to avoid unstable readings
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: step of 1 guards against hysteresis

consolidate wait times to be only function of ms_step

some doc additions
@ddkohler
Copy link
Contributor Author

this firmware is being used on fs table atm

@ddkohler ddkohler changed the title [don't merge] notice: take care when homing [WIP] notice: take care when homing Jan 27, 2026
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.

1 participant