Example Code

CDAQ-9178 Count Digital Events Without Digital Module

Products and Environment

This section reflects the products and operating system used to create the example.

To download NI software, including the products shown below, visit ni.com/downloads.


  • Data Acquisition (DAQ)


  • LabVIEW


  • NI DAQmx

Code and Documents



This example shows how to create a count digital events task by accessing the CDAQ-9178's onboard counters without a digital module.



Instead one of the 2 onboard PFI lines will be routed to the onboard counter.




  • LabVIEW 2012 or compatible
  • NI-DAQmx 9.5.5 or compatible


  • NI cDAQ-9178


Steps to Implement or Execute Code

  1. Choose one of the onboard BNC trigger connections to act as PFI lines where the signal to be counted will be inputted. 
  2. Choose the onboard counter.
  3. Run the VI


Additional Information or References

CDAQ count digital events.JPG



 **This document has been updated to meet the current required format for the NI Code Exchange.**

Tejinder Gill
National Instruments
Applications Engineer
Visit ni.com/gettingstarted for step-by-step help in setting up your system.

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.