Hello Mishal,
The PXI-6289 M Series device has two counters that are capable of counting TTL
signals. To troubleshoot your setup I would first verify that your signal
coming from the motor is a proper TLL signal and that pulses are being
transmitted. Next, I would use Measurement and Automation Explorer (MAX)
to count the pulses to make sure that the your hardware and software is working
correctly. You can test this in MAX by expanding Devices and Interfaces >>
NI-DAQmx Devices. Next select your device and press the Test Panels
button. In the window that appears select the counter tab. Then
select the counter you are using, set the mode to Edge Counting, and specify
the source to be PFI8 or PFI 3 (counter 0 gate or counter 1 gate).
Connect your signal to PFI8 (pin 37) or PFI3 (pin 42).
Once you get MAX to count your pulses you should be set to program your
software.
Regards,
Jesse O.
Applications Engineering
National Instruments
Jesse O. | National Instruments R&D