Data Acquisition Toolbox
  Function/Property:
    Search    Help Desk 
analoginput    Examples   See Also

Create an analog input object.

Syntax          

AI = analoginput('adaptor')

AI = analoginput('adaptor', ID)

Arguments

adaptor
Name of the hardware driver adaptor
ID
Device identifier
AI
The analog input object

Description

analoginput creates an analog input object. This device object exists both in the data acquisition engine and the MATLAB workspace. When the object is created:

analoginput accepts one or two input arguments depending on the hardware you are accessing. The input arguments are given below.

Description
Supported Vendors and Devices

Sound Card
National Instruments
Hewlett-Packard
adaptor
winsound
nidaq
hpvxi
ID
N/A
Device number
Device ID

For National Instruments hardware, ID must be specified as a double. For Hewlett-Packard hardware, ID can be specified as a double or a string.

If the values supplied to analoginput are incomplete or incorrect, or the referenced driver is not found, then an error is returned. To use the analog input object to perform data acquisition tasks, hardware channels must be added with the addchannel function.

Example

Sound Card

To create an analog input object for a sound card

National Instruments

To create an analog input object for a National Instruments device defined as device number 1

Hewlett-Packard

To create an analog input object for a Hewlett-Packard (HP) VXI device with device ID 8 (slot 8)

The HP driver allows you to span multiple hardware. To span two HP VXI devices with device ID's 8 and 9

See Also

Functions

addchannel, analogoutput, digitalio



[ Previous | Help Desk | Next ]