Documentation

General Standards PMC-ADADIO Analog Output Write Block

PMC-ADADIO Analog Output Write block

Library

Simulink® Real-Time™ Library for General Standards

Note

Data from 1 to 4 input data streams is written to the digital to analog output registers when the enable port also receives a true value. If the enable port is not used, then it is assumed to be set to true. The output registers are held and not written through to the output converters until the analog output update block is executed.

Scaling Input to Output

I/O Module Output

Block Input Data Type

Scaling

Volts

Double

1

The values passed to the enable input port and enable output port of this block are Boolean values.

Block Parameters

Channel vector

Enter a vector of numbers between 1 and 4 to select the analog output lines to drive. Number the lines beginning with 1 even if this board manufacturer starts numbering the lines with 0.

Reset vector

The reset vector controls the behavior of the channel at model termination. Enter a scalar or a vector that is the same length as the channel vector. If you specify a scalar value, that setting is replicated over the channel vector. If you specify a value of 1, the corresponding channel is reset to the value specified in the initial value vector. If you specify a value of 0, the channel remains at the last value attained while the model was running. For example, if Channel vector is [ 2 3 ] and the Reset vector is [1], the action taken will be the same as if Reset vector was set to [1 1]. Both channels will be reset to their initial values when model execution is stopped.

Initial value vector

The initial value vector contains the initial voltage values for the output channels. Enter a scalar or a vector that is the same length as the channel vector. If you specify a scalar value, that value is replicated as initial value over the channel vector. The channels are set to the initial values between the time the model is downloaded and the time it is started. When model execution is stopped, the corresponding position in Reset vector is checked. Depending on that value, the channel is either reset to the initial value or remains at the last value attained while the model was running. For example, assume that Channel vector is [2 5 8], Reset vector is [1 0 1], and Initial value vector is [2.3 5.6 0]. On initial download, channel 2 is set to 2.3 volts, channel 5 to 5.6 volts, and channel 8 to 0.0 volts. When the model is stopped, channel 2 resets to 2.3 volts, channel 5 remains at the last value attained, and channel 8 resets to 0.0 volts.

Range vector

From the list, select ±10V, ±5V or ±2.5V as the output voltage range of the board. You must select the range that corresponds to the factory configured output range. Consult the manufacturer documentation to determine the voltage range of your board. The Simulink Real-Time software uses this parameter to convert the data from floating point numbers to integers.

Autocalibration

The PMC-ADADIO can check its own calibration (autocalibration) against an internal voltage reference. Choose this check box to execute the autocalibration cycle when the model is downloaded to the target computer. The output ports show a square wave during the cycle. Unless you subject this board to harsh conditions, you should only need to run autocalibration occasionally— for example, once a month.

    Note:   The calibration cycle takes several seconds to run. Refer to the manufacturer documentation for further information on autocalibration.

Enable input port

Select this check box to display an input enable port that controls writing data to the D/A ports on the I/O module. If the enable input signal is true, then the block input data is written to the D/A ports. If the enable input signal is false, then data is not written to the D/A ports and the output remains at the previous value. If this check box is not selected, then the enable input signal is assumed to be true.

Enable output port

Select this check box to pass the Boolean value from the input enable port to the output enable port. You can connect this port to the input enable port on another block to control other blocks in the model and specify execution ordering.

Sample time

Enter the base sample time or a multiple of the base sample time (-1 means sample time is inherited).

PCI slot (-1:autosearch)

If only one board of this type is in the target computer, enter -1 to locate the board.

If two or more boards of this type are in the target computer, enter the bus number and the PCI slot number of the board associated with this driver block. Use the format [BusNumber,SlotNumber].

To determine the bus number and the PCI slot number, type:

tg = slrt;
getPCIInfo(tg, 'installed')

External Websites

Was this topic helpful?