Top 10 STM32 projects for beginners (Blue Pill and Nucleo)

The 10 best STM32 projects for students: bare-metal blink, timer PWM servo, Blue Pill clock, thermometer, voltmeter, kitchen scale and Nucleo serial console, with code.

In short

What are the best STM32 projects?

STM32 is a family of 32-bit ARM microcontrollers used in industry. The easiest way to learn it is on a Blue Pill, Black Pill or Nucleo board. Begin with the bare-metal blink to see how registers and clocks work, then build the reaction timer, traffic light and sensor projects below.

Projects
10 guided builds
Levels
Intermediate
Build time
2.2 h to 3 h

The 10 projects

All ten are guided builds written for STM32 boards (Blue Pill, Black Pill, Nucleo). They are Intermediate level because STM32 teaches clocks and peripherals that Arduino hides.

  1. Bare-metal blink on STM32

    Program a Blue Pill without Arduino: clocks, GPIO registers and a timer interrupt.

    Intermediate3 hLearningOpen the build →
  2. Blue Pill reaction timer

    A Blue Pill lights an LED after a random wait and times how fast you press a button, printing the result over USB serial.

    Intermediate2.2 hGames & ToysOpen the build →
  3. Blue Pill traffic light with a crossing button

    A Blue Pill runs a model traffic light and a pedestrian button that asks for a safe change, with a walk and wait pair of LEDs.

    Intermediate2.3 hSafetyOpen the build →
  4. Blue Pill humidity gauge

    A Blue Pill reads a DHT22 and shows humidity and temperature on an OLED, with a bar and a mark for the 40 to 60 percent comfort band.

    Intermediate2.3 hEnvironmentOpen the build →
  5. Blue Pill one-wire thermometer

    A Blue Pill reads a DS18B20 probe over one wire and shows the temperature with the lowest and highest values on an OLED.

    Intermediate2.3 hSensorsOpen the build →
  6. 12-bit voltmeter on a Blue Pill

    A Blue Pill reads a knob with its 12-bit ADC and shows the counts, the voltage and what a 10-bit board would read for the same input.

    Intermediate2.5 hTest & MeasurementOpen the build →
  7. Servo sweep with an STM32 timer

    A Blue Pill turns a knob position into a servo angle using a hardware timer to make the 50 Hz pulses, with the servo on its own power.

    Intermediate2.3 hRoboticsOpen the build →
  8. Nucleo serial command console

    A Nucleo board reads text commands over its USB serial link to turn LEDs on and off, report the uptime and print a help list.

    Intermediate2.5 hCommunicationOpen the build →
  9. Blue Pill clock with a DS3231

    A Blue Pill reads a DS3231 clock chip over I2C and shows the time and date on an OLED, with one button to set the minutes.

    Intermediate2.3 hLearningOpen the build →
  10. Blue Pill kitchen scale

    A Blue Pill reads a 5 kg bar load cell through an HX711 amplifier, tares on a button and shows grams on an OLED, with a serial command to calibrate against a known weight.

    Intermediate2.8 hTest & MeasurementOpen the build →

Before you start

Every build has the full parts list, wiring table, tested code and troubleshooting. Check the circuit or sketch first in the code space or the circuit builder, then order parts with the Buy at Geekobot links on each project page. ElectroLark does not sell parts.

New to the basics? Take the free microcontrollers course, or browse all projects and final-year project briefs.

STM32 projects: common questions

Is STM32 hard for beginners?

It has more to learn than an Arduino because you configure clocks, pins and timers yourself. Start with the bare-metal blink, then move through the timer and sensor projects in order.

Which STM32 board should I start with?

A Blue Pill or Black Pill is the cheapest start. A Nucleo board gives a built-in programmer. The guides list the exact board.

Why learn STM32 instead of Arduino?

STM32 chips are used in real products, and ECE and EEE syllabi and placements often expect ARM Cortex-M knowledge. Arduino is easier first; STM32 is a step towards industry practice.

Can I use the Arduino IDE with STM32?

Yes, with the STM32 core installed for many boards. The guides here say which toolchain each build uses.

Are these suitable for mini projects?

Yes. The voltmeter, kitchen scale and servo timer builds make solid embedded mini projects for ECE and EEE.