
1 Overview
The position control mode is available since the version v5.4.3 of the X-CUBE-MCSDK Expansion Package. It
allows the electric drive to move the motor to a specified target mechanical position (angle) in a settled time
(duration) following a programmed trajectory composed of three phases: acceleration, constant speed, and
deceleration. Following such defined trajectory is mandatory to reach the target position with zero angular speed
and therefore avoid oscillations around the settled position.
1.1 Main features
• Position control mode available for all the control boards supported by X-CUBE-MCSDK
• Compatible with:
– Quadrature encoder (with index signal)
– Magnetic sensor (with encoder interface)
• Trajectory calculator
– Constant jerk
– Acceleration integration
– Speed integration
– Position integration
• Current control for field orientation (FOC)
1.2 Hardware prerequisites
• A control board supported by X-CUBE-MCSDK, featuring an STM32 microcontroller based on the Arm
®
Cortex
®
-M core
• A power board or expansion board supported by X-CUBE-MCSDK (three-shunt current sensing is advised)
• Optionally, a complete inverter supported by X-CUBE-MCSDK
• The main power supply (according to the host board used)
• A USB Type-A to Mini-B cable for programming and debugging (see the exact requirements of the board
used)
• A PMSM motor with quadrature encoder (with index signal)
Note: Arm is a registered trademark of Arm Limited (or its subsidiaries) in the US and/or elsewhere.
All other trademarks are the property of their respective owners.
1.3 Software prerequisites
• STSW-LINK009: ST-LINK USB driver
• STSW-LINK004: STM32 ST-LINK Utility
– STSW-LINK004 is needed only to update ST-LINK firmware to the latest version
• A Windows
®
PC with the supported development toolchain:
– IAR
™
– EWARM
– Keil
®
- MDK-ARM
– STMicroelectronics - STM32CubeIDE
• X-CUBE-MCSDK version v5.4.3 or later
AN5464
Overview
AN5464 - Rev 1
page 2/22