Contenuto principale

Simulink Real-Time Deployment Approaches

Deploying a real-time application consists of building a real-time application on the development computer and installing it on the target computer. There are several ways to deploy a real-time application:

  • Simulink Editor — From the Real-Time tab, click Run on Target. This selection provides a one-click operation for a model build, a real-time application load onto the target computer, and an application start on the target computer. You can use the UI for step-by-step build, load, connect model, and start operation by selecting from the buttons available from Run on Target.

  • Simulink Real-Time Explorer — If you have completed the model build, you can use the Simulink Real-Time Explorer to load the real-time application onto the target computer and start the application.

  • MATLAB commands — To deploy a real-time application to the target computer, in the MATLAB Command Window, type:

    tg = slrealtime;
    % creates target object tg for the default target computer
    
    connect(tg);
    % connects Simulink Real-Time to the target computer
    
    slbuild('model_name');
    % builds the real-time application from the model
    
    load(tg,'model_name');
    % installs the real-time application and loads 
    % it on the target computer
    
    start(tg);
    % starts the real-time application run
    
    % let the application run until stop time expires or . . .
    
    stop(tg);
    % stops the real-time application run

After you deploy the real-time application to the target computer, you can configure the target computer to run the application as the startup application when you start the target computer. This configuration is useful when you use the target computer for standalone mode operation instead of using the target computer for connected mode operation. For more information, see Deploy and Configure a Startup Real-Time Application.

See Also

Topics