If your ESC already comes with AM32, you can configure or flash it using one of the AM32 configuration tools available, the process is very straightforward as shown here: https://oscarliang.com/flash-update-am32-esc/. However, if your ESC has BLHeli_32, converting it to AM32 is a bit more complex. This step by step tutorial will guide you through the process.
For more information about ESCs, check out this buyer’s guide: https://oscarliang.com/esc/
Disclaimer: Official instructions are available on the AM32 homepage: https://am32.ca/. This tutorial demonstrates how I personally flash my ESC. Follow these instructions at your own risk; I am not responsible for any damages. I recommend familiarizing with the process on a spare ESC that you don’t need, so if anything goes wrong you won’t be grounded.
Table of Contents
Why Flash AM32?
A couple of reasons why you might want to switch from BLHeli32 to AM32:
- AM32 is a promising open source project, see overview: https://oscarliang.com/am32-esc-firmware-an-open-source-alternative-to-blheli32/
- BLHeli_32 is officially dead and no more updates: https://oscarliang.com/end-of-blheli_32/
However, if your ESC is working fine, consider just stay on BLHeli32 and keep flying. There’s is really nothing wrong to keep flying BLHeli32, unless there’s a bug or new features you want to have by upgrading to AM32.
Or just buy ESC with AM32 pre-installed to avoid all the hurdles:
- AliExpress: https://s.click.aliexpress.com/e/_Dm32AXj
- Amazon: https://amzn.to/3KrHz3R
- GetFPV: https://oscarliang.com/product-2lo6
Process Summary
Here are the simple steps to flash AM32 onto a BLHeli_32 ESC:
- Connect ESC to STLink V2 Programmer
- Remove write protection and erase the chip
- Install AM32 Bootloader on the ESC
- Flash AM32 Firmware
Is Your ESC AM32 Compatible?
At the moment, not every BLHeli_32 ESC is compatible with AM32. Before proceeding, check if your ESC is compatible: https://github.com/AlkaMotors/AM32-MultiRotor-ESC-firmware/wiki/List-of-Supported-Hardware
What You Need
ST-Link V2 Programmer, purchase here (under $10):
- Amazon: https://amzn.to/3XpI3f4
- AliExpress: https://s.click.aliexpress.com/e/_DCalVOh
STM32 ST-Link Utility: https://www.st.com/en/development-tools/stsw-link004.html
This software is needed for disabling write protection on the BLHeli_32 ESC, allowing you to install the AM32 bootloader. Alternatively, you can use STM32CubeProgrammer, which may require account registration to download.
Multi_ESC Config Tool: https://github.com/am32-firmware/AM32?tab=readme-ov-file#firmware-release–configuration-tool
This tool is used to flash AM32 firmware and configure the ESC using Betaflight passthrough, similar to BLHeli32Suite.
Download AM32 Bootloader file here: https://github.com/AlkaMotors/AM32_Bootloader_F051/tree/main/Bootloaders
To determine which bootloader file is right your ESC, refer to the supported hardware list: https://github.com/AlkaMotors/AM32-MultiRotor-ESC-firmware/wiki/List-of-Supported-Hardware
Example: For the Tekko32 4in1 ESC with the STM32 F051 processor, it’s listed under the target name FD6288, with the bootloader labeled PA2.
Click on the required bootloader file, then select “View raw” to download it.
Download AM32 Firmware file here: https://github.com/am32-firmware/AM32/releases
Ensure you get the correct firmware file for your ESC based on the target name and processor type. Incorrect firmware, the ESC simply won’t work (e.g., no response and makes three short beeps repeatedly when powered on). If you flashed the wrong firmware, you can still flash the correct one which should resolve these issues, at least that’s my experience.
Find the firmware file by target name and processor, then click the link to download.
Once you have downloaded the two necessary files, you are ready to begin the flashing process.
How to Flash AM32 Bootloader
Connecting STLink Programmer to ESC
ESC Side | ST-Link Tool |
SWC | SWCLK |
SWD | SWDIO |
GND | GND |
You need to find the tiny SWC and SWD pads for each ESC. Sometimes they are labelled which is easy to spot.
The locations of these pads are similar across different ESCs, and you can tell them apart by following the traces.
You also need to connect the ground (GND). You can use any GND on the ESC, including the XT60 GND.
Before connecting the STLink V2 tool to the ESC, ensure the ESC is powered by a LiPo battery or bench power supply via the XT60 connector.
In the ST-Link Utility, click on “Target” in the top menu, then “Settings,” and change Mode to “Hot Plug.” Leave the rest at default.
Removing Write Protection and Erasing the Chip
Disclaimer: Once you erase the chip, you cannot flash BLHeli32 back onto the ESC.
Click on “Target” in the top menu, then select “Option Bytes.”
Change “Read Out Protection” to Level 0, and click on “Unselect all” under Flash sectors protection. Click “Apply.”
You should see “Option Bytes Updated Successfully” in the console, indicating write protections have been removed.
Now, go to “Target,” then “Erase Chip” to erase BLHeli32 on the ESC. If you encounter an error, try “Erase Sectors” and select all as a workaround.
Installing AM32 Bootloader
Under “Target”, click on “Program”.
For F051 processors, ensure the Start address is 0x08000000. Select the bootloader file and check “Skip Flash Erase.”
Click “Start” to flash.
Removing SWC/SWD Wires
Once the bootloader is flashed, safely disconnect the ST-Link V2 tool and desolder the SWC, SWD, and GND wires from the ESC.
Flashing AM32
Once your ESC has the AM32 bootloader, it will be recognized by AM32 Configuration Tools, including the Multi_ESC config tool. There, you can flash the AM32 firmware and load the default settings via Betaflight passthrough.
Connect the ESC to your Betaflight flight controller and power the ESC.
In Multi ESC Config Tool, select the COM port of your FC and click “Connect”.
Go to the “Flash” tab and click on one of the ESCs you want to flash (M1, M2, M3, or M4). It should say “Connected – No EEprom”.
Load the firmware we downloaded earlier, then click “Flash Firmware”.
Once done, click on “Send Default Settings” to write the EEPROM.
Now repeat this for the other 3 ESC on the board, and you should now have a functional AM32 4in1 ESC!
Testing ESC
You can test the ESC by soldering a motor to it and attempting to spin it in the Betaflight Motor tab. If all went well, the ESC should work normally.
Configuring AM32
There are multiple tools you can use to configure AM32 ESC, including
- Multi ESC Config Tool (standalone tool)
- am32.ca (AM32 online tool – Chrome based)
- esc-configurator.com (Bluejay online tool – Chrome based)
In this tutorial I will explain what each setting does: https://oscarliang.com/best-am32-settings/
Conclusion
I hope you find this tutorial useful. Let me know if you have any questions. Happy flying!
4 comments
Sorry meant to say am32 unlockeR.
Might want to add info on am32 unlocked program by tridge on github
I flash same esc (tekko32 4in1) and its not work, motor is twitches and not spinning.
target AM32_WRAITH32V2_F051_2.12. fix my problem