04-16-2007 10:36 PM
04-17-2007 03:03 PM
04-17-2007 05:08 PM
04-18-2007 09:56 PM
Hello Adam.
There is a way that we could try to accomplish this task using a bit of a workaround. However, I would like to stress that most of our other hardware can do this much easier.
If instead of focusing on a counter solution, we focused on an analog input solution, we could get fairly accurate measurements. What we could do is set up a DAQmx task to sample off of 2 analog inputs quickly (the 2 analog inputs correspond to the 2 digital signals of interest). After a few seconds of acquisition, we could post process the data to determine when each signal experienced a rising edge. Then, via the timestamps that correspond to the time when the input signal went high, we could determine the time between the rising edge of both of our signals. This would give us a fairly accurate measurement of the edge separation, but the results would not be real time. Thus, if you want to use this measurement to control some other process in your application and this measurement must be returned immediately after the second signal goes high, this solution will not be completely valid.
You could also do something comperable with 2 digital input lines and continuously monitor their states. However, this will be much slower since the digital lines sample at a slower rate than the analog channels.
Let me know if this helps!
Brian F
Applications Engineer
National Instruments