LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Monitor Analog Output at the moment of digital change

Hi,

I generate an analog signal to the system I am testing with -10V to +10V increasing voltage. At the same time monitor the digital changes of several like 5 digital lines. Each digital lines will have more than 1 time digital changes. I need to get the analog voltage value at certain digital change.

 

I am thinking that use a Analog Output to generate signal;

Use Digital Input - Change Detection to get the change;

Use Event Structure to catche the digtial change.

 

Problems are:

If use Event Structure, I need to know the value change at certain digital line? Digital change in diffferent digital line have different meaning, So how should I do to know at which channel digital change heppens? 

 

Also, how can I tell which is rising edge and which is falling edge?

 

Thanks

0 Kudos
Message 1 of 2
(2,342 Views)

If you are using a National Instruments data acquasition device, you can use the DAQmx driver.  There are numerous examples in the LabVIEW Example Finder for acquiring/generating data based on a trigger.  It sounds like you are trying to trigger when your entire port is set to a certain pattern.  If you go to the Example Finder and navigate to Hardware Input and Output>>DAQmx>>Digital Measurements>>Read Dig Chan-Int Clk-Pattern Match Start.  Here you can set the mask of the port and trigger when all of the lines are set to the values you want.  In that VI if you change from digital pattern to digital edge, then you will be able to pick between rising and falling edge triggering of a single line.  I hope you find this helpful.

 

Brandon Treece

Applications Engineer

National Instruments

Message 2 of 2
(2,324 Views)