From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to run two DAQmx Read (Counter in + Digital in) simultaneously?

Hello to all, i have following issue:
I want to acquire a digital (UART like) bus signal. For this purpose i use a DAQmx Card (PXI 6070e). I need precise time information about time lenght of 0 and 1, so i use a counter. The counter is adjust to CI Semi Period(continuous samples) -> on the edge change i'll get a new measured time value. It works perfectly, but i newer know what kind of state (0 or 1) actually belongs to current value. Of course they changing with each edge, but i need to know that exactly. So i should take a digital input which watching the current state. Unfortunately i can not synchronise two DAQmx-reads.
Finaly i should get two values:
time value(counter) and his state(digital in
) to work with them. How can i do this?
I use LabView 7.0
0 Kudos
Message 1 of 2
(2,415 Views)
[SRQ 211371]
This is not a trivial taks but here is one way to do what you explained with a PXI-6070E and some external circuitry:

1. Use buffered semi period measurement to measure the width of your pulses.(Meas Buffered Semi-Period-Continuous.vi)

2. Use a buffered continuous analog data acquisition with external scanclock (e. g. Cont Acq&Graph Voltage-Ext Clk.vi). Maybe you should use a triggered example to start the acquisition at a defined time.

Now you could connect your signal to the ScanClock input (PFI7) of the 6070E but then you only would acquire only a sample at either the rising or the falling edge. As you need a sample at both edges you need some external circuitry that generates a short positive TTL pulse at each edge (rising and fa
lling).
Sorry that I can't provide a solution for this circuitry but I'm pretty sure something like this should be available as a low cost IC.

You may want to allow your signal some settling time after the scanclock pulse has occurred. In this case simply acquire data on two AI channels. The first channel is only a dummy channel. Connect your signal to the second channel. The delay can be adjusted with the interchannel delay.

If anybody knows a good solution for the external circuitry or if anybody has a better approach please post it here.

Best regards,

Jochen Klier
NI-Germany
0 Kudos
Message 2 of 2
(2,415 Views)