Data Acquisition Toolbox | ![]() ![]() |
Syntax
DIO = digitalio('
adaptor
',ID)
Arguments
' adaptor ' |
Name of the hardware driver adaptor. The supported adaptors are nidaq and cbi . |
ID |
The hardware device identifier. |
DIO |
The digital I/O object. |
Description
creates the digital I/O object DIO = digitalio('
adaptor
',ID)
DIO
for the specified adaptor
and for the hardware device with device identifier ID
. ID
can be specified as an integer or a string.
More About Creating Digital I/O Objects
addline
function.Name
property is automatically assigned a descriptive name that is produced by concatenating adaptor
, ID
, and -DIO
. You can change this name at any time.More About the Hardware Device Identifier
When data acquisition devices are installed, they are assigned a unique number, which identifies the device in software. The device identifier is typically assigned automatically and can usually be manually changed using a vendor-supplied device configuration utility. National Instruments refers to this number as the device number.
There are two ways you can determine the ID
for a particular device:
daqhwinfo('
adaptor')
.Example
To create a digital I/O object for a National Instruments device defined as device number 1
DIO = digitalio('nidaq',1);
Functions
Properties
![]() | delete | disp | ![]() |