Measuring the Time Interval Between Changes on the Digital LinesHardware: Digital I/O (DIO)>>High-Speed>>PCI-6534
Problem: How do I measure the time interval between changes on the digital lines? Solution: To measure the time interval between changes on the digital lines, you will need a NI 653x high-speed digital device along with a counter/timer device such as the NI 660x device. By configuring the NI 653x device for the Change Detection sample timing type, the device acquires data whenever the state of one or more data lines change. When this change is detected, the NI 653x generates a pulse on PFI <2..3> or PFI <6..7> (if you are using NI-DAQmx signal naming conventions) or the REQ pin (if you are using Traditional NI-DAQ (Legacy) naming conventions) of the corresponding group. Using RTSI, you can route this signal to the gate of a counter. To do this using NI-DAQmx in LabVIEW, configure a digital acquisition with the Change detetection sample timing type and export the Change Detection event such that the 6602 can measure the time between rising edges of the Change Detection event. To do this using Traditional DAQ in LabVIEW, use the RTSI Control VI. For help on using this VI and information on how to route the REQ signal to RTSI, refer to the help associated with this VI (Right-Click»Help). For example, if you are using the REQ 0 signal, then the VIs inputs are the following:
The counter should be configured for buffered event counting. The counter counts an internal timebase and latches the current count value when there is an edge on the gate. Since the frequency of the internal timebase is known, you can calculate the time that has elapsed between the change detections. Related Links: Developer Zone Example: National Instruments Digital Time Interval Analyzer Start-Up Kit NI 6533/6534 Devices for NI-DAQmx Help NI 653X User Manual for Traditional NI-DAQ Attachments:
Report Date: 12/16/2002 Last Updated: 02/28/2006 Document ID: 2SFAL8N1 |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
