Although it may not seem like standard operation since most uses involve offsets and not changing the coords of the axis once homed I'm trying to manually position my axes to a location via code, zero the axis at that point, and have the backlash amount and direction be maintained for the next move that is performed. Since backlash amount and direction are lost when ZeroAxis is performed, I had thought I would save them before the ZeroAxis and recall them after.
It sounds like that possible 'burst of step pulses to move the backlash amount' is my problem. I don't suppose there is a method to set the backlash amount/direction *without* moving the motor or a zeroaxis() that doesn't clear the backlash amount and direction?
Motor movement during reset of axes
Moderators: TomKerekes, dynomotion
- TomKerekes
- Posts: 2679
- Joined: Mon Dec 04, 2017 1:49 am
Re: Motor movement during reset of axes
Could you just move in the negative direction by an amount larger than the backlash to your position so the backlash would be zero before you zero? Then the backlash would always be zero and not need to be set.
Otherwise there is a global variable:
I believe with output gain of 1 and zero destination if you set this equal to the Backlash value then there should be no pulses output. Basically KFLOP outputs step pulses until this value matches the Destination + Backlash.
Note the index is the number of the Step/Direction generator which may be different from the axis number.
You should perform a WaitNextTimeSlice() then set both the backlash and the ActualStepPos to avoid any possibility of being interrupted with only one changed.
HTH
Otherwise there is a global variable:
Code: Select all
double ActualStepPos[NSTEPDIR];
Note the index is the number of the Step/Direction generator which may be different from the axis number.
You should perform a WaitNextTimeSlice() then set both the backlash and the ActualStepPos to avoid any possibility of being interrupted with only one changed.
HTH
Regards,
Tom Kerekes
Dynomotion, Inc.
Tom Kerekes
Dynomotion, Inc.