主要内容

Deploy and Run SOA Applications

R2026b

Multiple approaches are available for build, package, deploy, and run service-oriented architecture (SOA) applications. The approach you should choose depends on your development and target environment and on available or preferred tooling.

Once an application is running in the target environment, tools are available for tuning parameters, monitoring signal data, and logging signal and output data to an Association for Standardization of Automation and Measuring (ASAM) Measurement Data Format (MDF) file that you can then import into the Simulation Data Inspector for analysis.

Choose a Deployment Approach

Use this table as a guide for choosing a deployment approach.

Deployment ApproachReasons to Choose
Linux Runtime Manager app
  • Embedded Coder® Support Package for Service-Oriented Applications on Linux® is installed.

  • Deploy and run on your Linux development computer.

  • Deploy and run on an ARM® 64 or x86_64 target computer that runs the Linux operating system.

  • Deploy to a Docker® container that runs on your development computer or a target computer.

  • Want to tune parameters and monitor signals as a deployed system runs in the target environment.

Run on Custom Hardware app
  • Deploy and run on a development computer that runs the Linux operating system.

  • Deploy and run on a custom target hardware board that runs the Linux operating system.

  • Want to tune parameters and monitor signals as a deployed system runs in the target environment.

packNGo function
  • Relocate generated application code to a development environment that does not provide MATLAB® or Simulink®

  • Embedded Coder Support Package for Service-Oriented Applications on Linux is not installed.

  • You are unable to or do not want to deploy to a Docker container.

  • Deploy and run on an unsupported target hardware board that runs the Linux operating system.

Deploy By Using Linux Runtime Manager App

You can use the Linux Runtime Manager to deploy a system of applications if the Embedded Coder Support Package for Service-Oriented Applications on Linux is installed on your development computer. Using the Linux Runtime Manager, you can build, package, deploy, and run SOA application code on an ARM 64 Linux target computer.

For information on how to set up a target computer for use with the Linux Runtime Manager and how to build software component models and deploy applications, see Set Up Linux Target Computer and Build Simulink Model and Deploy Application, respectively.

Deploy By Using Run on Custom Hardware App

The Run on Custom Hardware app enables you to:

  • Build, deploy, and run the SOA application code on your development computer or a target computer by using external mode and XCP communication.

  • Perform the steps to build, deploy, connect, and run separately or with one click.

  • Use an external mode simulation for parameter tuning and signal monitoring.

To establish an external mode connection, instead of setting model configuration parameters, use the Run on Custom Hardware app to specify connection settings.

  1. In the Software Component Designer app, open a software component model that you want to connect to a target computer.

  2. Open the Run on Custom Hardware app.

  3. Specify a hardware board. In the toolstrip, on the Hardware tab, from the Hardware menu, select the board setting for your development or target computer.

  4. Specify a TCP/IP connection. From the Connection menu, select TCP - IP Address: "localhost" - Port:17725", the default connection settings, or Change Connection. If you select Change Connection, the app displays a TCP/IP connection parameters dialog box. In the dialog box, enter the target computer IP address and TCP port number, and click OK.

  5. In the toolstrip, in the Run on Hardware section, specify a stop time (in minutes) and click Monitor and Tune and choose between using one-click or step-by-step commands for performing these actions:

    1. Build the target application on your development computer.

    2. Deploy the application to the target computer.

    3. Connect Simulink to the application that runs on the target computer.

    4. Start execution of the application on the target computer.

This table shows the workflow support that the app provides for your target hardware.

Workflow Feature or TaskTarget Computer
Development ComputerCustom Target Hardware

One-click

Yes

Yes, if you set up connectivity between Simulink and your target hardware.

Step-by-step

Build for Monitoring

Yes

Yes. Software builds target application on development computer by using the toolchain that you specify.

Deploy

Yes

Yes, if you set up connectivity between Simulink and your target hardware.

Connect

Yes

Yes

Start

Yes

Yes

For information on how to set up external mode connectivity programmatically, see Set Up External Mode Connectivity Between Simulink and Target Hardware.

Relocate Application Code to a Development Environment By Using packNGo Function

If your development environment does not provide MATLAB or Simulink, use the packNGo function to package generated application code files in a ZIP file so that you can relocate, unpack, and build or rebuild them in another development environment.

For information, see Relocate or Share Generated Code and Compile Code in Another Development Environment.

Tune Parameters and Monitor Signals

If you need to calibrate a software component model, set up the model so you can tune parameters and monitor signal data as the code runs on the target computer.

To enable parameter tuning and signal monitoring for a component model, before you build the model and deploy the application to the target computer, identify parameters that you want to tune and signals that you want to monitor. Then, see the topic in this table that aligns with your deployment approach:

Log Application Execution Results to an MDF File

You can generate application code from a component model that logs signal and output data to an Association for Standardization of Automation and Measuring (ASAM) Measurement Data Format (MDF) file for analysis.

  1. In the component model, specify signals and output data that you want the generated code to log.

  2. Configure the component model for data logging. Select these model configuration parameters:

  3. Build the application.

  4. Deploy and run the application on the target computer.

  5. View the time series of generated code variables by doing one of the following

For more detail and an example, see Log signals to MDF file.

See Also

| | |

Topics