AN1914 Freescale Semiconductor / Motorola, AN1914 Datasheet
AN1914
Related parts for AN1914
AN1914 Summary of contents
Page 1
... PC Master ....................................49 10. DSP Usage .................................49 11. Setting of SW parameters for other motor kits.................................49 11.1 Current and Voltage Settings ........50 11.2 Commutation Control Settings......51 11.3 Speed Setting.................................54 12 References ...................................55 12.1 Software Development Kit............55 12.2 User’s Manuals and Application Notes ..........................55 Go to: www.freescale.com Order by AN1914/D (Motorola Order Number) Rev. 0, 8/01 Contents ...
Page 2
Freescale Semiconductor, Inc. Motorola DSP Advantages and Features can perform the control tasks. Moreover, the necessary computing power can be minimized by using dedicated on chip peripheral modules (such as A/D converter, dedicated PWM outputs, input capture and output compare ...
Page 3
Freescale Semiconductor, Inc. • Software-programmable, Phase Lock Loop-based frequency synthesizer for the DSP core clock Table 2-1. Memory Configuration DSP56F801 Program Flash 8188 x 16-bit Data Flash 2K x 16-bit Program RAM 1K x 16-bit Data RAM 1K x 16-bit ...
Page 4
Freescale Semiconductor, Inc. Target Motor Theory • Set, clear, or toggle output capture action • Pulse Width Modulator (PWM) signal generation • Programmable clock sources and frequencies, including external clock The Quadrature Timer provides the capability to precisely control the ...
Page 5
Freescale Semiconductor, Inc. Figure 3-1. BLDC Motor - Cross Section The motor can have more then just one pole-pair per phase. This defines the ratio between the electrical revolution and the mechanical revolution. The BLDC motor shown has three pole-pairs ...
Page 6
Freescale Semiconductor, Inc. Target Motor Theory motor terminals of the BLDC motor. As can be seen, the shape of the Back-EMF is approximately trapezoidal and the amplitude is a function of the actual speed. During the speed reversal the amplitude ...
Page 7
Freescale Semiconductor, Inc. 3.3 Why Sensorless Control? As explained in the previous section, the rotor position must be known in order to drive a Brushless DC motor. If any sensors are used to detect rotor position, then sensed information must ...
Page 8
Freescale Semiconductor, Inc. Target Motor Theory Figure 3-5. Power Stage - Motor Topology The second goal of the model is to find how the motor characteristics depend on the switching angle. The switching angle is the angular difference between a ...
Page 9
Freescale Semiconductor, Inc. 3.4.1 Mathematical Model The following set of equations is valid for the presented topology where: are “branch” voltages; the voltages between one power stage output and its virtual ...
Page 10
Freescale Semiconductor, Inc. Target Motor Theory The internal torque of the motor itself is defined as where internal motor torque (no mechanical losses rotor speed, rotor position x - phase index, it stands for ...
Page 11
Freescale Semiconductor, Inc Figure 3-6. Phase Voltage Waveforms 3.6 Back-EMF Sensing Circuit An example of the possible implementation of the Back-EMF sensing circuit is shown in +DC_Bus Phase A Phase B Phase C 560k 560k 560k ...
Page 12
Freescale Semiconductor, Inc. System Design Concept Figure 3-8. The Zero Crossing Detection The voltage drop resistor is used to measure the DC-bus current which is chopped by the PWM. The obtained signal is rectified and amplified (0-3.3V with 1.65V offset). ...
Page 13
Freescale Semiconductor, Inc. — Low Voltage Evaluation Motor hardware set — Low Voltage hardware set — High Voltage hardware set at variable line voltage 115 - 230V AC • Overvoltage, Undervoltage, Overcurrent, and Temperature Fault protection • Manual Interface (Start/Stop ...
Page 14
Freescale Semiconductor, Inc. System Design Concept Table 4-3. Low Voltage Hardware Set Specifications Load Characteristic: Table 4-4. High Voltage Evaluation Hardware Set Specifications Motor Characteristics: Drive Characteristics: Load Characteristic: 14 DSP56F80x MC PWM Module in Motor Control Applications For More ...
Page 15
Freescale Semiconductor, Inc. 4.2 Sensorless Drive Concept The concept below was chosen. The sensorless rotor position technique developed detects the zero crossing points of Back-EMF induced in the motor windings. The phase Back-EMF Zero Crossing points are sensed while one ...
Page 16
Freescale Semiconductor, Inc. Control Technique the switching of the IGBTs (MOSFETs). This signal is transferred to the DSP Encoder Input which is also used as a digital filter. The SW selects one of the phase comparator outputs which corresponds to ...
Page 17
Freescale Semiconductor, Inc. commutation commutation A-off PWM1 S At A-off PWM2 S Ab B-off PWM3 S Bt B-off PWM4 S Bb C-off PWM5 S Ct C-off PWM6 S Cb A-off I A B-off I B C-off ...
Page 18
Freescale Semiconductor, Inc. Control Technique Figure 5-3 shows that the diagonal power switches are driven by the same PWM signal as shown with arrow lines. This technique is called bipolar (hard) switching. The voltage across the two connected coils is ...
Page 19
Freescale Semiconductor, Inc. 5.4 Sensorless Commutation Control This chapter concentrates on sensorless BLDC motor commutation with BEMF Zero Crossing technique. In order to start and run the BLDC motor, the control algorithm has to go through the following states: • ...
Page 20
Freescale Semiconductor, Inc. Control Technique 5.4.1 Alignment Be fore the motor starts, there is a short time (which depends on the motor’s electrical time constant) when the rotor position is stabilized by applying PWM signals to only two motor phases ...
Page 21
Freescale Semiconductor, Inc. 5.4.2.1 Algorithms BLDC Motor Commutation with Zero Crossing Sensing All these processes are provided by new algorithms which were designed for these type of applications within SDK. They are described in Motor Control.pdf, chapter BLDC Motor Commutation ...
Page 22
Freescale Semiconductor, Inc. Control Technique Commutation Done BEMF Zero Crossing detected between previous commutations? Yes Service of Commutation: Preset commutation Wait for Per_Toff until phase current decays to zero BEMF Zero Crossing missed? No BEMF Zero Crossing Detected ...
Page 23
Freescale Semiconductor, Inc. 5.4.2.2 Running - Commutation Times Calculation Commutation time calculation is provided by algorithm bldcZCComput described in Motor Control.pdf, chapter BLDC Motor Commutation with Zero Crossing Sensing (see [12.1]). T_Cmt0[n-2] T_Cmt0[n-1] n-2 Zero Crossing Detection Signal Zero Crossing ...
Page 24
Freescale Semiconductor, Inc. Control Technique Per_ZCros[n] = T_ZCros[n] - T_ZCros[n-1] = T_ZCros[n] - T_ZCros0 Per_ZCrosFlt[n] = (1/2*Per_ZCros[n]+1/2*Per_ZCros0) HlfCmt[n] = 1/2*Per_ZCrosFlt[n]- Advance_angle = = 1/2*Per_ZCrosFlt[n]- C_CMT_ADVANCE*Per_ZCrosFlt[n]= Coef_HlfCmt*Per_ZCrosFlt[n] The best commutation was get with Advance_angle: 60Deg*1/8 = 7.5Deg which means Coef_HlfCmt = ...
Page 25
Freescale Semiconductor, Inc. In order to start the BLDC motor the adequate torque must be generated. The motor torque is proportional to the multiplication of the stator magnetic flux, the rotor magnetic flux and the sine of angle between these ...
Page 26
Freescale Semiconductor, Inc. Control Technique Motor is Running at steady-state condition with regular Back-EMF feedback Rotor magnetic Stator magnetic field field (created by PM) Border of stator pole Rotor movement during one Direction of commutation Phase current Zero crossing Phase ...
Page 27
Freescale Semiconductor, Inc. Phase Back-EMFs Back-EMF Zero Crossings Ideal Commutation Pattern when position is known B C TOP TOP C A BOT BOT Real Commutation Pattern when position is estimated B TOP C A BOT BOT st nd 1’ 2’ ...
Page 28
Freescale Semiconductor, Inc. Control Technique . [1] [2] T_Cmt0 T_Cmt0 T2[1] n=2 n=1 2* Per_CmtStart Per_CmtStart Zero Crossing Detection Signal T_ZCros[0] Zero Crossing Detection Signal Zero Crossing Detection Signal Per_Toff[n] Figure 5-11. Calculation of the Commutation Times during the Starting ...
Page 29
Freescale Semiconductor, Inc. 5.5 Speed Control The speed close loop control is provided by a well known PI regulator as shown in actual speed (Omega_Actual) is computed from average of two BEMF Zero Crossing periods (time intervals) received from the ...
Page 30
... U1 CONTROLLER BOARD for DSP56F803: — supplied as: DSP56803EVM — described in: DSP Evaluation Module Hardware User’s Manual Information of all above mentioned boards and documents can be found on: http://mot-sps.com/motor/devtools/index.html 6.3 Low Voltage Hardware Set The system configuration is shown in 30 DSP56F80x MC PWM Module in Motor Control Applications ...
Page 31
... Phase Brushless DC Low Voltage Power Stage • MB1 - Motor-Brake SM40N + SG40N — supplied as: ECMTRLOVBLDC Information of all above mentioned boards and documents can be found on: http://mot-sps.com/motor/devtools/index.html 6.4 High Voltage Hardware Set The system configuration is shown in DSP56F80x MC PWM Module in Motor Control Applications For More Information On This Product, Figure 6-14 ...
Page 32
... MB1 Motor-Brake SM40V + SG40N — supplied as: ECMTRHIVBLDC Information of all above mentioned boards and documents can be found on: http://mot-sps.com/motor/devtools/index.html 32 DSP56F80x MC PWM Module in Motor Control Applications For More Information On This Product, Go to: www.freescale.com ...
Page 33
Freescale Semiconductor, Inc Design This section describes the design of the software blocks of the drive. The software will be described in terms of: • Main Software Flow Chart • Data Flow • State Diagram For more information ...
Page 34
Freescale Semiconductor, Inc. SW Design Reset Initialize Application State Machine: precedes/sets requirements of: Drive Fault Status Application Mode Omega Required Mechanical Control Speed Control Alignment Current Commutation Control proceed Status_Commutation: Running Starting Alignment Stopped Check Run/Stop Switch Interrupt ADC complete ...
Page 35
Freescale Semiconductor, Inc. Interrupt Up Button Up Button ISR: increment Omega Required Mechanical RTI Interrupt ADC Low Limit ADC Low Limit ISR: set Undervoltage Fault set Overheating Fault Emergency Stop RTI Figure 7-2. Main Software Flow Chart - Part 2 ...
Page 36
Freescale Semiconductor, Inc. SW Design DC-Bus Current Manual Speed Setting (A/D) I_Dc_Bus Omega_Required_Mech Cmd_Application Process Current PI Controller U_Desired PVAL0,PVAL1 Protection processes are shown in 36 DSP56F80x MC PWM Module in Motor Control Applications For More Information On This Product, ...
Page 37
Freescale Semiconductor, Inc. DC-Bus Current Temperature (A/D) Temperature I_Dc_Bus Process Fault Control DriveFaultStatus Process Application State Machine 7.2.1 Process Application State Machine This process controls the application subprocesses by status and command words as can be seen in Figure 7-3. ...
Page 38
Freescale Semiconductor, Inc. SW Design . Reference Speed Speed Error (Omega_Desired) - Figure 7-5. Closed Loop Control System The speed closed loop control is characterized by the feedback of the actual motor speed. This information is compared with the reference ...
Page 39
Freescale Semiconductor, Inc. 7.3.1 Main SW States - General Overview The SW can be split into following processes: • Process Application State Machine • Process Commutation Control • Process Speed PI Controller • Process Current PI Controller • Process PWM ...
Page 40
Freescale Semiconductor, Inc. SW Design In manual control, the application is controlled with Start/Stop switch and Up Down Push buttons to set Required Speed Master control mode the Start/Stop is controlled manually and the Required Speed is set ...
Page 41
Freescale Semiconductor, Inc. — motor is powered with current through 2 phases - no commutations provided. • Starting (Back-EMF Acquisition) State — motor is started with making first 2 commutations, then it is running as at Running state using Start ...
Page 42
Freescale Semiconductor, Inc. SW Design and commutation registers are preset. If Zero Crossing already happen during Per_Toff time period, the commutation period is corrected using Corrective Calculation 2. When the commutation time expires, then a new commutation is performed. Running ...
Page 43
Freescale Semiconductor, Inc. • T_Actual = Cmt Timer Counter • setting new commutation parameters and initialized commutation with bldczcHndlrInit algorithm • initialization of computation with bldczcComputInit algorithm 7.3.4.4 Commutation Control - Set Starting This state is used to set the ...
Page 44
Freescale Semiconductor, Inc. SW Design 7.3.5 State Diagram - Process Speed PI Controller U_Desired = PI (Reference Speed - Actual Motor Speed) Speed Control Request Figure 7-9. State Diagram - Process Speed PI Controller The Speed PI controller algorithm controllerPItype1 ...
Page 45
Freescale Semiconductor, Inc. 7.3.6 State Diagram - Process Current PI Controller U_Desired = PI (Reference Current - Actual Current) Current Control Request PWM Reload (PWM period) Start ADC Conversions Figure 7-10. State Diagram - Process Speed PI Controller The Current ...
Page 46
Freescale Semiconductor, Inc. SDK Implementation 7.3.7.2 ADC Low Limit Interrupt Subroutine This subroutine is called when at least one ADC low limit is detected. In this interrupt subroutine following low limit exceeds are processed: • the undervoltage of the DC ...
Page 47
Freescale Semiconductor, Inc. • bldczcTimeoutIntAlg (time-out interrupt algorithm for BLDC commutation control with BEMF Zero Crossing; bldc.lib library) • bldczcHndlrStop (stop handler for BLDC commutation control with BEMF Zero Crossing; BLDC.LIB library) • bldczcComputInit (computation initialization for BLDC commutation control ...
Page 48
Freescale Semiconductor, Inc. PC Master 8.4 Interrupts The SDK serves the calling of interrupt routines and automatically clears interrupt flags. The user defines the callback functions which are called during interrupts. The callback functions are assigned during the driver’s opening. ...
Page 49
Freescale Semiconductor, Inc. ...\dsp5680xevm\nos\applications\bldc_zerocross\configextram\appconfig the file (Flash version): ...\dsp5680xevm\nos\applications\bldc_zerocross\configFlash\appconfig.h. The motor control drive usually needs setting/tuning of: • dynamic parameters • current/voltage parameters The SW selects valid parameters (one of the 3 parameter sets) based in the identified ...
Page 50
Freescale Semiconductor, Inc. Setting of SW parameters for other motor kits The current controller works with constant execution (sampling) period determined by PWM frequency: Current Controller period = 1/pwm frequency. Both proportional and integral gain have two coefficients: gain portion ...
Page 51
Freescale Semiconductor, Inc. #define x_PER_CMTSTART #define x_PER_TOFFSTART The unit of these constant is 1.777us. These constants are automatically calculated in newer SDK software versions. Notes recommended to set Then the first motor commutation period = The Back-EMF Zero ...
Page 52
Freescale Semiconductor, Inc. Setting of SW parameters for other motor kits 11.2.5 Commutation Proceeding Period Commutation preceeding period is the constant time after motor commutation, when BEMF Zero Crossing is not measured (until the phase current decays to zero). #define ...
Page 53
Freescale Semiconductor, Inc. 11.3 Speed Setting 11.3.1 Maximal and Minimal Speed and Speed Regulator Setting All this section settings are in bldcadczcdefines.h. In order to compute the speed setting important to set the number of BLDC motor commutations ...
Page 54
Freescale Semiconductor, Inc. References 12. References 12.1 Software Development Kit, SDK Rev.2.2 • Targetting_DSP56805_Platform.pdf — located at: Embedded SDK\help\docs\sdk\targets\Targetting_DSP56805_Platform\content • Targetting_DSP56803_Platform.pdf — located at: Embedded SDK\help\docs\sdk\targets\Targetting_DSP56803_Platform\content • Motor Control.pdf, chapter BLDC Motor Commutation with Zero Crossing Sensing — located at: ...
Page 55
Freescale Semiconductor, Inc. DSP56F80x MC PWM Module in Motor Control Applications For More Information On This Product, Go to: www.freescale.com References 55 ...
Page 56
... ASIA/PACIFIC: Motorola Semiconductors H.K. Ltd.; Silicon Harbour Centre, 2 Dai King Street, Tai Po Industrial Estate, Tai Po, N.T., Hong Kong. 852–26668334 Technical Information Center: 1–800–521–6274 HOME PAGE: http://www.motorola.com/semiconductors/ For More Information On This Product, Æ are registered trademarks of Motorola, Inc. Motorola, Inc Equal Go to: www.freescale.com AN1914/D ...