| Contents | Index |
xPC Target Library for UEI
Hardware Input | Block Output Data Type | Scaling |
|---|---|---|
Volts | Double | 1 |
Select the specific board type from the list provided.
Enter a vector of numbers that make up one scan. For example, to read the first and fifth channels, enter
[1 5]
The channel numbers can occur in any order. Number the channels beginning with 1 even though the board manufacturer numbers them beginning with 0. The maximum allowable channel number is 4, 8, 16, or 64 depending on the board type.
Enter a vector of numbers to specify the gains for each of the channels in the scan. Enter a single value to use the same gain for all vectors in the scan. Available gains vary depending on board type. Allowable values depend on the board type.
L (Low level) boards — Specify the gain as one of 1, 10, 100, or 1000.
H (High level) boards — Specify the gain as one of 1, 2, 4, or 8.
DG-option boards — Specify the gain as one of 1, 2, 5, or 10.
Enter a vector that is the same length as the channel vector. Each vector element must be a 0 or 1. If you specify 1, the corresponding channel has a longer settling time. To get a more accurate reading, you might want to specify a 1 for channels that have higher gains, such as 100 or 1000. Refer to the UEI PowerDAQ documentation for further information on the longer settling time. This time depends on the board type.
Caution With frame based acquisition, the additional time resulting from setting the Mux settling time vector (slow bit) might cause an acquisition overrun that the xPC Target software does not detect. For example, on a PD2-MF-xx-333/16H board, each acquisition takes 3 microseconds if the slow bit is 0. If the slow bit is 1, that same acquisition takes more than 10 microseconds. With the xPC Target software, the scan is performed at the maximum rate for a given board. This means that the slow acquisition takes a multiple of 3 microsecond ticks. For a PD2-MF-xx-333/16H board, this becomes 12 microseconds. For example, assume that N scans of the channel vector compose a frame of data. Assume also that you have a PD2-MF-xx-333/16H board with a Channel vector value of [1 2 3 4] and a Mux settling time vector (slow bit) value of [0 1 0 1]. For the PD2-MF-xx-333/16H board, two of the of the acquisition delays are 3 microseconds, and two are 12 microseconds. With a Block sampletime value of .001 second, if N is greater than 38, the data will not be acceptable. If you set all slow bits to 0, N can have a value of up to 83. The software detects the limit at N = 83, but is not aware of the extra board dependent delay. |
From the list, select one of the following voltage ranges. The value you select applies to all channels.
+-10 Volts
+-5 Volts
0-10 Volts
0-5 Volts
From the list, select one from the following list of input coupling modes:
Single Ended
Differential
Enter the number of samples per channel to return as a frame of data. Due to constraints in the hardware architecture, the total number of samples in a frame of data cannot exceed 512. The relationship between the number of samples, frame size, and number of channels is
total number of samples = FrameSize x nChannels
For example, if you specify two channels, the frame size must be less than or equal to 256.
From the list, select either Frame or Vector.
Frame — Select Frame if you expect the output signal from this block to be the input signal for a block that requires a frame. For example, a Signal Processing block.
Vector — Select Vector if you expect the output signal from this block to be the input signal for an xPC Target scope or some other block that requires vector input.
Select Internal or External to identify the clock source for the frame scans.
Enter the time (in seconds) between scans as the interval.
Enter the interval (in seconds) during which the board will interrupt. The driver block evenly spaces the scans in the frame across the Frame time interval. If the Frame time interval is too short, you will receive a buffer overrun error at run time. For optimal results, experimentally increase the Frame time value and reiterate the process. Always rebuild the model when you change this value.
The Frame size, Scan time, and Frame time parameters are not independent, but are related by
Frametime = Framesize × Scantime.
After you specify two of the parameters, specify -1 for the third parameter and the equation determines the third parameter.
Select this check box if the block is in an interrupt service routine (ISR). Selecting this check box forces the block sample time to –1, which enables the block to work in the ISR. If this check box is not selected, the block sample time is equal to the value of Frame time.
If you have multiple boards configured in a master/slave combination, select this box for the slave boards only. Leave the box unchecked for the master board. (Note that a single board configuration is considered a master board.)
Note In the model, set the priority of slave blocks higher than master blocks. Right-click the slave or master block and select Block Properties. In the dialog, enter a value in the Priority property. For example, if you have multiple slave blocks, you can enter values of 2 for the slave blocks and 3 for the master block, where a lower number indicates a higher priority. |
Enter the rate at which the high speed conversion clock runs. This is the clock used to acquire each scan in a frame. For example, with a PD2-MF-xx-333/16H board, the maximum clock is 333 kHz. At that rate, the second channel in a scan will be acquired 3 microseconds after the first one in every scan of the frame.
Specify -1 to select the maximum rate available for the specified board.
From the list, select either 32, 16, or 8. The DMA engine transfers data in packets of the burst size or less. Between each burst, a new bus arbitration cycle must complete. The best performance is achieved with higher DMA burst size values, with 32 being highest. However, in some architectures and with some PCI bus adaptors, a DMA burst size of 32 might cause problems. For example, it might lock up the target machine when DMA is attempted. In these cases, reduce the DMA burst size value to 8, rebuild and rerun the target application. If the DMA works at 8, select 16 to increase performance and try again.
If only one board of this type is in the target computer, enter
-1
to automatically 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
getxpcpci

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.
| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |