This migration workflow helps you migrate legacy SimEvents® models to R2016a or later. In this workflow, you create a new SimEvents model to replace your legacy SimEvents model. This is an iterative workflow that requires you to repeat some steps.
Before you start, copy your legacy model to a backup folder. Run the old model and collect the results using the Simulation Data Inspector (Inspect Simulation Data (Simulink)).
Pre-R2016a SimEvents blocks cannot coexist in a model with post-R2016a SimEvents blocks.
Identify and redefine entity types (Identify and Redefine Entity Types)
When possible, replace old blocks with new blocks (Replace Old Blocks) and reconfigure the new blocks.
Write event actions for these instances:
Replace Set Attribute blocks with event actions in other blocks (Replace Set Attribute Blocks with Event Actions)
Replace Get Attribute blocks with event actions in other blocks (Connect Signal Ports)
Replace Attribute Function blocks with event actions in other blocks (Replace Attribute Function Blocks with Event Actions)
Replace random number generators with event actions in other blocks (Replace Random Number Distributions in Event Actions)
Replace reactive ports (see If Connected to Reactive Ports).
Determine a strategy to observe output by replacing Discrete Event Signal to Workspace blocks with To Workspace blocks or logging (Observe Output).
Verify the results by running the simulation and using Simulation Data Inspector to compare these results with those you collect in step 1.