Multifunction DAQ

Showing results for 
Search instead for 
Did you mean: 

pre-triggering with four PXI-6115 Cards

Go to solution



I have a PXI-1010 chassis with four PXI-6115 cards, labeled boards 3, 4, 5, 6, installed in it.  Each of these cards has four analog input channels (BNC inputs).  In my current system, all four boards trigger off of the first analog input on board 3.  I do this using an analog rise trigger on board 3, which then triggers a digital start trigger on boards 4, 5, and 6.


Now, I would like to be able to take pre-trigger samples.  I have worked on this for a while and what seems to happen is that board 3 correctly triggers and takes pre-trigger samples, but boards 4, 5, and 6 somehow are triggering too late or early or something - they never record any of my input test signals.  


Can someone help me figure out where I'm going wrong here?  I have attached my VI and also an image of the important part of my block diagram.





Download All
0 Kudos
Message 1 of 6

First of all, I would like to compliment you on your well organised code. This looks like it is going be a master piece of timing and synchonosation when it is finished.


I have spend some time looking at your code. If understand this right, you want all of the ai channels on every board to trigger together when board 3/aio rises about 0.0001 volts. You also want it all to include 300 presamples. Is that right?


Notice that you are getting error -200284, which means that the for boards 4-6 timed out before the trigger occured. It's not that it is triggering late--it is not triggering at all.


Here are two things you could try:


1. Change the input to the "Get Terminal Name with Device Prefix Campbell" subVI to ai/ReferenceTrigger. It could be that it is not triggering boards 4 to 6 because they are waiting for a pulse from the board3/ai Start Trigger, but you're not using a start trigger. You are using a reference trigger. In other words, it could be that the start trigger channel is blank because you configured a reference trigger instead of a start trigger. This would result in the other boards not receiving a trigger pulse.


2. Try configuring the other boards to start with the same analog reference trigger as board 3. I'm not entirely familiar with this particular PXI chassis, but it might be able to route the trigger to the other boards. It's worth a try.


Please let us know if either of these options worked. Take care,


Jeremy P.

Jeremy P.
Application Engineer
National Instruments
0 Kudos
Message 2 of 6

Thanks Jeremy,


You are understanding my code correctly - glad it makes sense!  


Good idea on option 1 - I'll give that a try.  I tried Option 2 already but somehow the other boards need to be triggered from an analog input coming from their own channels, not from another board.



0 Kudos
Message 3 of 6

Thanks again for your help.  I set the input to ai/ReferenceTrigger.  It seems like now it records some samples prior to the trigger, but after the trigger boards 4/5/6 stop recording anything.  Thoughts on that?



0 Kudos
Message 4 of 6
Accepted by topic author souperman1985

It could be that you need to wire the number of samples per channel into the sample clocks for boards 4,5, and 6. This will make sure that the task creates a buffer on your PC that is large enough to receive all of the samples that you are going to read.


Also, why did you delete the sequence structure? You needed that to ensure that the slave boards were armed before the master board.


Here is a link to an example that is similar to what you are trying to do. This example acquires the data at different rates at different boards, but it looks like everything else is the same as what you are doing. I think that it could be helpful for you:


Jeremy P.

Applications Engineer
National Instruments
0 Kudos
Message 5 of 6

Between putting in the sequence structure and giving the timing modules the number of samples, it worked!  You can see on this VI that it correctly recorded samples prior to the triggering event (the white plot on the graph).  Thanks!


0 Kudos
Message 6 of 6