IntroductionIn this bare-metal STM32 project, we blink an LED connected in current-sinking configuration on a custom board — no libraries, just direct register access!The LED anode is connected to VCC (3.3V) through a current-limiting resistor, and the cathode is tied to PF2. This common setup lets the GPIO pin control the LED by sinking current when pulled low.Perfect for learning low-level GPIO control on custom hardware.
Parts Needed
- Custom STM32 board (your own design with GPIOF access)
- One LED
- 220–330 Ω resistor (connected between VCC and LED anode)
- Programmer (ST-Link or similar)
- Bare-metal development environment
Circuit Connection
- LED anode → resistor → VCC (3.3V)
- LED cathode → PF2
- No pull-up needed






Comments