This is the documentation for the latest (main) development branch of HPM SDK. If you are looking for the documentation of previous releases, use the drop-down menu on the left and select the desired version.

14.1. BLDC Trapezoidal Wave Control

14.1.1. Overview

Bldc_block project demonstrates speed control of the BLDC.

  • Control by trapezoidal wave algorithm

14.1.2. Configurations

Note

This code does not support any compilation optimization, please turn off compilation optimization

14.1.3. Running the Demo

The motor runs at a speed of 20r/s. The following data can be configured by serial console :

speed float, range +40~-40, unit r/s.

The serial console message is as follows:

Mode selection:
0. Location mode.
1. Speed mode.
Enter mode code:
1
Speed mode, motor run, speed is: 20.000000.
Input speed:
10.5

Speed mode, motor run, speed is: 10.500000.
Input speed:

Warning

Pay attention to the current size, when abnormalities occur, please cut off the power at any time