LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Using high-sample-rate digital input as a digital output trigger

Hello,

 

I would like to be pointed in the right direction with my first LabVIEW project. I have a need to use the state of a digital line sampled at up to 1 MHz to trigger a fixed length output pulse. I cannot use edge triggering - the line has to be sampled at a defined rate to determine its state as it may remain high between samples. I don't know if this is a task better suited to a Real-Time or FPGA solution rather than LabVIEW on Windows using a conventional PXI multifunction IO card?

 

The sample rate, number of samples, and pulse width will be user-selectable in the application.

 

 

Sample digital line

 

If high:

- Output a pulse

- Increment a counter

If low:

- No action

 

Repeat for N samples

 

 

 

Software: LabVIEW on Windows.

Hardware: PXI-6115 card in mind at the moment.

0 Kudos
Message 1 of 4
(2,642 Views)

Hi Louis,

 

You can use the DAQmx triggering functions  - http://zone.ni.com/reference/en-XX/help/370469AA-01/lvdaqmx/mxtrigger/ her but you will have to define the characterisitics of the pulse before hand, start the task and then the hardware will be able to wait for the trigger. 

 

There is also a white paper on triggering which is very useful - http://www.ni.com/tutorial/4329/en/ .

 

 

Kind Regards,
Lucas
Applications Engineer
National Instruments
0 Kudos
Message 2 of 4
(2,576 Views)

Hello Lucas,

 

Thanks for getting back to me. I can see that achieving the input sample rates I want is certainly possible using DAQmx tasks, but I couldn't work out a way to make a decision based on each sample and output coresponding pulses at the same rate. I think decisions at this speed really have to be made in hardware and I don't know if I can incorporate that intelligence into a DAQmx task to be offloaded to e.g. a PXI-6115?

 

For the moment, I've started working with an R-series card to do the digital acquisiton and digital ouput, but if there is a way to do this using a multifunction DAQ card then I'd be interested to see.

 

Thanks again,

Louis

0 Kudos
Message 3 of 4
(2,557 Views)

Hi Lous,

 

DAQmx won't allow you create something that can respond to each sample. To respond to each sample I believe you will need FPGA. 

 

On a DAQ card you will be putting the data in the buffer and transferring to the PC to then look at the sample in software which means the response will be late. 

 

 

Kind Regards,
Lucas
Applications Engineer
National Instruments
0 Kudos
Message 4 of 4
(2,538 Views)