Contenu principal

Configure AUTOSAR Adaptive Model for External Mode Simulation

R2026b

Embedded Coder® Support Package for Service-Oriented Applications on Linux® enables you to configure an AUTOSAR adaptive model for external mode simulation using XCP communication channel. Install the support package from Add-Ons button from MATLAB home. For more information about the support package, see Install Embedded Coder Support Package for Service-Oriented Applications on Linux (Embedded Coder).

Steps to enable external mode simulation:

  1. Open your AUTOSAR adaptive model.

  2. Set the Hardware board configuration parameter in the Hardware Implementation to Embedded Coder Linux Docker Container.

    Note

    Embedded Coder Linux Docker Container is only visible if the Embedded Coder Support Package for Service-Oriented Applications on Linux is installed.

  3. Enable the XCP service and configure the TCP port for XCP communication by using the linux.setXCPServiceConfiguration (Embedded Coder) function.

    linux.setXCPServiceConfiguration("myModel", Enabled=true, TCPPort=12345);

  4. Enable the External mode option in the Interface pane of Code Generation section.

  5. To log signals, select the signals you want to log and click the Log Signals in the Prepare pane of the Simulation section.

  6. Open the Linux Runtime Manager from the Simulink apps gallery. Alternatively, enter this command at the MATLAB Command Window.

    linuxRuntimeManager

  7. Deploy the model on the Linux target machine. See Build Simulink Model and Deploy Application (Embedded Coder) for more information.

  8. Select the model on the Linux Runtime Manager and click Monitor & Tune button. This will start the application and external mode simulation.

See Also

(Embedded Coder) | (Embedded Coder) | (Embedded Coder)

Topics