xPC Target    

Marking Block Signals

Tagging signals in your Simulink model allows the function xpcsliface to create From xPC Target interface blocks. These interface blocks contain the signals you connect to display devices (gauges) in your user interface model.

After you create a Simulink model, you can mark the block signals. This procedure uses the model xpc_tank1.mdl (or xpctank.mdl) as an example. See Creating a Target Application Model.

Notice that you cannot select signals on the output ports of any virtual blocks such as Subsystems and Mux blocks. Also, you cannot select signals on any Function-call, triggered signal output ports.

  1. Open a Simulink model. For example, in the MATLAB Command Window, type
  2. Point to a Simulink signal line, and then right-click.
  3. From the menu, click Signal Properties.

  1. A Signal Properties dialog box opens.

  1. In the Description box, enter a tag to the signals for this line.
  1. For example, the TankLevel block is an integrator with a single signal that indicates the level of water in the tank. Enter the tag shown below.

    The tag has the following syntax:

    For single dimension ports, the following syntax is also valid:

To create the From xPC blocks in an user interface model for a signal line with four signals (port dimension of 4), use the following syntax:

To create the From xPC blocks for the second and fourth signals in a signal line with at least four signals, use the following syntax:

  1. From the File menu, click Save as. Enter a file name for your model. For example, enter

You next task is to mark block parameters if you have not already done so, and then create the user interface template model. See Marking Block Parameters and Creating a User Interface Model.


  Marking Block Parameters Description of the User Interface Model