Each new release, I am always excited to share my favorite new Simulink features. As Simulink and our modeling and simulation technologies continue to mature, I am noticing that my release highlights are becoming more geared toward workflows than single features – and this is exciting!
Here is my top three for what's new in Simulink R2023a.
Simulink Debugger
In R2023a, we finally retired the old Simulink Debugger. To replace it, we are introducing the capability to step block by block in the Simulink canvas. I plan to follow up with a blog post dedicated to this, but here is an animation to give you an idea of what this new feature looks like. What you will see: - I added a breakpoint for the simulation to break when the output of the Sum block is greater than or equal to zero.
- I enabled the new option "Pause within time step" to allow block-by-block stepping.
- I enabled Port Value Display for most signals in the model. (For that, hit Ctrl+A to Select All and click on "Show port value display label on selected signals" in the toolstrip)
- The Step In button allows to step inside MATLAB Function blocks and Stateflow charts seamlessly.
- It is also possible to step block-by-block in Iterator Subsystems.
Variant Assembly Subsystem
This feature was introduced in MATLAB R2022b, but I decided to wait before highlighting it because we added enhancements making it more useful in R2023a.
The key advantage of the Variant Assembly Subsystem is that it enables you to add or remove variant choices without modifying the model. All you have to do is specify a list of Subsystem or Model files to be included as variant choices. This can be done in two ways.
Option 1: Label mode
When the variant control mode is set to Label, the list of variant choices is specified using the Variant choices specifier field. In this field, you can type anything that will be evaluated as a cell array of strings, where each string is the name of a model on the MATLAB path: With the model configured as in the above screenshot, if I was to receive a new Subsystem or Model, I could simply place it in the folder Controller_subsystem_choices and it would automatically become a new available variant choice.
Option 2: Expression Mode
When the variant control mode is set to Expression, the list of variant choices is specified through an enumeration, where each member is the name of a model on the MATLAB path. where the enumeration is defined as:
As it is the case for the Variant Subsystem, expression mode enables the Variant Assembly Subsystem to support all the activation times. Display of Parameter Values in Simscape blocks
Now it's your turn
Have a look at the R2023a release notes and let us know in the comments below which R2023a features you would like to see covered on this blog.
评论
要发表评论,请点击 此处 登录到您的 MathWorks 帐户或创建一个新帐户。