0% found this document useful (0 votes)
92 views

BLDCPMSM Control Using Sensorless FOC Algorithm

Uploaded by

guocan1014
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
92 views

BLDCPMSM Control Using Sensorless FOC Algorithm

Uploaded by

guocan1014
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

www.ti.

com BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 MCUs

Application Brief
BLDC/PMSM Control Using Sensorless FOC Algorithm
Based on MSPM0 MCUs

In our modern world, motors are used in many products, such as power tools, e-bike, e-car, industrial robot, and
more. BLDC (brushless DC) and PMSM (permanent-magnet synchronous motor) motors in particular provide
advantages in terms of high efficiency, low noise and long life. For the control method of the BLDC or PMSM,
field-oriented control (FOC) algorithms are used in many applications where the motor needs to run smoothly
with high efficiency and minimal audible noise. MSPM0 MCUs can fill this role of FOC control with its low-price,
broad portfolio, efficient math accelerator, and high-performance features.

Home appliances Power tools Industrial motors Personal transport

What are BLDC/PMSM and FOC?


BLDC/PMSM is a brushless motor that uses the force generated by the inconsistent magnetic fields of the stator
and rotor to drive the motor. The rotor of this motor is a permanent magnet, and the stator is composed of
multiple electromagnetic coils.

Figure 1. Consistent Magnetic Field Figure 2. Inconsistent Magnetic Field

Vector control, also called field-oriented control (FOC), is a variable-frequency drive (VFD) control method in
which the stator currents of a three-phase AC or brushless DC electric motor are identified as two orthogonal
components that can be visualized with a vector. One component defines the magnetic flux of the motor, the
other the torque. The driver control system calculates the corresponding current component references from the
flux and torque references given by the drive's speed control.

SLAAE96 – MARCH 2023 BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 1
Submit Document Feedback MCUs
Copyright © 2023 Texas Instruments Incorporated
BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 MCUs www.ti.com

MSPM0Gx

Figure 3. FOC Control Algorithm Block Diagram

Across BLDC and PMSM related applications, users need to accurately control the motor speed, torque, and
other variables to meet the requirements of actual applications. Therefore, the main resources used are as
follows:
Hardware
• Microcontroller (MCU): As the motor driver controller, it controls analog data acquisition, run control
algorithms, monitors the motor status, and communicates with other products.
• Predriver: Predriver for power stage / inverter bridge
• Power stage and inverter bridge: 6x MOSFETs, IGBTs, Gallium nitride (GaN) FETs
• Analog feedback: collects bus voltage, motor phase voltages, and motor phase currents
• Position sensing (optional): absolute encoders, sin/cos transducers
Software
• Application: Task management and scheduling
• Algorithm: Calculate the drive signal output of the motor in real time according to the feedback of the motor
and the user input speed/torque references
TI Devices
You can realize all these functions using TI devices for the driver and powerstage across a wide range of
3-phase motor voltages and powers.
MCU Motor Voltage (Switch Type) Pre-driver Powerstage, Inverter
3 V to 40 V (MOSFET) 3-Phase BLDC Motor Driver (DRV831x series)
3-phase BLDC Gate Driver
6 V to 100 V (MOSFET) N-channel MOSFET (CSD series)
MSPM0Gxx ARM Cortex M0+ 80- (DRV83xx series)
MHz MCUs Up to 650 V (GaN) GaN ICs (LMG3xx series)
Half bridge drivers (UCC2xxx
Up to 700 V (MOSFET, IGBT) MOSFET, IGBT
series, LMxxx series)

Why is MSPM0 suitable for BLDC/PMSM and FOC?


TI’s scalable M0+ MSPM0Gxx high-performance MCUs with advanced on-chip motor control peripherals
provides a great low-cost solution for variety of motor control applications. The portfolio covers from 32KB
to 128KB of Flash with scalable analog Integration, motor control peripherals, and CAN.

2 BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 SLAAE96 – MARCH 2023
MCUs Submit Document Feedback
Copyright © 2023 Texas Instruments Incorporated
www.ti.com BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 MCUs

80-MHz M0+ CPU provides Advanced motor control timers


high performance and an with flexible PWM control and
integrated math accelerator cross triggers

Connect in any motor control


Two independent 4-Msps system with UART, I2C, SPI, and
12-bit ADCs (up to CAN-FD
MSPM0
16 channels)

Ensure system stability and reliability


Accurate analog signal with Q100 qualified options and wide
measurement with two zero- operating temperature range
drift chopper OPAs and three (-40°C to 105° or 125°C)
high-speed comparators
• 80-MHz M0+ CPU – Reduce process time for FOC algorithms and sensing signal
• Integrated math accelerator
– 32-bit hardware divider (8 cycles) for fixed point and IQ format numbers
– Square root operation in 21 cycles
– 24-bit trigonometric calculations (sin, cos, atan) in 29 cycles
• Two independent 4-Msps 12-bit ADC module (up to 16 channels)
– Up to 11 ENOB with better SNR
– Up to 4-Msps ADC boost motor phase current sensing within 250 ns
• Two zero-drift chopper op-amps – Accurately amplify the 2-phase current
• Three high speed comparators – Enable hardware current limiting for motor with zero-wait
• Advanced motor control timers – Flexible 6 PWM control and cross triggers
– Center-aligned PWM generate
– Asymmetric PWM allows two center-aligned PWM signals to be generated with a controlled phase shift
– Complementary PWM with dead band Insertion
– Cross trigger to generate ADC timing to capture 2-phase current
• Robust IO design with glitch filter – Provide a reliable system despite motor noise.
• Comprehensive communication interfaces – Including UART, I2C, SMBus, SPI and CAN-FD to meet all
the communication requirements with the motor control system
• FOC algorithm library – Accelerate your time to market of your motor control design.
• Scalable MCU portfolio with pin-to-pin compatible devices across a wide range of flash memory options.
• Low cost and small footprint package provide cost effective options for space constrained designs.
• Support wide operating temperature range (-40°C to 105 or 125°C) with Q100 qualified options for system
stability and reliability.

What can MSPM0 do in BLDC/PMSM and FOC?


In BLDC/PMSM and FOC applications, MSPM0 monitors the motor status and runs the FOC algorithm.
Depending on the system architecture and motor voltage, there are two main topologies of analog integration
used in FOC applications, especially in sensorless FOC applications where an observer is required to estimate
the real-time position of the motor. The MSPM0G also provides an integrated hardware accelerator to calculate
the computations for efficient FOC performance at 30kHz PWM frequency or higher.
MSPM0Gx Analog Integration and Gate Driver
With the help of scalable analog integration, the MSPM0 can accurately sense the motor phase voltage, bus
voltage, current, and speed quickly to provide feedback to the FOC algorithm. Two programmable gain amplifiers
(PGAs) amplify the difference between phase currents sensed through two shunt resistors and a scaled DAC
output voltage, and the output of the PGAs directly can be sampled by internal ADCs. This topology is suited for
FOC applications that require high voltages, low-cost and high efficiency, such as servo drives, HVAC motors,
and large appliances.

SLAAE96 – MARCH 2023 BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 3
Submit Document Feedback MCUs
Copyright © 2023 Texas Instruments Incorporated
BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 MCUs www.ti.com
Vbus

MSPM0G150x
MSPM0G350x 1H 2H 3H
FOC 2H
Timer
Speed 3H 3-ph
6 PWM 3-ph.
Control BLDC/
Fault Gate
nFAULT PMSM
Detect driver 1L 2L 3L
2L
DAC R 3L

Vbus ADC Inv. Or


Current Sense x2
Non-Inv.
PGAs

LPF
Fault Bus Overcurrent Protection
Detect
LS
Comp

Figure 4. MSPM0G15x and MSPM0G35x Motor Control Block Diagram of FOC

MSPM0Gx and Gate Driver with Analog Integration


In lower voltage FOC applications, many gate driver or motor driver devices integrate up to three current sense
amplifers with programmable gain, which offloads analog requirements from the MSPM0Gx device. MSPM0Gx
devices without analog integration are available in packages as small as VSSOP-20 and 24-VQFN to reduce
system size and provide low cost. MSPM0 can accurately sense the motor phase voltage, bus voltage, current,
and speed quickly to provide feedback to the FOC algorithm using 12-bit simultananeous sampling 4-Mbps
ADCs. This topology is suited for FOC applications that are low-cost and small form factor, such as pumps, fans,
blowers, and small appliances.
Vbus
Optional MOSFET
MSPM0G110x and CSA integration

MSPM0G310x 1H 2H 3H
FOC 2H
Timer
Speed 3-ph. 3H 3-ph
6 PWM
Control BLDC BLDC/
SPI (opt.) driver PMSM
1L 2L 3L
Fault nFAULT 2L
3L
Detect
ADC LPF
CSAs

Vbus
Current Sense x3

Figure 5. MSPM0G11x and MSPM0G31x Motor Control Block Diagram of FOC

Solution Details
• Code Examples
– MSPM0 Sensorless FOC Library (access link)
• Supports DRV830x, DRV831x, DRV832x, DRV834x, DRV835x devices with integrated current sense
• Supports 3-phase gate driver solutions using MSPM0Gx integrated analog for current sense up to
650 V
• FOC Algorithm Libraries
– Hardware abstraction layer (HAL)
• Used to make the device-specific peripherals (for example, PWM, ADC, and Timer) generic across the
rest of the algorithm for easy porting.
– Space vector modulation (SVM)
• PWM control algorithm to create a continuously rotating space vector that generates appropriate gate
signals for the gate driver every PWM period.
– Clarke and Park transforms (and inverse)
• Mathematical modules used in the algorithm to achieve direct-quadrature-zero transform, which is a
crucial element of FOC theory. It is applied here to control three-phase stator and rotor qualities to
maximize torque.

4 BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 SLAAE96 – MARCH 2023
MCUs Submit Document Feedback
Copyright © 2023 Texas Instruments Incorporated
www.ti.com BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 MCUs

– Estimator
• Used to measure rotor flux magnitude and angle in sensorless FOC systems.
– PID controller
• A typical proportional-integral-derivative controller can be used to stabilize closed loop performance.
– User
• A module containing all user tunable parameters to achieve desired performance.
• Timer and ADC
– Generate 6 external PWM signals from one timer (TIMA0) and trigger 2 ADC module conversions to
simultaneously sample phase currents, phase voltages, and bus voltage
– PWM: Center-aligned complementary PWM with deadband insertion.

Figure 6. MSPM0Gx TIMA and ADC Sequence for FOC


• OPA – standard (STD) mode
Current Sense
Motor
Current
12-bit DAC
MSPM0G150x
Ext. Congurable voltage
Gain reference MSPM0G350x
+
Current Shunt
OPA ADC
Resistor Motor current sensing
-

Motor GND Programmable Gain

Figure 7. MSPM0Gx OPA Block Diagram for Current Sensing

– 6-MHz GBW, 4-V/µs slew rate, and 6-µV/°C drift in STD mode
• COMP – high-speed mode
Overcurrent Protecon
Motor MSPM0G150x
GND MSPM0G350x
OpAmps
Bus Shunt Motor Fault Event Timer
COMP
Resistor Current
8-bit DAC
6 PWM
Limi ng current threshold

Power GND

Figure 8. MSPM0Gx COMP Block Diagram for Current Protection

– The 8-bit DAC (1-µs settling time) inside COMP module enables a 40-ns response time for setting current
limit thresholds.

SLAAE96 – MARCH 2023 BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 5
Submit Document Feedback MCUs
Copyright © 2023 Texas Instruments Incorporated
BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 MCUs www.ti.com

Resources
Order an MSPM0 LaunchPad development kit and a DRV83xx EVM today to start evaluating MSPM0 for your
motor control system. Jump start your motor control design with MSPM0 code examples and interactive online
trainings. You can also find other resources under these links:
• MSPM0 Academy
• MSPM0 landing page
• DRV83xx EVM
– DRV8311HEVM / DRV8316REVM / DRV8317HEVM
– BOOSTXL-DRV8320RS
– BOOSTXL-DRV8323RH / BOOSTXL-DRV8323RS
– DRV8353RH-EVM / DRV8353RS-EVM
• MSPM0 LaunchPad development kit
• TI Precision Labs - Motor Drivers: Brushless-DC Basics

6 BLDC/PMSM Control Using Sensorless FOC Algorithm Based on MSPM0 SLAAE96 – MARCH 2023
MCUs Submit Document Feedback
Copyright © 2023 Texas Instruments Incorporated
IMPORTANT NOTICE AND DISCLAIMER
TI PROVIDES TECHNICAL AND RELIABILITY DATA (INCLUDING DATA SHEETS), DESIGN RESOURCES (INCLUDING REFERENCE
DESIGNS), APPLICATION OR OTHER DESIGN ADVICE, WEB TOOLS, SAFETY INFORMATION, AND OTHER RESOURCES “AS IS”
AND WITH ALL FAULTS, AND DISCLAIMS ALL WARRANTIES, EXPRESS AND IMPLIED, INCLUDING WITHOUT LIMITATION ANY
IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT OF THIRD
PARTY INTELLECTUAL PROPERTY RIGHTS.
These resources are intended for skilled developers designing with TI products. You are solely responsible for (1) selecting the appropriate
TI products for your application, (2) designing, validating and testing your application, and (3) ensuring your application meets applicable
standards, and any other safety, security, regulatory or other requirements.
These resources are subject to change without notice. TI grants you permission to use these resources only for development of an
application that uses the TI products described in the resource. Other reproduction and display of these resources is prohibited. No license
is granted to any other TI intellectual property right or to any third party intellectual property right. TI disclaims responsibility for, and you
will fully indemnify TI and its representatives against, any claims, damages, costs, losses, and liabilities arising out of your use of these
resources.
TI’s products are provided subject to TI’s Terms of Sale or other applicable terms available either on ti.com or provided in conjunction with
such TI products. TI’s provision of these resources does not expand or otherwise alter TI’s applicable warranties or warranty disclaimers for
TI products.
TI objects to and rejects any additional or different terms you may have proposed. IMPORTANT NOTICE

Mailing Address: Texas Instruments, Post Office Box 655303, Dallas, Texas 75265
Copyright © 2023, Texas Instruments Incorporated

You might also like