Use NI 9402 to Acquire a Position Measurement from an Encoder

Updated Oct 4, 2021

Environment

Hardware

  • NI-9402
  • cDAQ-9191

Software

  • Measurement & Automation Explorer (MAX)

Driver

  • NI-DAQmx

This guide walks through how to use an NI 9402 with a cDAQ chassis to acquire the position measurement of an encoder using NI-DAQmx. 

Useful information:

To acquire the position measurement you must consider:
  1. Check the pinout of NI 9402.
  2. Following the indications provided in the document  C Series Signal Connections for Counters, you can identify where to connect  pins A, B and Z of your encoder. In particular, for NI 9204:
    • MeasurementCtr0Ctr1Ctr2Ctr3
      Position
      Measurement
      A: PFI 0
      B: PFI 2
      Z: PFI 1
      A: PFI 3
      B: PFI 1
      Z: PFI 2
      A: PFI 1
      B: PFI 0
      Z: PFI 3
      A: PFI 2
      B: PFI 3
      C: PFI 0
  3. Now, you can configure an encoder measurement from MAX following the steps provided in Connecting Quadrature Encoders to a DAQ Device