Code covered by the BSD License  

Highlights from
Counter Example

5.0

5.0 | 3 ratings Rate this file 5 Downloads (last 30 days) File Size: 16.54 KB File ID: #2890

Counter Example

by Scott Hirsch

 

30 Dec 2002 (Updated 28 Sep 2011)

An example using generic dll calling to use the counter on an NI daq card.

| Watch this File

File Information
Description

UPDATE: Beginning with R2011b, the Data Acquisition Toolbox offers direct support for counters on most NI data acquisition card. -------

This example shows how to access the counter subsystem of an NI AI or MIO card. This feature is not supported by the Data Acquisition Toolbox™, but can be easily implemented with direct calls to the NIDAQ driver with generic DLL calling.

This counter application can be run while the Data Acquisition Toolbox is accessing the other hardware subsystems (analog input, analog output, and digital input/output). This allows you to build a complete measurement system directly within MATLAB®.

The zip file contains two directories - one if you are running R13, another if you are using R13SP1 or newer.

Acknowledgements
This submission has inspired the following:
squareWave, Using Counter of NI DAQ card to generate a pulse train
MATLAB release MATLAB 6.5 (R13)
Other requirements MATLAB Patch for Generic DLL calling http://www.mathworks.com/support/solutions/data/33513.shtml LoadLibraryGUI is strongly recommended http://www.mathworks.com/matlabcentral/fileexchange/loadFile.do?objectId=2800&objectType=file
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (3)
23 Apr 2003 SASMITO NUGROHO  
25 May 2005 Josh Coaplen

Thanks for this.

02 Aug 2005 Eduardo Veras  
Please login to add a comment or rating.
Updates
17 Dec 2003

Fix a wierd bug in nidaqcns.m. A random line from another application was inserted in this file.

12 Feb 2004

Updated to run under R13 Service Pack 1 and later releases.

12 Jan 2010

Updated copyright.

28 Sep 2011

Updated description to reference the relevant capability now in the Data Acquisition Toolbox.

Tag Activity for this File
Tag Applied By Date/Time
example Scott Hirsch 22 Oct 2008 06:55:37
application Scott Hirsch 22 Oct 2008 06:55:37
counter Scott Hirsch 22 Oct 2008 06:55:37
timer Scott Hirsch 22 Oct 2008 06:55:37
dll Scott Hirsch 22 Oct 2008 06:55:37
countertimer Scott Hirsch 22 Oct 2008 06:55:37
linked library Scott Hirsch 22 Oct 2008 06:55:38
linked Scott Hirsch 22 Oct 2008 06:55:38
counter Nico Broos 19 May 2011 19:02:28

Contact us at files@mathworks.com