Documentation

This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

ssGetSimStatus

Get the current simulation status of an S-Function block

Syntax

ssGetSimStatus(SimStruct *S, SS_SimStatus *status)

Arguments

S

SimStruct representing an S-Function block.

status

SS_SimStatus object that returns the current simulation status.

Description

Determines the simulation status of the block represented by S and stores the value in the SS_SimStatus object status. The variable status can have one of the following values, defined in simstruc_types.h:

  • SIMSTATUS_STOPPED

    The simulation has terminated

  • SIMSTATUS_UPDATING

    The Simulink® engine is updating the model

  • SIMSTATUS_INITIALIZING

    The simulation is initializing

  • SIMSTATUS_RUNNING

    The simulation is running

  • SIMSTATUS_PAUSED

    The simulation is paused

  • SIMSTATUS_TERMINATING

    The simulation is terminating

  • SIMSTATUS_EXTERNAL

    The simulation is running in external mode

Languages

C, C++

Example

The following lines obtain the current simulation status:

SS_SimStatus status;        // Define the return variable
ssGetSimStatus(S, &status);

Introduced in R2008a

Was this topic helpful?