Write to a block state
Simulink / Signal Routing
The State Writer block sets the state of a supported state owner block. When creating a library block with a State Writer block also include the state owner block.
Add a State Writer block to your model from the Simulink® Library Browser.
State Writer blocks can write state to these state owner blocks:
Discrete State-Space
Discrete-Time Integrator
Delay
Unit Delay
Discrete Transfer Fcn
Discrete Filter
Discrete FIR Filter
Integrator
Second-Order Integrator
Conditional subsystem blocks such as Enabled Subsystem, Triggered Subsystem, and Function-Call Subsystem.
S-Function with multiple discrete states.
To configure an S-Function block as a state owner block, exactly one data type work vector must be declared as discrete state vector using ssSetDWorkUsedAsDState and named using ssSetDWorkName or ssSetDWorkRTWIdentifier in mdlInitializeSizes.
Data Types |
|
Direct Feedthrough |
|
Multidimensional Signals |
|
Variable-Size Signals |
|
Zero-Crossing Detection |
|