| Contents | Index |
xPC Target Library for Misc.
Intel 80x86 and compatible processors have a special address space reserved for I/O devices.
To access this special address space and communicate directly to a device, the xPC Target block library provides the I/O Port Read and I/O Port Write blocks. These blocks enable the transfer of data from and to the I/O ports (see also, I/O Port Read).
Double click the I/O Port Write block.
The Block Parameters: I/O Port Write dialog box opens.
For example, if you want to write a double word (32 bits) starting at I/O port 0x300, followed by a word (16 bits) at 0x304, enter
{'0x300','0x304'}Your dialog box should look similar to the figure shown below.

The number of inputs to the block changes to reflect the length of the I/O-Port address cell array. The data type of the input signal reflects the type of value written to the I/O port. For example, an input signal of type uint32 writes a double word, an uint16 input signal writes a word, and an uint8 input signal writes a byte.
This is the cell array containing the I/O port addresses for the data that you want read. These addresses are specified in terms of hexadecimal strings.
Enter a base sample time or a multiple of the base sample time.

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 |