On 06/20/2017 10:51 AM, andy pugh wrote:
On 20 June 2017 at 17:37, Peter C. Wallace <[email protected]> wrote:

I suspect this cannot work the way you have this setup because of the
instantaneous jump in encoder (feedback) position at index

He has hooked up axis.*.motor-pos-cmd to the stepgens' .position-cmd, and motor-pos-cmd does not jump on home. His stepgens will see a smooth curve on their .position-cmd inputs even through all stages of homing.

axis.*.joint-pos-cmd includes the homing offset (and a bunch of other offsets), so it has that discontinuity, so it's good he's not using that.


I wonder if the answer might be to only connect the encoder once homed?

ie, use a mux2 to to connect motor-pos-fb to motor-pos-cmd until homed, and
only then switch it to the encoder.

That should not be needed.

Our shopbot has a similar setup, and it homes fine every time. It has a Mesa FPGA, position-mode steppers, and encoder position feedback. It homes to switches, but not to index.


The ini settings for all joints are of this form:

HOME = 0.000
HOME_OFFSET = -0.260
HOME_SEARCH_VEL = -2.00000
HOME_LATCH_VEL = 0.250
HOME_USE_INDEX = NO
HOME_IGNORE_LIMITS = YES
HOME_IS_SHARED = 0


The HAL wiring looks like this:

net x-encoder-pos <= hm2_5i23.0.encoder.01.position
net x-encoder-pos => axis.0.motor-pos-fb

net x-pos-cmd <= axis.0.motor-pos-cmd
net x-pos-cmd => hm2_5i23.0.stepgen.01.position-cmd


Pretty straight forward.

I still want to see the halscope trace.

It might be worth trying (just for debugging purposes) homing to the home switch, not the index, since that's the config that works for me. If home-to-index is broken we should fix it, and doing that test will help tell us if that's the case.

I have a vague memory that there's a fairly long pause at some stage in the homing state machine. I wonder if it was during index homing? And if so, if that's maybe related to this problem? A halscope trace might show us.


--
Sebastian Kuzminsky

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Emc-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/emc-users

Reply via email to