I am having trouble designing a VI to do what I need. I am trying to find the time difference between two digital pulses on two separate channels but the VI that I currently have only has a precision of more than a millisecond. I needs it to be under 0.1 ms.
Exactly what I am doing:
I have two optical sensors that give a digital pulse on two separate channels when an object passes by them. They are separated by a known distance (about 8 inches) and I am passing an object by them at a relatively high velocity (about 17 feet/sec). I need to use the time difference between them to find an exact velocity. The input is normally high and becomes low when an object interupts the field. I need the time difference between the falling edges and it needs to be within 0.1 ms.
M Series 6250 PCI DAQ
BNC 2120 connector block
I suspect that I need to use LabVIEW realtime but I am not familiar with it. If anyone can think of a good way to do this or even has a VI that I can take a look at then it would be very helpful.
I've only got seconds to reply now, but you should look into examples for "two signal edge separation" measurements using one of the on-board counter/timers. You can easily get sub-microsecond resolution!
Two-edge separation measures 2 different signals coming in on 2 different pins, but only 1 counter "channel" is used to perform the measurement. The M-series allow very flexible signal routing, so you can very likely map almost any physical PFI pin to almost any functional counter usage (timebase, sample clock, gate, trigger).