core icon indicating copy to clipboard operation
core copied to clipboard

Homing by Z-pulse of servo

Open karoria opened this issue 1 year ago • 3 comments

Hi Terje, I want to accurately home using Z-pulse of servo/easyservo drive. I also have hard limit switches for homing but want to explore homing like "First seek to limit switch and then slowly feed till Z-pulse signal received from drive. I know, I have to use 2 inputs for each axis in this case, but an example code or exact location where I need to modify code will be a great help. Thanks, Ravi

karoria avatar Apr 16 '23 07:04 karoria

There is no need to change any code. Trap hal.homing.get_feedrate in a plugin and switch inputs based on the mode parameter by replacing the hal.homing.get_state function.

terjeio avatar Apr 16 '23 08:04 terjeio

There is no need to change any code. Trap hal.homing.get_feedrate in a plugin and switch inputs based on the mode parameter by replacing the hal.homing.get_state function.

Does this mean, I have to write a new plugin? or should I edit machine_limits.h directly?

karoria avatar Apr 16 '23 09:04 karoria

Plugin code is your best option - modifying the core means that you have to update it for new releases.

terjeio avatar Apr 16 '23 09:04 terjeio