Documentation |
Implement brushless DC motor drive using Permanent Magnet Synchronous Motor (PMSM) with trapezoidal back electromotive force (BEMF)
The high-level schematic shown below is built from six main blocks. The PMSM, the three-phase inverter, and the three-phase diode rectifier models are provided with the SimPowerSystems™ library. The speed controller, the braking chopper, and the current controller models are specific to the Electric Drives library. It is possible to use a simplified version of the drive containing an average-value model of the inverter for faster simulation.
The speed controller is based on a PI regulator, shown below. The output of this regulator is a torque set point applied to the current controller block.
The current controller contains four main blocks, shown below. These blocks are described below.
The T-I block performs the conversion from the reference torque to the peak reference current. The relation used to convert torque to current assumes pure rectangular current waveforms. In practice, due to the motor inductance, it's impossible to obtain these currents. Therefore the electromagnetic torque may be lower than the reference torque, especially at high speed.
The Hall decoder block is used to extract the BEMF information from the Hall effect signals. The outputs, three-level signals (−1, 0, 1), represent the normalized ideal phase currents to be injected in the motor phases. These type of currents will produce a constant torque. The following figure shows the BEMF of phase A and the output of the Hall decoder for the phase A.
The current regulator is a bang-bang current controller with adjustable hysteresis bandwidth.
The Switching control block is used to limit the inverter commutation frequency to a maximum value specified by the user.
When using the average-value inverter, the abc current references are sent to the simplified inverter.
The braking chopper block contains the DC bus capacitor and the dynamic braking chopper, which is used to absorb the energy produced by a motor deceleration.
The average-value inverter is shown in the following figure.
It is composed of one controlled current source on the DC side and of two controlled voltage sources on the AC side. The DC current source allows the representation of the DC bus current behavior described by the following equation:
I_{dc} = (P_{out} + P_{losses}) / V_{in},
with P_{out} being the output AC power, P_{losses} the losses in the power electronic devices, and V_{in} the DC bus voltage.
On the AC side, the voltage sources are fed by the instantaneous voltages provided by the Trapezoidal PMSM dynamic model (see PMSM documentation for machine model). This dynamic model takes the reference currents (the rate of these currents has been limited to represent the real life currents), the measured BEMF voltages and the machine speed to compute the terminal voltages to be applied to the machine.
The dynamic rate limiter limits the rate of the reference currents when transitions occurs. The rate depends of the inverter saturation degree.
During loss of current tracking due to insufficient inverter voltage, the dynamic rate limiter saturates the reference current in accordance to this operation mode.
The model is discrete. Good simulation results have been obtained with a 2 µs time step. To simulate a digital controller device, the control system has two different sampling times:
Speed controller sampling time
Current controller sampling time
The speed controller sampling time has to be a multiple of the current controller sampling time. The latter sampling time has to be a multiple of the simulation time step. The average-value inverter allows the use of bigger simulation time steps since it does not generate small time constants (due to the RC snubbers) inherent to the detailed converter. For a current controller sampling time of 40 µs, good simulation results have been obtained for a simulation time step of 40 µs. The simulation time step can, of course, not be higher than the current controller time step.
The Permanent Magnet Synchronous Machine tab displays the parameters of the Permanent Magnet Synchronous Machine block of the powerlib library.
Select how the output variables are organized. If you select Multiple output buses, the block has three separate output buses for motor, converter, and controller variables. If you select Single output bus, all variables output on a single bus.
Select between the detailed and the average-value inverter.
Select between the load torque, the motor speed and the mechanical rotational port as mechanical input. If you select and apply a load torque, the output is the motor speed according to the following differential equation that describes the mechanical system dynamics:
$${T}_{e}=J\frac{d}{dt}{\omega}_{r}+F{\omega}_{r}+{T}_{m}.$$
This mechanical system is included in the motor model.
If you select the motor speed as mechanical input, then you get the electromagnetic torque as output, allowing you to represent externally the mechanical system dynamics. The internal mechanical system is not used with this mechanical input selection and the inertia and viscous friction parameters are not displayed.
For the mechanical rotational port, the connection port S counts for the mechanical input and output. It allows a direct connection to the Simscape™ environment. The mechanical system of the motor is also included in the drive and is based on the same differential equation.
The rectifier section of the Converters and DC bus tab displays the parameters of the Universal Bridge block of the powerlib library. Refer to the Universal Bridge for more information on the universal bridge parameters.
The inverter section of the Converters and DC bus tab displays the parameters of the Universal Brige block of the powerlib library. Refer to the Universal Bridge for more information on the universal bridge parameters.
The average-value inverter uses the following parameter.
The on-state resistance of the inverter switches (ohms).
The DC bus capacitance (F).
The braking chopper resistance used to avoid bus over-voltage during motor deceleration or when the load torque tends to accelerate the motor (ohms).
The braking chopper frequency (Hz).
The dynamic braking is activated when the bus voltage reaches the upper limit of the hysteresis band. The following figure illustrates the braking chopper hysteresis logic.
The dynamic braking is shut down when the bus voltage reaches the lower limit of the hysteresis band. The chopper hysteresis logic is shown in the following figure.
This pop-up menu allows you to choose between speed and torque regulation.
When you press this button, a diagram illustrating the speed and current controllers schematics appears.
The speed measurement first-order low-pass filter cutoff frequency (Hz). This parameter is used in speed regulation mode only.
The speed controller sampling time (s). The sampling time must be a multiple of the simulation time step.
The maximum change of speed allowed during motor acceleration (rpm/s). An excessively large positive value can cause DC bus under-voltage. This parameter is used in speed regulation mode only.
The maximum change of speed allowed during motor deceleration (rpm/s). An excessively large negative value can cause DC bus overvoltage. This parameter is used in speed regulation mode only.
The speed controller proportional gain. This parameter is used in speed regulation mode only.
The speed controller integral gain. This parameter is used in speed regulation mode only.
The maximum negative demanded torque applied to the motor by the current controller (N.m).
The maximum positive demanded torque applied to the motor by the current controller (N.m).
The current controller sampling time (s). The sampling time must be a multiple of the simulation time step.
The current hysteresis bandwidth. This value is the total bandwidth distributed symmetrically around the current set point (A). The following figure illustrates a case where the current set point is Is^{*} and the current hysteresis bandwidth is set to dx.
This parameter is not used when using the average-value inverter.
The speed or torque set point. The speed set point can be a step function, but the speed change rate will follow the acceleration / deceleration ramps. If the load torque and the speed have opposite signs, the accelerating torque will be the sum of the electromagnetic and load torques.
The mechanical input: load torque (Tm) or motor speed (Wm). For the mechanical rotational port (S), this input is deleted.
The three phase terminals of the motor drive.
The mechanical output: motor speed (Wm), electromagnetic torque (Te) or mechanical rotational port (S).
When the Output bus mode parameter is set to Multiple output buses, the block has the following three output buses:
The motor measurement vector. This vector allows you to observe the motor's variables using the Bus Selector block.
The three-phase converters measurement vector. This vector contains:
The DC bus voltage
The rectifier output current
The inverter input current
All current and voltage values of the bridges can be visualized with the Multimeter block.
The controller measurement vector. This vector contains:
The torque reference
The speed error (difference between the speed reference ramp and actual speed)
The speed reference ramp or torque reference
When the Output bus mode parameter is set to Single output bus, the block groups the Motor, Conv, and Ctrl outputs into a single bus output.
The library contains a 3 hp drive parameter set. The specifications of the 3 hp drive are shown in the following table.
3 HP Drive Specifications
Drive Input Voltage | ||
---|---|---|
Amplitude | 220 V | |
Frequency | 60 Hz | |
Motor Nominal Values | ||
Power | 3 hp | |
Speed | 1650 rpm | |
Voltage | 300 Vdc |
The ac7_example example illustrates an AC7 motor drive simulation with standard load condition. At time t = 0 s, the speed set point is 300 rpm.
There are two design tools in this example. The first block calculates the gains of the speed regulator in accordance with your specifications. The second block plots the operating regions of the drive. Open these blocks for more information.
As shown in the following figure, the speed precisely follows the acceleration ramp. At t = 0.5 s, the nominal load torque is applied to the motor. At t = 1 s, the speed set point is changed to 0 rpm. The speed decreases to 0 rpm. At t = 1.5 s., the mechanical load passes from 11 N.m to −11 N.m. The next figure shows the results for the detailed converter and for the average-value converter. Observe that the average voltage, current, torque, and speed values are identical for both models. Notice that the higher frequency signal components are not represented with the average-value converter.
AC7 Example Waveforms (Blue: Detailed Converter, Red: Average-Value Converter)
[1] Bose, B. K., Modern Power Electronics and AC Drives, Prentice-Hall, N.J., 2002.
[2] Krause, P. C., Analysis of Electric Machinery, McGraw-Hill, 1986.
[3] Tremblay, O., Modélisation, simulation et commande de la machine synchrone à aimants à force contre-électromotrice trapézoïdale, École de Technologie Supérieure, 2006.