SimElectronics is used to optimize system-level performance and to create plant models for control design. The models you create support your entire development process, including hardware-in-the-loop simulations.
SimElectronics provides libraries of motors, actuators, drivers, and sensor components. You can connect components, such as H-bridges, servomotors, and potentiometers, to model mechatronic systems. The models you create can be grouped into subsystems, enabling you to build libraries of mechatronic components, such as those used in robotics, aircraft actuation, and active vehicle systems. Connecting these systems with control systems modeled in Simulink® lets you test integrated mechatronic systems in a single environment.
In addition to the traditional input-output or signal flow connections used in Simulink, SimElectronics uses physical connections that permit the flow of power in any direction. Models of mechatronic systems built using physical connections (or acausal models) closely resemble the physical system they represent, and are easier to understand and share.
Modeling a Mechatronic System
Model a mechatronic system in the Simulink® environment. A model of an electrical motor and motor driver is connected to a three-dimensional mechanical model of an aileron.
Many of the component models in SimElectronics let you adjust the level of fidelity. You can either include or neglect certain effects, such as temperature-dependent behavior. For systems using pulse-width modulation (PWM), you have the option of setting the simulation mode to Averaged for faster simulation or to PWM to see the effects of switching on your system.
To help you specify realistic parameter values, various parameterization methods are provided for many components. You can read parameter values directly from data sheets or assign equivalent circuit parameters.
SimElectronics provides libraries of semiconductors, integrated circuits (behavioral models), and passive devices. You can connect transistors, diodes, op-amps, and other components to model electronic systems. The models you create can be grouped into subsystems, letting you build reusable libraries of circuit components. Connecting these electronic systems with control systems modeled in Simulink enables you to combine digital control with behavioral models of analog circuits.
In addition to the traditional input-output or signal flow connections used in Simulink, the electronic component models in SimElectronics use physical connections that permit the flow of power in any direction. Models of electronic systems built using physical connections closely resemble the electronic circuit they represent and are easier to understand and share.
The transistor models in SimElectronics include nonlinearities and high-frequency dynamics to help you capture these effects in simulation. Many components in SimElectronics enable you to specify temperature-dependent behavior and configure a thermal connection to model the heat transfer within your system.
To help you specify realistic parameter values, various parameterization methods are provided for many components. You can read parameter values directly from data sheets or assign the equation parameters.
You can add components from other physical modeling products to your SimElectronics model. The foundation library in Simscape contains blocks in hydraulic, thermal, magnetic, and other physical domains. Integrating these domains into your SimElectronics model using physical connections helps you model other aspects of your system in a single environment.
Simscape is an object-oriented language based on MATLAB® that enables you to create your own physical modeling components and libraries. You can define custom components complete with parameterization, physical connections, and equations represented as acausal implicit differential algebraic equations (DAEs). Within your component’s Simscape language file, you can use MATLAB to analyze parameter values, perform preliminary computations, and initialize system variables. The Simulink block and dialog box for your custom component are automatically created from the file.
Simscape Language: Electronic Example
Model custom electronic components using the Simscape™ language. Define a resistor whose behavior varies with temperature.
Using the Simscape language, you can control exactly which effects are captured in the models of your physical components. This approach enables you to balance the tradeoff between model fidelity and simulation speed.
You can perform transient simulation of SimElectronics models. The simulations can be run on your desktop (variable step) or in a real-time environment (fixed step). Every aspect of your simulation can be automated using scripts in MATLAB, including configuring the model, entering simulation settings, and running batches of simulations. The steady-state solve capability can be used to reduce simulation time by automatically removing unwanted transients at the start of simulation.
Optimization algorithms enable you to automatically tune parameters in simulation. This approach enables you, for example, to find designs that minimize power consumption or required actuator torque. To accelerate optimization tasks and other design studies that require many simulations, you can use Parallel Computing Toolbox™ to distribute your SimElectronics simulations across multiple cores or a cluster of computers.
Optimizing System Performance: DC Motor
Automatically tune the performance of a controlled DC motor to meet system requirements using optimization algorithms.
All the simulation data from your SimElectronics model can be saved automatically to the MATLAB workspace. Using MATLAB, you can analyze, plot, animate, and save the results of your simulation in many different file formats. You can perform tasks such as analyzing the frequency response of the circuit, comparing simulation runs to improve the control algorithm, and verifying the timing of switching events during simulation. With Simulink Report Generator™, the results of SimElectronics simulations can be automatically saved in a report, along with screenshots of the model, plots, and other information.
To analyze the frequency domain behavior of your system, you can generate a continuous-time or discrete-time linear model from your nonlinear SimElectronics model. The linear model can be used to study the system dynamics and to support controller design by applying linear control theory.
You can deploy SimElectronics models using code generated with Simulink Coder. The generated code lets you:
Simulating in Real Time: Electrical Actuator
Configure multiple, independent solvers to enable real-time simulation. A model of an aileron actuator is simulated on a real-time target.
You can share SimElectronics models with Simscape users who have not purchased SimElectronics. Simscape users can view, simulate, and change parameter values in SimElectronics models by leveraging the Simscape Editing Modes. As a result, your team can share SimElectronics models with a larger group of engineers who use Simscape.
Sharing Models Using Simscape Editing Mode
Share models without requiring licenses for Simscape™ add-on libraries. Open models in Restricted Mode and perform tasks such as simulation, parameter tests, and code generation.
|Working with SimElectronics Models|
(Purchases Simscape and SimElectronics)
|Log data or change visualization|
|Change numerical parameters|
|Generate code with Simulink Coder|
|Change block parameterization options|
|Make or break physical connections|