LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Daqmx Trigger Indication

How can I get an indication to the front panel that an acquisition event has triggered using Daqmx?
 
I've set the system to pretrigger on a falling edge, which works fine, however, the end user does not get an indication that the system has triggered until after Daqmx Read.vi has finished reading all the data.......12 seconds later (duration of acquisition event).  I'd like the user to get the indication at the moment the trigger threshold parameters have been met.
 
I'm using LabVIEW 7.1, DAQmx 7.2.
 
Thanks.
0 Kudos
Message 1 of 4
(2,561 Views)
One easy way to show when the reference trigger has occurred is to route the AI Reference Trigger signal to one of your counter inputs (i.e counter 0 source on PFIx).  You can do this with a DAQmx connect terminals function. Then run a counter task in addition to your analog task to count events. The count will remain at zero until the analog task is triggered. When the trigger occurs an event will be counted, incrementing the count to 1 and enabling you to notify the user.
 
This is one of several options.  Refer to Thayle's post in this discussion for more suggestions.
 
Regards,
 
Jennifer O.
0 Kudos
Message 2 of 4
(2,541 Views)

Thanks Jennifer.

I'm using a PXI-4472 and PXI-5421.  I don't think these have counter-timers.  I guess I'll just have to use software instead of hardware trigger.

 

Thanks again.

0 Kudos
Message 3 of 4
(2,527 Views)
I agree that a software trigger might be your best answer.  I cannot think of a good way without additional hardware to indicate to the user the occurrence of a hardware reference trigger.  The properties for available samples and total samples acquired will not give you the indication you are looking for with a reference trigger.  These are valid options for a start trigger.  If pretrigger samples are important to your application you can continuously read the samples into LabVIEW and programmatically determine the location you wish to trigger, saving your desired number of pretrigger samples and discarding the rest of the pretrigger data. There is an example already built for this in Help>>Find Examples by the name of "Cont Acq&Graph -Analog SW Trigger.vi".
 
Hope this helps,
 
Jennifer O.
0 Kudos
Message 4 of 4
(2,512 Views)