STM32-MICRIUM

Overview

The STM32-MICRIUM evaluation board is a development platform for the STM32F107VCT6 microcontroller. It exposes the Ethernet MAC, USB OTG full speed, CAN, an SD card socket and an RS-232 port of the connectivity line STM32F107, together with an on-board SEGGER J-Link debugger.

More information about the board can be found in the STM32-MICRIUM User Manual [1].

Hardware

  • STM32F107VCT6 microcontroller in an LQFP100 package

  • Arm® 32-bit Cortex®-M3 CPU

  • 256 KB of Flash

  • 64 KB of SRAM

  • 25 MHz crystal oscillator

  • 32.768 kHz crystal oscillator for the RTC

  • 10/100 Ethernet with a TI DP83848CVV PHY in MII mode

  • USB OTG full speed on a Micro-AB connector with an STMPS2141 VBUS power switch

  • One CAN channel with an SN65HVD230 transceiver

  • SD card socket

  • STLM75 temperature sensor

  • RS-232 with hardware flow control on a DB-9 connector

  • Three user LEDs (green, orange and red)

  • 46-pin extension connector and a prototyping area

  • On-board SEGGER J-Link (JTAG and SWD) on a mini-B USB connector

  • Powered from the J-Link USB connector or from a 5V screw terminal

For more details on the microcontroller refer to the STM32F107VC on www.st.com [2] and the STM32F105xx/107xx reference manual [3].

Supported Features

The stm32_micrium 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.

stm32_micrium/stm32f107xc target

On-target memory for this board target: 64 KiB of RAM, 256 KiB of Flash.

Type

Location

Description

Compatible

CPU

on-chip

ARM Cortex-M3 CPU1

arm,cortex-m3

ADC

on-chip

STM32F1 ADC1

st,stm32f1-adc

CAN

on-chip

STM32 CAN controller11

st,stm32-bxcan

Clock control

on-chip

STM32 RCC (Reset and Clock controller)1

st,stm32-rcc

on-chip

STM32 HSE Clock1

st,stm32-hse-clock

on-chip

Generic fixed-rate clock provider12

fixed-clock

on-chip

STM32F105/F107 Main PLL1

st,stm32f105-pll-clock

on-chip

STM32F105/F107 PLL21

st,stm32f105-pll2-clock

on-chip

STM32F1 Microcontroller Clock Output (MCO)1

st,stm32f1-clock-mco

Counter

on-chip

STM32 counters7

st,stm32-counter

DAC

on-chip

STM32 family DAC1

st,stm32-dac

DMA

on-chip

STM32 DMA controller (V2bis) for the stm32F0, stm32F1 and stm32L1 soc families2

st,stm32-dma-v2bis

Ethernet

on-chip

ST STM32 Ethernet MAC1

st,stm32-ethernet

on-chip

Synopsys DesignWare MAC MDIO controller1

snps,dwmac-mdio

on-board

Generic MII PHY1

ethernet-phy

on-chip

Synopsys DesignWare MAC PTP (Precision Time Protocol) Clock1

snps,dwmac-ptp-clock

Flash controller

on-chip

STM32 Family flash controller1

st,stm32-flash-controller

GPIO & Headers

on-chip

STM32 GPIO Controller5

st,stm32-gpio

I2C

on-chip

STM32 I2C V1 controller11

st,stm32-i2c-v1

Interrupt controller

on-chip

ARMv7-M NVIC (Nested Vectored Interrupt Controller)1

arm,v7m-nvic

on-chip

STM32 External Interrupt Controller1

st,stm32-exti

LED

on-board

Group of GPIO-controlled LEDs1

gpio-leds

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

STM32F1 Pin controller1

st,stm32f1-pinctrl

Power management

on-chip

STM32 power controller1

st,stm32-pwr

on-chip

STM32F1-like wake-up pins controller1

st,stm32f1-pwr-wkupctrl

PWM

on-chip

STM32 PWM5

st,stm32-pwm

Reset controller

on-chip

STM32 Reset and Clock Control (RCC) Controller1

st,stm32-rcc-rctl

RTC

on-chip

STM32 RTC1

st,stm32-rtc

Sensors

on-board

LM75 Digital Temperature Sensor with 2-Wire Interface1

lm75

on-chip

STM32 quadrature decoder5

st,stm32-qdec

on-chip

STM32 Internal Temperature Sensor1

st,stm32-temp

Serial controller

on-chip

STM32 USART12

st,stm32-usart

on-chip

STM32 UART2

st,stm32-uart

SMbus

on-chip

STM32 SMBus controller2

st,stm32-smbus

SPI

on-chip

STM32 SPI controller12

st,stm32-spi

Timer

on-chip

ARMv7-M System Tick1

arm,armv7m-systick

on-chip

STM32 timers7

st,stm32-timers

USB

on-chip

STM32 OTGFS controller1

st,stm32-otgfs

Watchdog

on-chip

STM32 watchdog1

st,stm32-watchdog

on-chip

STM32 system window watchdog1

st,stm32-window-watchdog

Default Zephyr Peripheral Mapping:

  • USART2 TX/RX/RTS/CTS : PD5/PD6/PD4/PD3 (RS-232 connector CN7)

  • I2C1 SCL/SDA : PB6/PB7 (STLM75 at address 0x48, OS/INT on PB5)

  • SPI1 SCK/MISO/MOSI/CS : PA5/PA6/PA7/PA8 (SD card socket)

  • SD card detect : PE6

  • CAN1 RX/TX : PD0/PD1

  • Ethernet MII : PA0, PA1, PA3, PB8, PB10, PB11, PB12, PB13, PC2, PC3, PD8 to PD12

  • Ethernet MDC/MDIO : PC1/PA2

  • Ethernet PHY interrupt : PE5

  • USB OTG FS DM/DP/VBUS/ID : PA11/PA12/PA9/PA10

  • LD1 (green) : PD13

  • LD2 (orange) : PD14

  • LD3 (red) : PD15

System Clock

The system clock is driven by the 25MHz crystal through PLL2 and the main PLL: the HSE is divided by 5 and multiplied by 8 in PLL2 (40 MHz), then divided by 5 and multiplied by 9 in the main PLL, giving a 72 MHz system clock. The OTG FS clock is the PLL VCO output divided by 3 (48 MHz). The RTC runs from the 32.768kHz crystal.

Ethernet

The DP83848 PHY is strapped to address 1 and drives the MAC in MII mode from its own 25 MHz crystal.

USB

The board cannot be powered from the OTG connector. The STMPS2141 power switch on PE1 supplies VBUS in host mode; it is not driven by Zephyr, which uses the controller in device mode only.

CAN

The CAN bus is available on CN3 pins 28 (CAN_L) and 30 (CAN_H). The on-board 120 ohm termination resistor is connected by fitting JP1 (not fitted by default).

Boot options

JP4 (BOOT0) and JP3 (BOOT1) select the boot source. In the default setting JP4 selects the user flash, which is what Zephyr expects.

Programming and Debugging

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

flash debug attach debugserver rtt reset
jlink ✅ (default) ✅ (default) ✅ ✅ ✅ ✅

The board integrates a SEGGER J-Link debug probe. Its SWDIO and SWCLK lines are always wired to the STM32F107VCT6; the remaining JTAG signals (TDI, TDO and TRST) pass through solder bridges SB1 to SB3, which are closed by default, so both JTAG and SWD are available. The Zephyr runners use SWD, which works in either bridge configuration. With JP2 open (default) the on-board probe is used; closing JP2 disconnects it so that an external probe can be attached to the JTAG/SWD signals on CN3. PA15, PB3 and PB4 are shared between the JTAG port and CN3, so using them as GPIOs requires opening SB1 to SB3 and disabling JTAG through the swj-cfg pinctrl property.

Applications for the stm32_micrium board can be built and flashed in the usual way (see Building an Application and Run an Application for more details).

Flashing

The default runner is J-Link [4]. Connect the J-Link mini-B USB connector (CN5) to the host, which also powers the board when JP5 is in its default position.

Here is an example for the Blinky application.

# From the root of the zephyr repository
west build -b stm32_micrium samples/basic/blinky
west flash

You will see the green LED blinking every second.

Debugging

The console is available on the RS-232 connector CN7 at 115200 bauds. The RTS and CTS lines are wired to the connector and routed to USART2, but hardware flow control is off by default so that the console works with a three-wire cable. Enable flow control with an overlay:

&usart2 {
    hw-flow-control;
};

You can debug an application in the usual way. Here is an example for the Hello World application.

# From the root of the zephyr repository
west build -b stm32_micrium samples/hello_world
west debug

References