STM32_Smart V2 on Arduino IDE

Emilio Moretti
2 min readFeb 1, 2020

In this article I will guide you through the steps required to get this board working under Arduino

The board itself can be found at extremely low prices, and it comes with a nice 32 bit capable processor: https://stm32-base.org/boards/STM32F103C8T6-STM32-Smart-V2.0.html

The process of adding support to the Arduino IDE is properly documented but the hardest part is to actually get it to recognize the board. To install the IDE support simply follow the steps here: https://github.com/stm32duino/wiki/wiki/Getting-Started

In order to actually use the board you have to upload the bootloader. There is a LED attached to PC13 and the user button on PA0, which was not originally supported. I added support for it, and it has been added to the main repositories, so you can download the bootloader binary from here: https://github.com/rogerclarkmelbourne/STM32duino-bootloader/blob/master/bootloader_only_binaries/smart-v2.bin

The next step is to actually burn the bootloader. You can do it with a cheap STLink V2 or any other tool you have at hand. The pinout is pretty simple.

After connecting the required pins we can flash the new bootloader. The command is:

st-flash write bootloader_only_binaries/smart-v2.bin 0x8000000

(On Linux make sure you have st-flash installed from https://github.com/texane/stlink )

Finally, from the IDE, select the board as shown here:

Notes:

  1. The button will be mapped to pin 20, or just use PA0 when referencing to it
  2. The led will be mapped to pin 17. You can use LED_BUILTIN or PC13 to reference it.
  3. I was not able to get any serial communication working over CDC. If you manage to do it, please let me know how you did it.

--

--