STM32 Nucleo-F091RC¶
Support for the STM32 Nucleo-F091RC.
Overview¶
The Nucleo-F091 is a board from ST’s Nucleo family supporting a ARM Cortex-M0 STM32F091 microcontroller with 32Kb of RAM and 256Kb of ROM.
Hardware¶
MCU¶
MCU | STM32F091RC |
---|---|
Family | ARM Cortex-M0 |
Vendor | ST Microelectronics |
RAM | 32Kb |
Flash | 256Kb |
Frequency | up to 48MHz (using the on-board 8MHz Oszillator of the ST-Link) |
FPU | no |
Timers | 9 (8x 16-bit, 1x 32-bit [TIM2]) |
ADCs | 1x 12-bit |
UARTs | 8 |
SPIs | 2 |
I2Cs | 2 |
Vcc | 2.0V - 3.6V |
Datasheet | Datasheet |
Reference Manual | Reference Manual |
Programming Manual | Programming Manual |
Board Manual | Board Manual |
MCU¶
MCU | STM32F091RC |
---|---|
Family | ARM Cortex-M0 |
Vendor | ST Microelectronics |
RAM | 32Kb |
Flash | 256Kb |
Frequency | up to 48MHz (using the on-board 8MHz Oszillator of the ST-Link) |
FPU | no |
Timers | 9 (8x 16-bit, 1x 32-bit [TIM2]) |
ADCs | 1x 12-bit |
UARTs | 8 |
SPIs | 2 |
I2Cs | 2 |
Vcc | 2.0V - 3.6V |
Datasheet | Datasheet |
Reference Manual | Reference Manual |
Programming Manual | Programming Manual |
Board Manual | Board Manual |
RIOT static pin mapping¶
please refer to this document for the pin mapping as implemenented in boards/nucleo-f091/include/periph_conf.h
Implementation Status¶
Device | ID | Supported | Comments |
---|---|---|---|
MCU | STM32F091RC | partly | Energy saving modes not fully utilized |
Low-level driver | GPIO | no | |
PWM | no | ||
UART | full | ||
I2C | no | ||
SPI | no | ||
USB | no | ||
Timer | full |
Flashing the device¶
The ST Nucleo-F091 board includes an on-board ST-LINK V2 programmer. The easiest way to program the board is to use OpenOCD. Once you have installed OpenOCD (look here for installation instructions), you can flash the board simply by typing
1 | make BOARD=nucleo-f091 flash
|
1 | make BOARD=nucleo-f091 debug
|
Supported Toolchains¶
For using the ST Nucleo-F091 board we strongly recommend the usage of the GNU Tools for ARM Embedded Processors toolchain.
-
CLOCK_CORECLOCK
¶ 1
(48000000U)
-
CLOCK_HSE
¶ 1
(8000000U)
-
CLOCK_LSE
¶ 1
(1)
-
CLOCK_AHB_DIV
¶ 1
RCC_CFGR_HPRE_DIV1
-
CLOCK_AHB
¶ 1
(CLOCK_CORECLOCK / 1)
-
CLOCK_APB1_DIV
¶ 1
RCC_CFGR_PPRE_DIV1 /* max 48MHz */
-
CLOCK_APB1
¶ 1
(CLOCK_CORECLOCK / 1)
-
CLOCK_APB2
¶ 1
(CLOCK_APB1)
-
CLOCK_PLL_PREDIV
¶ 1
(1)
-
CLOCK_PLL_MUL
¶ 1
(6)
-
const timer_conf_t
timer_config
()¶ 1 2 3 4 5 6 7 8 9
= { { .dev = TIM1, .max = 0x0000ffff, .rcc_mask = RCC_APB2ENR_TIM1EN, .bus = APB2, .irqn = TIM1_CC_IRQn } }
-
TIMER_0_ISR
¶ 1
isr_tim1_cc
-
TIMER_NUMOF
¶ 1
(sizeof(timer_config) / sizeof(timer_config[0]))
-
const uart_conf_t
uart_config
()¶
-
UART_0_ISR
¶ 1
(isr_usart2)
-
UART_1_ISR
¶ 1
(isr_usart1)
-
UART_2_ISR
¶ 1
(isr_usart3_8)
-
UART_NUMOF
¶ 1
(sizeof(uart_config) / sizeof(uart_config[0]))
-
const uint8_t
spi_divtable
()¶ 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
= { { 7, 6, 5, 2, 1 }, { 7, 6, 5, 2, 1 } }
-
const spi_conf_t
spi_config
()¶ 1 2 3 4 5 6 7 8 9 10 11 12
= { { .dev = SPI1, .mosi_pin = GPIO_PIN(PORT_A, 7), .miso_pin = GPIO_PIN(PORT_A, 6), .sclk_pin = GPIO_PIN(PORT_A, 5), .cs_pin = GPIO_PIN(PORT_B, 6), .af = GPIO_AF0, .rccmask = RCC_APB2ENR_SPI1EN, .apbbus = APB2 } }
-
SPI_NUMOF
¶ 1
(sizeof(spi_config) / sizeof(spi_config[0]))
-
const i2c_conf_t
i2c_config
()¶ 1 2 3 4 5 6 7 8 9 10 11 12 13 14
= { { .dev = I2C1, .speed = I2C_SPEED_NORMAL, .scl_pin = GPIO_PIN(PORT_B, 8), .sda_pin = GPIO_PIN(PORT_B, 9), .scl_af = GPIO_AF1, .sda_af = GPIO_AF1, .bus = APB1, .rcc_mask = RCC_APB1ENR_I2C1EN, .rcc_sw_mask = RCC_CFGR3_I2C1SW, .irqn = I2C1_IRQn, } }
-
I2C_0_ISR
¶ 1
isr_i2c1
-
I2C_NUMOF
¶ 1
(sizeof(i2c_config) / sizeof(i2c_config[0]))
-
const pwm_conf_t
pwm_config
()¶ 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
= { { .dev = TIM2, .rcc_mask = RCC_APB1ENR_TIM2EN, .chan = { { .pin = GPIO_PIN(PORT_B, 3) , .cc_chan = 1 }, { .pin = GPIO_PIN(PORT_B, 10) , .cc_chan = 2 }, { .pin = GPIO_PIN(PORT_B, 11) , .cc_chan = 3 }, { .pin = GPIO_UNDEF, .cc_chan = 0 } }, .af = GPIO_AF2, .bus = APB1 }, { .dev = TIM3, .rcc_mask = RCC_APB1ENR_TIM3EN, .chan = { { .pin = GPIO_PIN(PORT_B, 4) , .cc_chan = 0 }, { .pin = GPIO_PIN(PORT_C, 7) , .cc_chan = 1 }, { .pin = GPIO_PIN(PORT_C, 8), .cc_chan = 2 }, { .pin = GPIO_PIN(PORT_C, 9), .cc_chan = 3 } }, .af = GPIO_AF0, .bus = APB1 } }
-
PWM_NUMOF
¶ 1
(sizeof(pwm_config) / sizeof(pwm_config[0]))
-
RTC_NUMOF
¶ Nucleos with MB1136 C-02 or MB1136 C-03 -sticker on it have the required LSE oscillator provided on the X2 slot.
1
(1U)
See Nucleo User Manual UM1724 section 5.6.2.
-
ADC_CONFIG
¶ 1 2 3 4 5 6 7 8
{ \ { GPIO_PIN(PORT_A, 0), 0 },\ { GPIO_PIN(PORT_A, 1), 1 },\ { GPIO_PIN(PORT_A, 4), 4 },\ { GPIO_PIN(PORT_B, 0), 8 },\ { GPIO_PIN(PORT_C, 1), 11 },\ { GPIO_PIN(PORT_C, 0), 10 } \ }
-
ADC_NUMOF
¶ 1
(6)