[SOLVED] Rotary axis homin on index not working

More
21 May 2023 12:43 #271811 by Aciera
I'm trying to get a rotary joint to home using an encoder index.
I would expect the motor to rotate (according to the 'HOME_LATCH_VEL' set in the ini and upon finding the index pulse stop and reset the absolute position to zero.
What I see is the motor starts turning finds the index and then returns to, what seems to me, the old absolute zero position.
This is on Version 2.9 from a recent bookworm install.

Any ideas?

 

Warning: Spoiler!
 

Warning: Spoiler!
Attachments:

Please Log in or Create an account to join the conversation.

More
21 May 2023 13:50 - 21 May 2023 13:52 #271817 by Aciera
Here is a HalScope shot with the encoder positions.
Rotary: 
 

And my (linear) Y axis also using an index: 
Attachments:
Last edit: 21 May 2023 13:52 by Aciera. Reason: Fix images

Please Log in or Create an account to join the conversation.

More
21 May 2023 13:54 #271818 by Aciera
So it seems to me that with the rotary homing the joint position is not set to zero.

Please Log in or Create an account to join the conversation.

More
21 May 2023 14:00 #271820 by chris@cnc
I seems your encoder feedback is missing?
net a-pos-fb        <=  hm2_7i76e.0.encoder.03.position

Please Log in or Create an account to join the conversation.

More
21 May 2023 14:30 #271826 by Aciera
Ah, yes the linear axis is indeed closed loop and the rotary is not since that runs on a servo controller. So does that mean that I have to fully close the loop for that rotary in linuxcnc to be able to use index homing?
I was hoping to avoid that since that would mean two positional pids in the system.

Please Log in or Create an account to join the conversation.

More
21 May 2023 14:45 #271830 by PCW
It is possible to home open loop stepgen systems to index using
the right firmware (firmware with step/dir index support)

This firmware exports a stepgen index enable pin and has stepgen
hardware that emulates encoder behaviour on index. The stepgen index
input is normally shared with encoder index inputs of the same channel
so you might have to re-arrange stepgens for this to work.

Please Log in or Create an account to join the conversation.

More
21 May 2023 14:51 #271832 by chris@cnc
I set the linuxcnc PID to 1 and tune the servo controller. It works...

Please Log in or Create an account to join the conversation.

More
21 May 2023 15:26 #271835 by Aciera
Thank you both.

The stepgen index
input is normally shared with encoder index inputs of the same channel
so you might have to re-arrange stepgens for this to work.

On my 7i76e i use  three stepgens using closed loop with index homing (stepper/glasscales), one stepgen with home switch and the one in question with a step/dir servo controller with index homing from the controller index feedback.  Would that work?

I set the linuxcnc PID to 1 and tune the servo controller. It works...

Hm, if I do that I always get an 'offset' in the DRO after homing. The absolute value in the DRO is not 0 but say 1.5. This value decreases with the homing latch velocity but i'm already crawling.

 

Please Log in or Create an account to join the conversation.

More
21 May 2023 15:51 #271839 by PCW
As chris@cnc suggested, using encoder feedback for the rotary axis
is probably the simplest solution.

Then all axis would be settup similarly

If you wanted to use stepgen index you would need to arrange
the stepgen channel using index to match the encoder channel
(they are mis-matched now)

Please Log in or Create an account to join the conversation.

More
21 May 2023 16:20 #271844 by Aciera
So the only thing I would have to switch around is to use stepgen.03 with encoder.03 instead of using stepgen.04 with encoder.03? That seems easy enough.
So far I have not found a solution for the homing offset issue I'm having with the encoder feedback.

Please Log in or Create an account to join the conversation.

Time to create page: 0.255 seconds
Powered by Kunena Forum