Introducing the control algorithms of common motors
[Copy link]
BLDC Motor Control Algorithm
Brushless motors are self-commutated (self-direction converting) and therefore more complex to control.
BLDC motor control requires knowledge of the rotor position and the mechanism by which the motor is commutated and steered. For closed-loop speed control, there are two additional requirements, namely the measurement of the rotor speed and/or motor current and the PWM signal to control the motor speed power.
BLDC motors can use either edge-aligned or center-aligned PWM signals depending on the application requirements. Most applications require only variable speed operation and will use 6 independent edge-aligned PWM signals. This provides the highest resolution. If the application requires server positioning, dynamic braking, or power reversal, it is recommended to use supplemental center-aligned PWM signals.
To sense the rotor position, BLDC motors use Hall effect sensors to provide absolute position sensing. This results in more wires and higher costs. Sensorless BLDC control eliminates the need for Hall sensors and instead uses the motor's back EMF (electromotive force) to predict rotor position. Sensorless control is critical for low-cost variable speed applications like fans and pumps. Refrigerator and air conditioning compressors also require sensorless control when using BLDC motors.
Dead time insertion and supplementation
Most BLDC motors do not require complementary PWM, dead time insertion, or dead time compensation. The only BLDC applications that may require these features are high performance BLDC servo motors, sine wave excited BLDC motors, brushless AC, or PC synchronous motors.
Control Algorithm
Many different control algorithms are used to provide control of BLDC motors. Typically, power transistors are used as linear regulators to control the motor voltage. This approach is not practical when driving high power motors. High power motors must be PWM controlled and require a microcontroller to provide starting and control functions.
The control algorithm must provide the following three functions:
PWM voltage for controlling motor speed
Mechanism for rectifying and commutating the motor
Methods for predicting rotor position using back EMF or Hall sensors
Pulse width modulation is used only to apply a variable voltage to the motor windings. The effective voltage is proportional to the PWM duty cycle. When properly commutated, the torque-speed characteristics of the BLDC are the same as those of the following DC motors. The speed and variable torque of the motor can be controlled with a variable voltage.
Commutation of the power transistors enables the proper windings in the stator to generate the optimum torque based on the rotor position. In a BLDC motor, the MCU must know the rotor position and be able to commutate at the right time.
Trapezoidal commutation of BLDC motor
One of the simplest approaches for brushless DC motors is to use so-called trapezoidal commutation. A simplified framework of a trapezoidal controller for a BLDC motor is shown in the figure below.
In this schematic, the current is controlled through one pair of motor terminals at a time, while the third motor terminal is always electronically disconnected from the power supply.
Three Hall devices embedded in the large motor are used to provide digital signals that measure the rotor position in a 60-degree sector and provide this information to the motor controller. Since the current on two windings is equal at any time and the current on the third winding is zero, this method can only produce a current space vector with one of the six directions. As the motor turns, the current at the motor terminals is electrically switched once every 60 degrees (commutation), so the current space vector is always at the closest 30 degrees of the 90-degree phase shift.
Trapezoidal control: drive waveform and torque at rectification, as shown in the following diagram.
Therefore, the current waveform of each winding is trapezoidal, starting from zero to positive current to zero and then to negative current.
This creates a current space vector that will approach balanced rotation as it is stepped in six different directions as the rotor rotates.
In motor applications like air conditioning and frost, using Hall sensors is not always an option. Back EMF sensors sensed in the non-coupled windings can be used to achieve the same result.
Such trapezoidal drive systems are very common due to the simplicity of their control circuits, but they suffer from the problem of torque ripple during the rectification process.
Sinusoidal commutation of BDLC motor
Trapezoidal commutation is not sufficient to provide balanced, accurate BLDC motor control. This is primarily because the torque produced in a three-phase BLDC motor (with a sine wave back EMF) is defined by the following equation:
Shaft torque = Kt [IRSin(o) + ISSin(o+120) +ITSin(o+240)]
Where:
o is the electrical angle of the shaft
Kt is the torque constant of the motor
IR, IS and IT are the phase currents If the phase currents are sinusoidal: IR = I0Sino; IS = I0Sin (+120o); IT = I0Sin (+240o)
You will get: Shaft torque = 1.5I0*Kt (a constant independent of the shaft angle)
Sinusoidally commutated brushless motor controllers strive to drive the three motor windings with three currents that vary sinusoidally as the motor turns. The relative phases of these currents are chosen so that they will produce a smooth rotor current space vector that is orthogonal to the rotor and has constants. This eliminates torque ripple and steering pulses associated with northerly steering.
In order to generate a smooth sinusoidal modulation of the motor current as the motor rotates, an accurate measurement of the rotor position is required. Hall devices only provide a rough calculation of the rotor position, which is not sufficient for this purpose. For this reason, angular feedback from an encoder or similar device is required.
A simplified block diagram of a BLDC motor sine wave controller is shown below.
Since the winding currents must combine to produce a smooth constant rotor current space vector, and each position of the stator winding is 120 degrees apart, the current in each wire group must be sinusoidal and phase-shifted by 120 degrees. The position information from the encoder is used to synthesize two sine waves, which are 120 degrees phase-shifted between them. These signals are then multiplied by the torque command, so the amplitude of the sine wave is proportional to the required torque. As a result, the two sinusoidal current commands are properly phased to produce a rotating stator current space vector in orthogonal directions.
The sinusoidal current command signals output a pair of PI controllers that modulate the current in two appropriate motor windings. The current in the third rotor winding is the negative sum of the controlled winding currents and therefore cannot be controlled separately. The output of each PI controller is fed to a PWM modulator and then to the output bridge and two motor terminals. The voltage applied to the third motor terminal is derived from the negative sum of the signals applied to the first two wire groups, appropriately for three sinusoidal voltages spaced 120 degrees apart.
As a result, the actual output current waveform accurately tracks the sinusoidal current command signal and the resulting current space vector rotates smoothly, is stabilized in quantity and is positioned in the desired direction.
Normally, the sinusoidal commutation commutation results in a stable control that cannot be achieved with trapezoidal commutation commutation. However, since it is very efficient at low motor speeds, it will break down at high motor speeds. This is because as speed increases, the current return controllers must track a sinusoidal signal of increasing frequency. At the same time, they must overcome the motor's back EMF, which increases in amplitude and frequency as speed increases.
Since the PI controller has finite gain and frequency response, a time-varying disturbance to the current control loop will cause a phase lag and gain error in the motor current, which increases at higher speeds. This will disturb the direction of the current space vector relative to the rotor, causing a displacement from the orthogonal direction.
When this happens, less torque can be produced by a given amount of current, so more current is needed to maintain torque. Efficiency decreases.
As speed increases, this reduction continues. At some point, the current phase shift exceeds 90 degrees. When this occurs, the torque decreases to zero. Speeds above this point result in negative torque through sinusoidal combination, so this cannot be achieved.
AC Motor Algorithm
Scalar control
Scalar control (or V/Hz control) is a simple method of controlling the commanded motor speed.
The steady-state model of the command motor is mainly used to obtain the technology, so transient performance is impossible to achieve. The system does not have a current loop. To control the motor, the three-phase power supply only varies in amplitude and frequency.
Vector control or field oriented control
The torque in an electric motor varies as a function of the stator and rotor magnetic fields and reaches a peak when the two fields are orthogonal to each other. In scalar-based control, the angle between the two fields varies significantly.
Vector control seeks to recreate the quadrature relationship in an AC motor. To control torque, each generates current from the magnetic flux produced to achieve the responsiveness of a DC machine.
Vector control of an AC command motor is similar to control of a single-field DC motor. In a DC motor, the field energy Φ F generated by the field current IF is orthogonal to the armature flux Φ A generated by the armature current IA. These fields are decoupled and stable with respect to each other. Therefore, when the armature current is controlled to control torque, the field energy remains unaffected and a faster transient response is achieved.
Field Oriented Control (FOC) of a three-phase AC motor consists in emulating the operation of a DC motor. All controlled variables are converted to DC instead of AC by mathematical transformation. The goal is to independently control torque and flux.
There are two methods of field oriented control (FOC):
Direct FOC : The direction of the rotor magnetic field (Rotor flux angle) is directly calculated by the flux observer
Indirect FOC : The direction of the rotor magnetic field (Rotor flux angle) is obtained indirectly by estimating or measuring the rotor speed and slip.
Vector control requires knowledge of the position of the rotor flux and can be calculated through advanced algorithms using knowledge of the terminal currents and voltages (using a dynamic model of the AC induction motor). However, from an implementation perspective, the demand on computing resources is critical.
There are different ways to implement the vector control algorithm. Feedforward techniques, model estimation, and adaptive control techniques can all be used to enhance response and stability.
Vector Control of AC Motors: A Deeper Look
The core of the vector control algorithm is two important transformations: Clark transformation, Park transformation and their inverse operations. Using Clark and Park transformations, the rotor current can be controlled to the rotor area. This allows a rotor control system to determine the voltage that should be supplied to the rotor to maximize the torque under dynamically changing loads.
Clark transformation: Clark mathematical transformation modifies a three-phase system into two coordinate systems:
Among them, ia and ib are components of the orthogonal reference plane, and ic is the unimportant homoplanar part. The relationship between the three-phase rotor current and the rotating reference system is shown in the figure below.
Park Transformation: Park mathematical transformation converts a bidirectional static system into a rotating system vector:
The two-phase α, β frame representation is calculated by Clarke transformation and then input to the vector rotation module, where it is rotated by angle θ to conform to the d, q frame attached to the rotor energy. According to the above formula, the transformation of angle θ is achieved.
Basic structure of field-oriented vector control of AC motor
The Clarke transform uses the three-phase currents IA, IB and IC to calculate the currents Isd and Isq of the two-phase orthogonal stator shafts. The two currents in the fixed coordinate stator phases are transformed into Isd and Isq, which become the elements of the Park transform d, q. The currents Isd, Isq and the instantaneous flow angle θ calculated by the motor flux model are used to calculate the electric torque of the AC induction motor. The basic schematic diagram of the vector controlled AC motor is as follows.
These derived values are compared with reference values and updated by a PI controller.
An inherent advantage of vector-based motor control is that the same principle can be used to select the appropriate mathematical model to control various types of AC, PM-AC or BLDC motors.
Vector Control of BLDC Motors
BLDC motors are the main choice for field-oriented vector control. Brushless motors using FOC can achieve higher efficiency, with the highest efficiency reaching 95%, and are also very efficient at high speeds.
Stepper Motor Control Algorithm
The following is a schematic diagram of stepper motor control:
Stepper motor control usually uses a bidirectional drive current, and the motor steps are achieved by switching the windings in sequence. Usually this stepper motor has 3 drive sequences:
Single-phase full-step drive:
In this mode, the windings are energized in the following order, AB/CD/BA/DC (BA means that the energization of winding AB is in reverse direction). This sequence is called single-phase full-step mode, or wave drive mode. At any one time, only one phase is energized.
Two-phase full-step drive:
In this mode, both phases are powered together, so the rotor is always between the two poles. This mode is called two-phase full-stepping, which is the normal driving sequence for a two-pole motor and can output the maximum torque.
Half-step mode:
This mode combines single-phase stepping and two-phase stepping together: single-phase power, then two-phase power, then single-phase power..., so the motor runs in half-step increments. This mode is called half-step mode, and the effective step angle of each motor excitation is reduced by half, and its output torque is also lower.
The above three modes can all be used for reverse rotation (counterclockwise), but not if the order is reversed.
Typically, stepper motors have multiple poles in order to reduce the step angle, but the number of windings and the drive sequence remain unchanged.
General DC Control Algorithm
Speed control of general motors, especially motors using 2 circuits:
Phase angle control
PWM chopping control
Phase angle control
Phase angle control is the simplest method of general motor speed control. The speed is controlled by changing the firing angle of the TRIAC. Phase angle control is a very economical solution, but it is not very efficient and is prone to electromagnetic interference (EMI). The schematic diagram of the phase angle control of a general motor is shown below.
The above diagram shows the mechanism of phase angle control, which is a typical application of TRIAC speed control. The phase shift of the TRIAC gate pulse produces an effective voltage, thereby producing different motor speeds, and a zero crossing detection circuit is used to establish a timing reference to delay the gate pulse.
PWM chopping control
PWM control is a more advanced solution for general motor speed control, in which the power MOSFETs, or IGBTs, switch on the high-frequency rectified AC line voltage to produce a time-varying voltage for the motor.
The figure above is a schematic diagram of PWM chopping control of universal motors. Its switching frequency range is generally 10-20 KHz to eliminate noise. This universal motor control method can achieve better current control and better EMI performance, so it is more efficient.
丨 The article is organized to spread related technologies, the copyright belongs to the original author丨
丨 If there is any infringement, please contact us to delete丨
|