periph_conf.h File Reference

Peripheral MCU configuration for the STM32L476G-DISCO board. More...

Detailed Description

Peripheral MCU configuration for the STM32L476G-DISCO board.

Author
Alexandre Abadie alexa.nosp@m.ndre.nosp@m..abad.nosp@m.ie@i.nosp@m.nria..nosp@m.fr

Definition in file periph_conf.h.

#include "periph_cpu.h"
#include "cfg_rtt_default.h"
+ Include dependency graph for periph_conf.h:

Go to the source code of this file.

Clock system configuration

#define CLOCK_HSE   (0)
 
#define CLOCK_LSE   (1)
 
#define CLOCK_MSI_ENABLE   (1)
 
#define CLOCK_MSI_LSE_PLL   (1)
 
#define CLOCK_CORECLOCK   (80000000U)
 
#define CLOCK_PLL_M   (6)
 
#define CLOCK_PLL_N   (20)
 
#define CLOCK_PLL_R   (2)
 
#define CLOCK_AHB_DIV   RCC_CFGR_HPRE_DIV1
 
#define CLOCK_AHB   (CLOCK_CORECLOCK / 1)
 
#define CLOCK_APB1_DIV   RCC_CFGR_PPRE1_DIV4
 
#define CLOCK_APB1   (CLOCK_CORECLOCK / 4)
 
#define CLOCK_APB2_DIV   RCC_CFGR_PPRE2_DIV2
 
#define CLOCK_APB2   (CLOCK_CORECLOCK / 2)
 

Timer configuration

#define TIMER_0_ISR   isr_tim5
 
#define TIMER_NUMOF   (sizeof(timer_config) / sizeof(timer_config[0]))
 
static const timer_conf_t timer_config []
 

UART configuration

#define UART_0_ISR   (isr_usart2)
 
#define UART_NUMOF   (sizeof(uart_config) / sizeof(uart_config[0]))
 
static const uart_conf_t uart_config []
 

RTC configuration

#define RTC_NUMOF   (1)
 

Variable Documentation

◆ timer_config

const timer_conf_t timer_config[]
static
Initial value:
= {
{
.dev = TIM5,
.max = 0xffffffff,
.rcc_mask = RCC_APB1ENR1_TIM5EN,
.bus = APB1,
.irqn = TIM5_IRQn
}
}
APB1 bus.

Definition at line 77 of file periph_conf.h.

◆ uart_config

const uart_conf_t uart_config[]
static
Initial value:
= {
{
.dev = USART2,
.rcc_mask = RCC_APB1ENR1_USART2EN,
.rx_pin = GPIO_PIN(PORT_D, 6),
.tx_pin = GPIO_PIN(PORT_D, 5),
.rx_af = GPIO_AF7,
.tx_af = GPIO_AF7,
.bus = APB1,
.irqn = USART2_IRQn,
.type = STM32_USART,
.clk_src = 0,
}
}
use alternate function 7
APB1 bus.
STM32 USART module type.
port D
Definition: periph_cpu.h:39
#define GPIO_PIN(x, y)
Define a CPU specific GPIO pin generator macro.
Definition: periph_cpu.h:35

Definition at line 96 of file periph_conf.h.