AN1915D Freescale Semiconductor / Motorola, AN1915D Datasheet

no-image

AN1915D

Manufacturer Part Number
AN1915D
Description
3-Phase BLDC Motor Control with Quadrature Encoder using DSP56F80x
Manufacturer
Freescale Semiconductor / Motorola
Datasheet
© Motorola, Inc., 2002. All rights reserved.
3-Phase BLDC Motor
Control with Quadrature
Encoder using DSP56F80x
Design of Motor Control Application Based
on Motorola Software Development Kit
Pavel Grasblum
1.
This Application Note describes the design of a 3-phase
BLDC (Brushless DC) motor drive based on Motorola’s
DSP56F80x dedicated motor control device. The software
design takes advantage of the SDK (Software Development
Kit) developed by Motorola.
BLDC motors are very popular in a wide application area.
Compared with a DC motor, the BLDC motor loads a
commutator and so it is more reliable than the DC motor.
Also in comparison to an AC induction motor, the BLDC
motor has advantages. BLDC motors generate the rotor
achieve magnetic flux with rotor magnets so that BLDC
motors higher efficiency. Therefore BLDC motors are used in
high-end white goods (refrigerators, washing machines,
dishwashers, etc.), high-end pumps, fans and in other
appliances, which require high reliability and efficiency.
The concept of the application is a speed-closed loop BLDC
drive using a Quadrature Encoder. It serves as an example of
a BLDC motor control system design using a Motorola DSP
with SDK support. It also illustrates the usage of dedicated
motor control libraries that are included in the SDK.
This Application Note includes the basic motor theory,
system design concept, hardware implementation and
software design, including the PC Master visualization tool.
Introduction of Application
Benefit
Freescale Semiconductor, Inc.
For More Information On This Product,
Go to: www.freescale.com
1.
2.
3.
4.
5.
6.
7.
8.
9.
3.1 Digital Control of a BLDC Motor...4
4.1 System Outline ..............................14
4.2 Application Description ................15
4.3 Hardware Implementation.............16
5.1 Data Flow ......................................17
5.2 Software Implementation ..............20
6.1 Scaling of Quantities .....................23
7.1 Drivers and Library Functions ......24
7.2 Appconfig.h File ...........................25
7.3 Initialization of Drivers .................25
7.4 Interrupts .......................................25
7.5 PC Master Software ......................25
Benefit........................................1
Features......................................2
Introduction of Application
Motorola DSP Advantages and
Target Motor Theory .................4
System Concept.......................14
Software Design ......................17
Implementation Notes .............23
SDK Implementation...............24
DSP Usage...............................27
References ...............................27
Contents
(Motorola Order Number)
Order by AN1915/D
Rev. 0, 9/02

Related parts for AN1915D

AN1915D Summary of contents

Page 1

Freescale Semiconductor, Inc. 3-Phase BLDC Motor Control with Quadrature Encoder using DSP56F80x Design of Motor Control Application Based on Motorola Software Development Kit Pavel Grasblum 1. Introduction of Application Benefit This Application Note describes the design of a 3-phase BLDC ...

Page 2

Freescale Semiconductor, Inc. Motorola DSP Advantages and Features 2. Motorola DSP Advantages and Features The Motorola DSP56F80x family is well suited for digital motor control, combining the DSP’s calculation capability with the MCU’s controller features on a single chip. These ...

Page 3

Freescale Semiconductor, Inc. • Complementary channel operation • Deadtime insertion • Separate top and bottom pulse width correction via current status inputs or software • Separate top and bottom polarity control • Edge-aligned or center-aligned PWM signals • 15 bits ...

Page 4

Freescale Semiconductor, Inc. Target Motor Theory • Includes logic to decode quadrature signals • Configurable digital filter for inputs • 32-bit position counter • 16-bit position difference counter • Maximum count frequency equals the peripheral clock rate • Position counter ...

Page 5

Freescale Semiconductor, Inc. Voltage +U DCB Phase A -U DCB +U DCB Phase B -U DCB +U DCB Phase C -U DCB 30º 60º Figure 3-2. Voltage Strokes Applied onto the 3-ph BLDC Motor For the common 3-phase BLDC motor ...

Page 6

Freescale Semiconductor, Inc. Target Motor Theory PWM switching ON PWM Q1 OFF ON PWM Q2 OFF ON PWM Q3 OFF ON PWM Q4 OFF ON PWM Q5 OFF ON PWM Q6 OFF 10º Figure 3-4. Independent Switching of Power Transistors ...

Page 7

Freescale Semiconductor, Inc. 3.1.3 Commutation Commutation creates a rotation field. As was explained, for the proper operation of a BLDC motor necessary to keep the angle between stator and rotor flux close to 90°. With six-step control we ...

Page 8

Freescale Semiconductor, Inc. Target Motor Theory Figure 3-7. Situation Prior to Commutation Figure 3-8. Situation Following Commutation Table 3-1. Commutation Sequence for Clockwise Rotation 8 3-Phase BLDC Motor Control with Quadrature Encoder For More Information On This Product, '&% '&% ...

Page 9

Freescale Semiconductor, Inc. Table 3-2. Commutation Sequence for Counter Clockwise Rotation 3.1.3.1 Quadrature Encoder versus Hall Sensors The BLDC motor application uses the Quadrature Encoder for rotor position sensing. The Quadrature Encoder output consists of three signals. Two phases, A ...

Page 10

Freescale Semiconductor, Inc. Target Motor Theory position very quickly. The frequency of scanning depends on the maximal rotor speed, the number of pole pairs and on the required precision of commutation moment detection. The same scan frequency as used in ...

Page 11

Freescale Semiconductor, Inc. Figure 3-11. Situation Prior to First Compare Following Alignment As soon as the counter reaches one of the compare values, the commutation interrupt is called. The commutation interrupt recognizes the spin direction and sets new values into ...

Page 12

Freescale Semiconductor, Inc. Target Motor Theory We can see that the commutation interrupt is called six times per electrical revolution. Note that the commutation interrupt is called in the same moment as when we use Hall Sensors. Thus we can ...

Page 13

Freescale Semiconductor, Inc. desired - actual The speed controller calculates a Proportional-Integral (PI) algorithm according to equations below: After transformation to a discrete time domain using an integral approximation by a Backward Euler method, we get the following equations for ...

Page 14

Freescale Semiconductor, Inc. System Concept 4. System Concept 4.1 System Outline The system is designed to drive a 3-phase BLDC motor. The application meets the following performance specification: • Voltage control of BLDC motor using Quadrature Encoder • Targeted for ...

Page 15

Freescale Semiconductor, Inc. 4.2 Application Description A standard system concept is chosen for the drive (see following hardware boards: • Power Supply 12V DC, 4Amps • EVM Motor Board • BLDC Motor IB23810 with Quadrature Encoder • Evaluation Board DSP56F803, ...

Page 16

Freescale Semiconductor, Inc. System Concept 4.3 Hardware Implementation As already stated, the application runs on Motorola motor control DSPs using the DSP EVM Boards and a dedicated 3-phase BLDC platform. The application can be controlled by the following Motorola motor ...

Page 17

Freescale Semiconductor, Inc. • CONTROLLER BOARD for DSP56F805: — supplied as: DSP56805EVM — described in: DSP Evaluation Module Hardware User’s Manual • CONTROLLER BOARD for DSP56F807: — supplied as: DSP56807EVM — described in: DSP Evaluation Module ...

Page 18

Freescale Semiconductor, Inc. Software Design The main data flow can be divided to four parts: • Speed control • Velocity calculation • Rotor commutation • DC-Bus voltage measurement Speed control starts with the required speed omega_required_mech . This variable is ...

Page 19

Freescale Semiconductor, Inc. 5.1.4 Mask and Swap Calculation This process performs a rotor commutation. As already mentioned, only two phases are powered by a six-step control. The proper PWM output can be generated by changing the PWM value (duty cycle) ...

Page 20

Freescale Semiconductor, Inc. Software Design Note: In complementary switching mode necessary to use the software control feature for masking. For independent mode possible to use the masking feature in the PWM Channel Control Register. This feature ...

Page 21

Freescale Semiconductor, Inc. Figure 5-3. State Diagram - General Overview 5.2.1 Initialization The Main Routine provides initialization of the DSP: • Disables Interrupts • Initializes DSP PLL • Disables COP and LVI • Initializes the POSIX Timer for a time ...

Page 22

Freescale Semiconductor, Inc. Software Design • Initializes Quad TimerA - channel A1 — set Count Mode to Count — set Input Source to Bus Clock / 128 — set Input Polarity to Normal — set Secondary Input Source to Input ...

Page 23

Freescale Semiconductor, Inc. 5.2.3 Drive State Machine The drive can be in any of the states shown in among the drive states. The user is able to recognize the current state blinking green LED diode. In case of ...

Page 24

Freescale Semiconductor, Inc. SDK Implementation 6.1.1 DC-Bus Voltage Scaling The DC-Bus voltage sense is defined by following equation: Where: u_dc_bus = variable of DC-Bus voltage, V measurable DC-Bus voltage 16V for the EVM Motor Board MAX 6.1.2 PI ...

Page 25

Freescale Semiconductor, Inc. The BLDC motor control application uses the following library functions: • bldchsCommHandlerComp (BLDC motor commutation algorithm; bldc.lib library) • controllerPItype1 (standard PI controller; mcfunc.lib library) • switchcontrol (switch control; mcfunc.lib library) 7.2 Appconfig.h File The purpose of ...

Page 26

Freescale Semiconductor, Inc. SDK Implementation #define INCLUDE_SCI #define INCLUDE_PCMASTER This automatically includes the SCI driver and installs all necessary services. The default baud rate of the SCI communication is 9600Bd set automatically by the PC master software driver ...

Page 27

Freescale Semiconductor, Inc. 8. DSP Usage Table 8-1 shows how much memory is needed to run the 3-phase BLDC drive in a speed-closed loop using Quadrature Encoder. A majority of the DSP’s memory is still available for other tasks. Table ...

Page 28

Freescale Semiconductor, Inc. Motorola reserves the right to make changes without further notice to any products herein. Motorola makes no warranty, representation or guarantee regarding the suitability of its products for any particular purpose, nor does Motorola assume any liability ...

Related keywords