sschdl.generateOptimizedModel
Replace Simscape switches and converter blocks with dynamic switches optimized for FPGA deployment
Since R2024a
Syntax
Description
replaces common Simscape™ switches and converter blocks with their dynamic equivalents to optimize the
model for FPGA deployment. To learn more about dynamic switch replacement, see Generate HDL Code for Simscape Models by Using Dynamic Switch Approximation. generatedModel
= sschdl.generateOptimizedModel(input
)
replaces Simscape switches or PMSM (Simscape Electrical) block with a dynamic equivalent
using one or more name-value pair arguments.generatedModel
= sschdl.generateOptimizedModel(input
,Name,Value
)
The function supports replacement of these blocks:
Switches — Switch (Simscape), Ideal Semiconductor Switch (Simscape Electrical), Diode (Simscape Electrical), Diode (Simscape), IGBT (Ideal, Switching) (Simscape Electrical), MOSFET (Ideal, Switching) (Simscape Electrical), and Averaged Switch (Semiconductor switch with an anti-parallel diode)
Converter blocks — Bidirectional DC-DC Converter (Simscape Electrical), Boost Converter (Simscape Electrical), Buck Converter (Simscape Electrical), Buck-Boost Converter (Simscape Electrical), Converter (Three-Phase) (Simscape Electrical), Rectifier (Three-Phase) (Simscape Electrical), and Three-Level Converter (Three-Phase) (Simscape Electrical)
PMSM (Simscape Electrical)
The generated optimized model has the same name as input
but
with the suffix _generated
. Once the optimized model is generated, open
the model and verify the connection. Connect any gate signal inports of the replaced
blocks to their respective sources and remove any additional Simulink-PS Converter (Simscape) blocks.
Examples
Input Arguments
Output Arguments
Limitations
This function does not support all switches and converter blocks. Only listed switches and converter blocks are supported.
In the model, if a parameter references any workspace variable or an expression then the parameter value is replaced by the evaluated value.