Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Synchronize AI with position (from encoder) by Counter (DAQ-STC on PCI6052E, C/C++)

Hello,

we use an encoder with 6000 steps to known the position of an analog acquisition in 60 Hz with PCI6052E.
Our problem: we must set any analog acquisition (set by clock of the card in Hz) and to known at every acquisition the position (from encoder) given by the counter:
How to get both values synchronized
(ie, by array: AI1->pos1, AI2->pos2 and not AI1->pos2 because of delay of Windows NT)?

Windows NT is not real-time, that we believe we cannot synchronize by soft. Any idea by hard?

Thanks a lot,
Alain
0 Kudos
Message 1 of 2
(3,040 Views)
Hi, Alain

You could use the encoder output pulses as an external scanclock for your AI operation. To do this you need to wire the encoder output to the PFI7/STARTSCAN and configure the AI acquisition for external scan clock. (See the SCANsingleBufExtScan_Eseries.C example program that comes with Ni-DAQ.) This way you sample the AI channels every time you get a pulse from the encoder.
Message 2 of 2
(3,040 Views)