xPC Target    

Adding a Simulink Outport Block

If you want to log signal data to the MATLAB workspace for analysis and later save that data to a disk, you need to add a Simulink Outport block and activate logging from the Simulation Parameters dialog box.

The following procedure uses the Simulink model xpc_osc.mdl as an example. To create this model, see Creating a Simple Simulink Model.

  1. In the MATLAB Command Window, type
  1. The Simulink block diagram opens for the model xpc_osc.mdl.

  1. In the Simulink window, from the View menu, click Show Library Browser.
  1. The Simulink Library Browser window opens.

  1. In the left pane, double-click Simulink, and then click Sinks.
  1. In the right pane, the browser shows a list of sink blocks.

  1. Click-and-drag the Out1 block to your model and connect it to the output of the Mux block.
  1. Your model should look similar to the figure shown below.

  1. From the File menu, click Save as and enter a filename. For example, enter xpc_osc1 and then click OK.

Your next task is to enter parameters for the Outport block. See Entering Parameters for Outport Blocks.


  Creating a Simple Simulink Model Entering Parameters for Outport Blocks