STM32Utils app allow to flash STM32 by using Bluetooth communication served by HC-05 module. The required modification impact just the hardware. Once implemented it you just need a phone with Bluetooth to flash or updated a firmware.
Basic wiring schematic sample as following (with Blue Pill).
For this procedure it has been used an Android terminal app with an USB-TTL cable connected to the HC-05.
- Connect the HC-05 module to a USB-Serial cable (GND to GND, VCC to VCC, RX to TX). Connect the USB-TTL cable to the phone with an OTG adapter. In the app there is an icon for connection on the top-right corner.
- Start the communication configuring the Serial port as the HC-05 module basic settings, verify the communication sending the command AT followed by the sequence CR+LF (using the Android app this can be automatic by the settings). If this command work it should return the word AT.
- Set the bluetooth module name (put your module name instead of STM32_01)
- Set the bluetooth module password (put your code instead of 0000)
- Set the new serial communication settings
- Now if you want to communicate again with the HC-05 you need to set the serial communication of the USB-TTL cable as following
Serial USB Terminal app settings, the sequence CR+LF is required after each AT command. In the second picture are the app settings after the configuration completed, to access again to the HC-05.
STM32Utils App & Phone Configurations
- Pair the Bluetooth module to your phone using the Bluetooth settings in Android. Remember the module has a password for pairing.
- In STM32Utils configure the initial name of your modules. The app will connect automatically to any paired bluetooth module with a name starting with these initials.
- In STM32Utils enable the Bluetooth option. The app will start to search for bluetooth devices and will show the result in the log. Once the bluetooth module is Attached you can push the Init Chipset button.