Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

RTSI/NI-DAQ configuration for multiple cards & mutliple sampling rates

What are the various methods of syncronizing E-series cards?

I'm trying to figure-out a variable sampling rate freindly syncronization method... I have several cards sampling at 8kHz and one at 2kHz.

Currently I route ND_IN_SCAN_START, ND_IN_CONVERT, & a half-duty square wave out the RTSI bus from the master; I route the square wave into ND_IN_START_TRIGGER on all the cards and route ND_IN_SCAN_START & ND_IN_CONVERT in on all the slaves.

Are there other methods to keep all the cards in sync?

Is it neccessary to route the ND_IN_SCAN_START & ND_IN_CONVERT signals?
Is it possible to route the internal 20MHz clock from the master to all the slaves and trigger off it? Wit
hout using a counter?



...
Frivilous Details:
I have an application that using 6 PXI-6033E NI-DAQ cards. Each card is connected to one SCXI chassis, and each chassis has several modules in it. Five of the cards have 40 channels (to be) acquired at 8kHz each, and one card has 128 channels (to be) acquired at 2kHz each.

I plan on actually sampling 160 channels at 2kHz (and ignoring the 'bonus' 32 channels) to make the math easier (read: possible). This way all the cards are acquiring data at the same rate of 320kHz.
0 Kudos
Message 1 of 8
(3,071 Views)
If you want to synchronize all of your boards, you can share the scan and/or channel clock and a start trigger. Another option is to export the 20 MHz timebase from the master to slaves, and let the slaves derive their own scan and channel clocks from that timebase. However, you will still need to provide a common start trigger if you want to correlate the data from each board in time.

To export the timebase, you can use Select_Signal with signal = ND_RTSI_CLOCK and source = ND_BOARD_CLOCK to route the master's timebase to the RTSI bus. You then call Select_Signal for each of the slaves and switch the parameters.

You can then program the scan and channel parameters for each device independently. Also, at the end of your acquisition, be sure to call Select_Signal
again to disconnect all of the signals from the RTSI bus.

Hope this helps.

Regards,
Erin
0 Kudos
Message 2 of 8
(3,070 Views)
Select_Signal returns -10003 when I try to route the reference clock either in or out to the RTSI clock. The NI-DAQ docs list only a few devices that can route out to the rtsi_clock.

RTSI_Clock returns -10403 as indicated by the docs.

It also says: "To connect the system clock signal of any other device to the RTSI bus, you must change a jumper setting on the device."
But there are no jumpers on the NI_DAQ cards 😞

Syncronization would be really easy if all the cards could share a common reference clock...

Is it actually not possible to sync the reference clocks, or am I doing something wrong?
0 Kudos
Message 3 of 8
(3,070 Views)
I'm testing on two PCI-6033E's - is RTSI_CLOCK routing only functional with the PXI-6033E's?
0 Kudos
Message 4 of 8
(3,070 Views)
I received the same errors on the PXI cards as the PCI cards...
0 Kudos
Message 5 of 8
(3,070 Views)
Ok last comment (no really :))

In order to route the reference clock out the RTSI bus the sourceSpec must be ND_DONT_CARE.

i.e. this routes the reference clock out from the master card:
RTSI_Clear(m_iDeviceID);

//Route Reference Clock out RTSI bus
if((m_iStatusCode=Select_Signal(m_iDeviceID, ND_BOARD_CLOCK, ND_RTSI_CLOCK, ND_DONT_CARE)) < 0)
return(E_FAIL);

//Send Scan Clock out RTSI_0
if((m_iStatusCode=Select_Signal(m_iDeviceID, ND_RTSI_0, ND_IN_SCAN_START, ND_LOW_TO_HIGH)) < 0)
return(E_FAIL);
0 Kudos
Message 6 of 8
(3,070 Views)
I just wanted to follow up with the 'success' story.

Apparently the PXI-1010 automatically routes the clock from the device in slot 2 out the RTSI_CLOCK line. If I explicitly route the clock from any device out the RTSI_CLOCK the system hangs (and the PXI-1010 is left in a baaadddd state). However, if I route the RTSI_CLOCK to the BOARD_CLOCK on all the devices (with a device in slot 2) every card gets the same 20MHz clock. I've had them running for a few hours now and there's no drift.

The documentation on the PXI mentions that the PXI_STAR_* lines are setup to be used from slot 2; and that the chassis provides a 10MHz clock. It appears that the star lines can only be used with DSA devices, or that's how the docs read.

Anyway, if you have PXI/SCXI equipement, jus
t route the RTSI_CLOCK into the BOARD_CLOCK, trigger, and everything will be syncronized.
0 Kudos
Message 7 of 8
(3,070 Views)
I had a disfunctional PXI-6052E card in the system when I was working on this syncronization code. It was the cause of the problems I had routing the clock to and from the RTSI_Clock line.
0 Kudos
Message 8 of 8
(3,070 Views)