Data Acquisition Toolbox | ![]() ![]() |
Generate a list of descriptive channel or line names
Syntax
Arguments
Description
generates a cell array of descriptive channel or line names by concatenating names = makenames('prefix',index)
prefix
and index
.
Remarks
You can pass names
as an input argument to the addchannel
or addline
function.
If names
contains more than one descriptive name, then the size of names
must agree with the number of hardware channels specified in addchannel
, or the number of hardware lines specified in addline
.
If the channels or lines are to be referenced by name, then prefix
must begin with a letter and contain only letters, numbers, and underscores. Otherwise the names can contain any character.
Example
Create the analog input object AI
. You can use makenames
to define descriptive names for each channel that is to be added to AI
.
names
is an eight-element cell array of channel names chan1
, chan2
,..., chan8
. You can now pass names
as an input argument to the addchannel
function.
Functions
![]() | load | muxchanidx | ![]() |