Difference between revisions of "STM32 Beginner - Getting started"

From Stm32World Wiki
Jump to navigation Jump to search
Line 8: Line 8:
 
[[File:ST-Link Bunch.jpg|200px|thumb|A pile of cheap Chinese ST-Link clones]]
 
[[File:ST-Link Bunch.jpg|200px|thumb|A pile of cheap Chinese ST-Link clones]]
  
The [[ST-Link]] is a device especially designed to flash and debug [[STM32]] [[MCU]]'s. [[ST]] can provide these at a reasonable price (< $20) but there are also a lot of Chinese "clones" available.  The image to the right show a bunch of these clones.
+
The [[ST-Link]] is a device especially designed to flash and debug [[STM32]] [[MCU]]'s.
 +
 
 +
[[File:STLink.jpg|600px]]
 +
 
 +
[[ST]] can provide these at a reasonable price (< $20) but there are also a lot of Chinese "clones" available.  The image to the right show a bunch of these clones.
  
 
While the original [[ST-Link]] devices provide additional features, the Chinese clones do get the job done and they have one benefit over the original that the pins on the device are clearly labelled.  For some incomprehensible reason, [[ST]] decided not to label the pins on their device and that is really annoying in daily use.
 
While the original [[ST-Link]] devices provide additional features, the Chinese clones do get the job done and they have one benefit over the original that the pins on the device are clearly labelled.  For some incomprehensible reason, [[ST]] decided not to label the pins on their device and that is really annoying in daily use.

Revision as of 03:58, 12 March 2022

Getting started with STM32 development is a daunting task.

Prerequisites

ST-Link

A pile of cheap Chinese ST-Link clones

The ST-Link is a device especially designed to flash and debug STM32 MCU's.

STLink.jpg

ST can provide these at a reasonable price (< $20) but there are also a lot of Chinese "clones" available. The image to the right show a bunch of these clones.

While the original ST-Link devices provide additional features, the Chinese clones do get the job done and they have one benefit over the original that the pins on the device are clearly labelled. For some incomprehensible reason, ST decided not to label the pins on their device and that is really annoying in daily use.

Development Board

As mentioned earlier, there's a lot of different STM32 MCU variants and there's almost as many different development boards.

A very popular model was/is the so-called "Blue Pill" board:

Blue Pill top.jpg

There are different variants of these boards, but they are supposed to include a STM32F103 MCU. The problem is that almost none of them are. There are at least 6-8 Chinese companies making "clones" of the STM32F103 processor. Some of these are probably genuine MCUs with a properly licensed ARM core, that just happens to use the same memory map like the original. Some of these are labelled correctly and identifies themselves as "GD32F103" (from GigaDevice), HK32F103 or something else. Unfortunately some are labelled STM32F103xxx and it can be extremely hard to know which is which:

Fake STM32F103.jpg Real STM32F103.jpg
Fake STM32F103 (possibly a HK32) from some random Blue Pill Real STM32F103 from my own Green Pill board

Arduino

Before diving into using the Arduino IDE with STM32 development boards, I would like to stress that I think it is a horrible approach to learning.

https://github.com/stm32duino/BoardManagerFiles/raw/main/package_stmicroelectronics_index.json

Stm32CubeIde

To be added

Miscellaneous Links

Arduino

To be added

Stm32CubeIde

To be added