PM Synchronous Motor Drive
Implement Permanent Magnet Synchronous Motor (PMSM) vector control drive
Description

The high-level schematic shown below is built from six main blocks. The PMSM motor, the three-phase inverter, and the three-phase diode rectifier models are provided with the SimPowerSystems library. More details on these three blocks are available in the SimPowerSystems user guide. The speed controller, the braking chopper, and the vector controller models are specific to the drive library. It is possible to use a simplified version of the drive containing an average-value model of the inverter for faster simulation.
High-Level Schematic

Simulink Schematic

Speed Controller
The speed controller is based on a PI regulator, shown below. The output of this regulator is a torque set point applied to the vector controller block.

Vector Controller
The vector controller contains four main blocks, shown below. These blocks are described below.

The dq-abc block performs the conversion of the dq current component in the rotor reference frame into abc phase variables.
The current regulator is a bang-bang current controller with adjustable hysteresis bandwidth.
The angle conversion block is used to compute the electrical rotor angle from the mechanical rotor angle.
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 ab current references are sent to the inverter, as well as switching pulses from a slightly modified Switching control block.
Braking Chopper
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.
Average-Value Inverter
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 current sources and two controlled voltage sources on the AC side. The DC current source allows the representation of the average DC bus current behavior following the next equation:

with being the output power, the losses in the power electronic devices, and the DC bus voltage.
On the AC side, the current sources represent the average phase currents fed to the motor. The regulation being fast, the current values are set equal to the current references sent by the current regulator. A small current is injected to compensate for the current drawn by the three-phase load (needed because of the inverter current sources in series with inductive motor).
During loss of current tracking due to insufficient inverter voltage, the currents are fed by two controlled voltage sources. These voltage sources represent the square wave mode and allow good representation of the phase currents during inverter saturation. Each voltage source outputs either Vin or 0, depending on the values of the pulses (1 or 0) sent by the current controller.
Remarks
The model is discrete. Good simulation results have been obtained with a 2 time step. To simulate a digital controller device, the control system has two different sampling times:
1 Speed controller sampling time
2 Vector controller sampling time
The speed controller sampling time has to be a multiple of the vector 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 vector controller sampling time of 75 µs, good simulation results have been obtained for a simulation time step of 75 µs. The simulation time step can, of course, not be higher than the vector controller time step.
The stator current direct component id* is set to zero inside the vector controller block because the rotor flux is supplied by the permanent magnets.
Mechanical input
Allows you to select either the load torque or the motor speed as mechanical input. Note that if you select and apply a load torque, you will obtain as output the motor speed according to the following differential equation that describes the mechanical system dynamics:

This mechanical system is included in the motor model.
However, if you select the motor speed as mechanical input then you will get the electromagnetic torque as output, allowing you to represent externally the mechanical system dynamics. Note that the internal mechanical system is not used with this mechanical input selection and the inertia and viscous friction parameters are not displayed.
Rectifier section
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.
Inverter section
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.
Braking Chopper Section
Resistance
The braking chopper resistance used to avoid bus over-voltage during motor deceleration or when the load torque tends to accelerate the motor (ohms).
Activation Voltage
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.
Deactivation Voltage
The dynamic braking is shut down when the bus voltage reaches the lower limit of the hysteresis band