Data Acquisition Toolbox    

Creating an Analog Output Object

You create an analog output object with the analogoutput function. analogoutput accepts the adaptor name and the hardware device ID as input arguments. For a list of supported adaptors, refer to The Hardware Driver Adaptor. The device ID refers to the number associated with your board when it is installed. Some vendors refer to the device ID as the device number or the board number. The device ID is optional for sound cards with an ID of 0. Use the daqhwinfo function to determine the available adaptors and device IDs.

Each analog output object is associated with one board and one analog output subsystem. For example, to create an analog output object associated with a National Instruments board with device ID 1:

The analog output object ao now exists in the MATLAB workspace. You can display the class of ao with the whos command.

Once the analog output object is created, the properties listed below are automatically assigned values. These general purpose properties provide descriptive information about the object based on its class type and adaptor.

Table 6-1: Descriptive Analog Output Properties 
Property Name
Description
Name
Specify a descriptive name for the device object.
Type
Indicate the device object type.

You can display the values of these properties for ao with the get function.


  Getting Started with Analog Output Adding Channels to an Analog Output Object