25 #ifndef CONFIG_BOARD_HAS_LSE
26 #define CONFIG_BOARD_HAS_LSE 1
29 #include "periph_cpu.h"
31 #include "cfg_rtt_default.h"
53 #define DMA_0_ISR isr_dma1_channel2
54 #define DMA_1_ISR isr_dma1_channel3
55 #define DMA_2_ISR isr_dma1_channel4
56 #define DMA_3_ISR isr_dma1_channel5
57 #define DMA_4_ISR isr_dma1_channel7
58 #define DMA_5_ISR isr_dma2_channel6
59 #define DMA_6_ISR isr_dma2_channel4
61 #define DMA_NUMOF ARRAY_SIZE(dma_config)
109 #if !MODULE_PERIPH_DAC
119 #define ADC_NUMOF ARRAY_SIZE(adc_config)
124 #define VBAT_ADC ADC_LINE(7)
129 #define VREFINT_ADC ADC_LINE(6)
139 #ifndef VREFBUF_ENABLE
140 #define VREFBUF_ENABLE (1)
156 #if !MODULE_PERIPH_SPI
164 #define DAC_NUMOF ARRAY_SIZE(dac_config)
177 .rcc_mask = RCC_AHB3ENR_FMCEN,
178 #if MODULE_PERIPH_FMC_NOR_SRAM
214 #if MODULE_PERIPH_FMC_16BIT
246 .address = 0x64000000,
252 .r_timing = { .addr_setup = 6,
254 .bus_turnaround = 1, },
263 .address = 0x60000000,
275 .r_timing = { .addr_setup = 1,
277 .bus_turnaround = 2, },
285 #define FMC_BANK_NUMOF ARRAY_SIZE(fmc_bank_config)
294 .data_offset = 0x80000,
304 #define LCD_FMC_NUMOF 1
324 .rcc_mask = RCC_APB1ENR1_I2C1EN,
325 .rcc_sw_mask = RCC_CCIPR_I2C1SEL_1,
326 .irqn = I2C1_ER_IRQn,
340 .rcc_mask = RCC_APB1ENR1_I2C2EN,
341 .rcc_sw_mask = RCC_CCIPR_I2C2SEL_1,
342 .irqn = I2C2_ER_IRQn,
346 #define I2C_0_ISR isr_i2c1_er
347 #define I2C_1_ISR isr_i2c2_er
349 #define I2C_NUMOF ARRAY_SIZE(i2c_config)
367 .rcc_mask = RCC_APB2ENR_TIM8EN,
369 { .pin =
GPIO_PIN(PORT_I, 6), .cc_chan = 1},
377 .rcc_mask = RCC_APB1ENR1_TIM4EN,
387 .rcc_mask = RCC_APB1ENR1_TIM5EN,
397 #define PWM_NUMOF ARRAY_SIZE(pwm_config)
412 .rcc_mask = RCC_APB2ENR_SDMMC1EN,
420 #if MODULE_PERIPH_DMA
431 #define SDMMC_CONFIG_NUMOF 1
458 .rccmask = RCC_APB2ENR_SPI1EN,
460 #if MODULE_PERIPH_DMA
467 #if MODULE_PERIPH_SPI_STMOD
478 .rccmask = RCC_APB1ENR1_SPI2EN,
480 #if MODULE_PERIPH_DMA
490 #define SPI_NUMOF ARRAY_SIZE(spi_config)
501 .rcc_mask = RCC_APB1ENR1_TIM2EN,
508 .rcc_mask = RCC_APB1ENR1_TIM3EN,
514 #define TIMER_0_ISR isr_tim2
515 #define TIMER_1_ISR isr_tim3
517 #define TIMER_NUMOF ARRAY_SIZE(timer_config)
534 .rcc_mask = RCC_APB1ENR1_USART2EN,
541 #if MODULE_PERIPH_UART_HW_FC
547 #if MODULE_PERIPH_DMA
554 .rcc_mask = RCC_APB1ENR2_LPUART1EN,
560 .irqn = LPUART1_IRQn,
561 #if MODULE_PERIPH_UART_HW_FC
567 #if MODULE_PERIPH_DMA
573 #if !MODULE_PERIPH_SPI_STMOD
576 .rcc_mask = RCC_APB2ENR_USART1EN,
583 #if MODULE_PERIPH_UART_HW_FC
591 #if MODULE_PERIPH_DMA
599 #define UART_0_ISR (isr_usart2)
600 #define UART_1_ISR (isr_lpuart1)
601 #define UART_2_ISR (isr_usart1)
603 #define UART_NUMOF ARRAY_SIZE(uart_config)
#define GPIO_PIN(x, y)
Define a CPU specific GPIO pin generator macro.
#define GPIO_UNDEF
Definition of a fitting UNDEF value.
static const uart_conf_t uart_config[]
UART configuration.
static const spi_conf_t spi_config[]
SPI configuration.
static const i2c_conf_t i2c_config[]
I2C configuration.
static const timer_conf_t timer_config[]
All timers on board.
static const adc_conf_t adc_config[]
ADC configuration.
static const pwm_conf_t pwm_config[]
Actual PWM configuration.
static const dac_conf_t dac_config[]
DAC configuration.
static const sdmmc_conf_t sdmmc_config[]
SDIO/SDMMC static configuration struct.
static const lcd_fmc_desc_t lcd_fmc_desc[]
Descriptors of FMC banks used for LCDs.
static const fmc_bank_conf_t fmc_bank_config[]
FMC Bank configuration.
static const fmc_conf_t fmc_config
FMC controller configuration.
Common configuration for STM32 OTG FS peripheral.
@ GPIO_AF2
use alternate function 2
@ GPIO_AF5
use alternate function 5
@ GPIO_AF4
use alternate function 4
@ GPIO_AF8
use alternate function 8
@ GPIO_AF3
use alternate function 3
@ GPIO_AF12
use alternate function 12
@ GPIO_AF7
use alternate function 7
@ STM32_LPUART
STM32 Low-power UART (LPUART) module type.
@ STM32_USART
STM32 USART module type.
@ APB1
Advanced Peripheral Bus 1
@ APB2
Advanced Peripheral Bus 2
#define FMC_BANK_CONFIG(n)
Gives the configuration of n-th bank.
@ FMC_BUS_WIDTH_16BIT
16 bit data bus width
@ FMC_BANK_1
Bank 1 is always available and used for NOR, PSRAM, SRAM.
@ I2C_SPEED_NORMAL
normal mode: ~100 kbit/s
ADC device configuration.
gpio_t pin
pin connected to the channel
DAC line configuration data.
int stream
DMA stream on stm32f2/4/7, channel on others STM32F2/4/7:
Bank configuration structure.
FMC peripheral configuration.
I2C configuration structure.
TWI_t * dev
Pointer to hardware module registers.
Descriptor of the FMC bank used for a LCD.
const fmc_bank_conf_t * bank
FMC bank config used for the LCD.
PWM device configuration.
mini_timer_t * dev
Timer used.
SDMMC slot configuration.
SPI device configuration.
SPI_t * dev
pointer to the used SPI device
Timer device configuration.
TC0_t * dev
Pointer to the used as Timer device.
UART device configuration.
USART_t * dev
pointer to the used UART device
#define MiB(x)
A macro to return the bytes in x MiB.