LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Continuous Triggering of two synchronized PXI 5122

Hello,

 

I´ll try to explain what I want to do.

 

I want to measure signals with a length of 1 to 30 us with 100MS on four channels synchronously (2x PXIe 5122) with a pulse rate of at least 20kHz.

 

The problem in my VI is that I have no chance to get all measurements from those cards when the pulse rate is about 5...6kHz.

 

I configured both cards as needed, set the memory of both cards to ring buffering (enable records > memory) and wanted to read 200 records from each channel.

I Trigger on a Signal on PXIe 5122 N0. 1 Channel 0 positive edge. After Configuration of both cards I configure TClk to synchronize both cards.

 

In measurement I fetch with each call 200 records per channel and count up to the next record I need to fetch to get all records from the cards.

 

So I try to read 200 records for each channel per loop iteration.

 

Also when I lower the sample rate of the PXIe 5122´s (that means also less samples for each record) I can not get over 6kHz of trigger rate.

 

 

The source code of my VI is attached to this post.

 

Maybe someone can help me with my problem or can tell me where in my code is a problem of getting more data from the digitizers.

 

 

0 Kudos
Message 1 of 3
(2,096 Views)

Hi,

 

actually I don't know exactly if the problem occurs only at a pulse rate range from 5 - 6 kHz or general.

 

 

In the example finder there are example VIs, which describe common methods to measure, anlayze and

present data.

 

You are able to filter the results for your specific Hardware, so there in most of times already basic VIs wich show

how to set up the program.

 

Attached you will find the NI Scope Ex Mult-Device-Configured Acquisition which you will find in the example finder under

synchronization.

 

Check this VI and compare and modify for your specific application.

 

Best regards,

 

Rupert Donauer

National Instruments

 

 

0 Kudos
Message 2 of 3
(2,072 Views)

Hi again,

 

thanks for the reply to my post.

 

I allready modified this VI how you can see in my attached VI.

All I did was to remove the complete configuration stuff for the measurement devices out of the while loop, cause the card config stays constat all over measurement.

Also the TriggerClock Synchronisation has to be done only once when configuration of the cards stays constant. (I hope this is correct?)

 

When using the cards internal memory as a ringbuffer you will have to say what positions in the buffer (number of records) you want to fetch what is done by the property node inside the while loop (fetch record number).

From this property node I want to read the specified number of records done in the configuration (property node:fetch number of records).

 

This means: Each iteration of the while loop reads for example 200 records. Starts with record 0 to 199 for each channel, next iteration starts with record 200 to 399 and so on.

All this works fine, but when setting the Pulserate above 5...6kHz (needed rate is 20kHz) it is not possible to get all records fast enough from the internal memory of the cards.

So after some aquisitions I get a buffer overrun. This is also correct, because I did not fetch all records fast enough from the card, so older records from the ringbuffer become overwritten.

 

My problem is that i actually do not know why this happens and why i can´t get the records fast enough from the measurement devices.

 

Kind regards,

 

Daniel

 

 

0 Kudos
Message 3 of 3
(2,064 Views)