Black Pill STM32H523

Overview

The WeAct STM32H523CE Core Board is a low-cost and bare-bone development board made in the famous “blackpill” package. It features the STM32H523CE, a high-performance microcontroller based on an Arm Cortex-M33 processor.

Hardware

The STM32H523CE-based Black Pill board provides the following hardware components:

  • STM32H523CE in 48-pin package

  • ARM 32-bit Cortex-M33 CPU with FPU

  • 250 MHz max CPU frequency

  • VDD from 1.7 V to 3.6 V

  • 512 KB Flash

  • 274 KB SRAM

  • TIM

  • ADC

  • USART

  • I2C

  • SPI

  • USB FS

  • FDCAN

  • RTC

Supported Features

The blackpill_h523ce board supports the hardware features listed below.

on-chip / on-board
Feature integrated in the SoC / present on the board.
2 / 2
Number of instances that are enabled / disabled.
Click on the label to see the first instance of this feature in the board/SoC DTS files.
vnd,foo
Compatible string for the Devicetree binding matching the feature.
Click on the link to view the binding documentation.

blackpill_h523ce/stm32h523xx target

Type

Location

Description

Compatible

CPU

on-chip

ARM Cortex-M33 CPU1

arm,cortex-m33

ADC

on-chip

STM32 ADC1

st,stm32-adc

CAN

on-chip

STM32 FDCAN CAN FD controller1

st,stm32-fdcan

Clock control

on-chip

STM32H5 RCC (Reset and Clock controller)1

st,stm32h5-rcc

on-chip

STM32 HSE Clock1

st,stm32-hse-clock

on-chip

STM32 HSI Clock1

st,stm32h7-hsi-clock

on-chip

Generic fixed-rate clock provider2 1

fixed-clock

on-chip

STM32 LSE Clock1

st,stm32-lse-clock

on-chip

STM32U5 PLL1 1

st,stm32u5-pll-clock

on-chip

STM32 Microcontroller Clock Output (MCO)2

st,stm32-clock-mco

Counter

on-chip

STM32 counters4

st,stm32-counter

DAC

on-chip

STM32 family DAC1

st,stm32-dac

DMA

on-chip

STM32U5 DMA controller2

st,stm32u5-dma

Ethernet

on-chip

STM32 Ethernet Controller1

st,stm32-ethernet-controller

on-chip

STM32H7 Ethernet1

st,stm32h7-ethernet

Flash controller

on-chip

STM32 Family flash controller1

st,stm32-flash-controller

GPIO & Headers

on-chip

STM32 GPIO Controller6

st,stm32-gpio

I2C

on-chip

STM32 I2C V2 controller1 1

st,stm32-i2c-v2

I2S

on-chip

STM32H7 I2S controller3

st,stm32h7-i2s

on-chip

STM32 SAI controller2

st,stm32-sai

I3C

on-chip

STM32H5 I3C controller2

st,stm32-i3c

Input

on-board

Group of GPIO-bound input keys1

gpio-keys

Interrupt controller

on-chip

ARMv8-M NVIC (Nested Vectored Interrupt Controller)1

arm,v8m-nvic

on-chip

STM32G0 External Interrupt Controller1

st,stm32g0-exti

LED

on-board

Group of GPIO-controlled LEDs1

gpio-leds

MDIO

on-chip

STM32 MDIO Controller1

st,stm32-mdio

Memory controller

on-chip

STM32 Flexible Memory Controller (FMC)1

st,stm32-fmc

MMU / MPU

on-chip

ARMv8-M MPU (Memory Protection Unit)1

arm,armv8m-mpu

MTD

on-chip

STM32 flash memory1

st,stm32-nv-flash

PHY

on-chip

This binding is to be used by all the usb transceivers which are built-in with USB IP1

usb-nop-xceiv

Pin control

on-chip

STM32 Pin controller1

st,stm32-pinctrl

PWM

on-chip

STM32 PWM1 4

st,stm32-pwm

Reset controller

on-chip

STM32 Reset and Clock Control (RCC) Controller1

st,stm32-rcc-rctl

RNG

on-chip

STM32 Random Number Generator1

st,stm32-rng

RTC

on-chip

STM32 RTC1

st,stm32-rtc

Sensors

on-chip

STM32 Digital Temperature Sensor1

st,stm32-digi-temp

on-chip

STM32 family TEMP node for production calibrated sensors with two calibration temperatures1

st,stm32-temp-cal

on-chip

STM32 VREF+1

st,stm32-vref

on-chip

STM32 VBAT1

st,stm32-vbat

Serial controller

on-chip

STM32 USART1 2

st,stm32-usart

on-chip

STM32 LPUART1

st,stm32-lpuart

SMbus

on-chip

STM32 SMBus controller2

st,stm32-smbus

SPI

on-chip

STM32H7 SPI controller1 2

st,stm32h7-spi

Timer

on-chip

ARMv8-M System Tick1

arm,armv8m-systick

on-chip

STM32 low-power timer (LPTIM)2

st,stm32-lptim

on-chip

STM32 timers1 4

st,stm32-timers

USB

on-chip

STM32 USB controller1

st,stm32-usb

Watchdog

on-chip

STM32 watchdog1

st,stm32-watchdog

on-chip

STM32 system window watchdog1

st,stm32-window-watchdog

Connections and IOs

Default Zephyr Peripheral Mapping:

  • UART_1 TX/RX : PA9 / PA10

  • I2C1 SCL/SDA : PB6 / PB7

  • SPI1 CS/SCK/MISO/MOSI : PA4 / PA5 / PA6 / PA7 (routed to footprint for external flash)

  • PWM_3_CH3 : PB0

  • PWM_3_CH4 : PB1

  • ADC_1 : PA1

  • USER_PB : PA0

  • USER_LED : PC13

Programming and Debugging

The blackpill_h523ce board supports the runners and associated west commands listed below.

flash debug rtt attach debugserver
blackmagicprobe
dfu-util ✅ (default)
jlink
openocd ✅ (default)

There are 2 main entry points for flashing STM32H5X SoCs: one using the ROM bootloader, and another by using the SWD debug port (which requires additional hardware). Flashing using the ROM bootloader requires a special activation pattern, which can be triggered by using the BOOT0 pin.

Flashing

Installing dfu-util

It is recommended to use at least v0.8 of dfu-util. The package available in Debian/Ubuntu can be quite old, so you might have to build dfu-util from source.

There is also a Windows version which works, but you may have to install the right USB drivers with a tool like Zadig.

Flashing an Application

Connect a USB-C cable and the board should power ON. Force the board into DFU mode by keeping the BOOT0 switch pressed while pressing and releasing the NRST switch.

The dfu-util runner is supported on this board and so a sample can be built and tested easily.

# From the root of the zephyr repository
west build -b blackpill_h523ce samples/basic/blinky -- -DCONFIG_BOOT_DELAY=5000
west flash

Debugging

The board can be debugged by installing the included 100 mil (0.1 inch) header, and attaching an SWD debugger to the 3V3 (3.3V), GND, SCK, and DIO pins on that header.

References