Delta Tau Forums
Triggered time base capture flag on coder input ? - Printable Version

+- Delta Tau Forums (http://forums.deltatau.com)
+-- Forum: Delta Tau Data Systems (http://forums.deltatau.com/forumdisplay.php?fid=1)
+--- Forum: Power PMAC (http://forums.deltatau.com/forumdisplay.php?fid=2)
+--- Thread: Triggered time base capture flag on coder input ? (/showthread.php?tid=2787)



Triggered time base capture flag on coder input ? - jsinoir - 11-19-2018

Hello,
We are using the triggered time base to accomplish synchronisation with an external device. This device gives us 2 signals a 1kHz clock and a 128kHz clock perfectly in phase (<20ns jitter)

we want to use the 128kHz signal as an external time base for one of our CS and use the 1Khz signal as the capture flag to defreeze the time base (at the next rising edge after arming)

problem, the incoming signals are 5V so we plugged it on coder inputs of spare (dummy) motors.

At first we thought that we could use ServoCapt.a in pEnc1 for the trigger instead of using the flags , but does not seem that this signal is unfreezing the timebase at a rising edge of a coder pulse (the coder is configured in pulse and dir)

is there any way to use a signal wired on a coder input to trigger the time base ? (for now we are still trying to avoid to connect it on a flag input which would require a voltage adaptation) maybe by tweaking the pLimits adress ?

Now what I tried to do is to put the capture flag as "always active" in the motor config so that it reacts "instantly to the arming" then I created a plc that arms the time base as soon as it sees a change in the integer part of the coder value (using a floor) I was expecting to see my time base unfrozen with an jitter proportional to the servocycle (110us).
but again, it seems that I am completely out of phase , I presume the arming does not give me any real-time guarantee (aka if arming at servocycle N with an always up capture flag, then time base is unfrozen at servocycle N+1) . is that correct ?

thank you for your help.

regards,
Jeremy


RE: Triggered time base capture flag on coder input ? - curtwilson - 11-20-2018

Wire the 1kHz signal into the C (index) for the same encoder as you have wired the 128kHz into the A (pulse) input. You will set Gaten[i].Chan[j].CaptCtrl to 1 to trigger on the rising edge of the index input. To the PMAC this now looks like a 128 pulse-per-rev encoder with an index pulse.


RE: Triggered time base capture flag on coder input ? - jsinoir - 11-22-2018

Many thanks, that is exactly what I was looking for !
have a good day !