DefaultChannelValue

Specify value held by analog output subsystem

Description

DefaultChannelValue specifies the value to write to the analog output (AO) subsystem when data is finished being output from the engine.

DefaultChannelValue is used only when OutOfDataMode is set to DefaultValue. This property guarantees that a known value is held by the AO subsystem if a run-time error occurs. Note that sound cards do not have an OutOfDataMode property.

Characteristics

Usage

AO, per channel

Access

Read/write

Data type

Double

Read-only when running

Yes

Values

The default value is zero.

Examples

Create the analog output object ao and add two channels to it.

ao = analogoutput('nidaq','Dev1');
addchannel(ao,0:1);

You can configure ao so that when it stops outputting data, a value of 1 volt is held for both channels.

ao.OutOfDataMode = 'DefaultValue';
ao.Channel.DefaultChannelValue = 1.0;

See Also

Properties

OutOfDataMode

Was this topic helpful?