Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

Which Analog Input channel type to use

Hi,

 

I am using USB-6221, and using C++ for coding the application.

 

I use a digital output channel to send a pulse train of n pulses at KHz. A receiver is connected to an input channel, from which I want to measure the received signal. I expect to receive a signal at the same frequency, and the time that it took to receive the signal is related to the distance between the transmitter and the receiver.

 

Which channel input type should I use? I assumed DAQmxCreateAIFreqVoltageChan should be used, but I receive an error message that "selected physical channel does not support the measurement type ...".

 

How should I configure the Input channel?

Which Read interface I should use?

 

Best Regards,

Danny.

0 Kudos
Message 1 of 2
(3,096 Views)

Hi Danny,

 

DAQmxCreateAIFreqVoltageChan() is for use with devices that convert frequency to voltage in hardware, namely the SCXI-1126 and SCC-FV01. Even if you had one of these devices, I don't think it would do what you want, which is to measure the phase difference between two signals. It would only measure the frequency.

 

How many input channels do you need for this, how many output channels are you using, and what are the logic levels of the signals? Depending on the answer, counter/timer or digital input channels may or may not be a better solution than AI.

 

Brad

---
Brad Keryan
NI R&D
0 Kudos
Message 2 of 2
(3,080 Views)