libopencm3
A free/libre/open-source firmware library for various ARM Cortex-M3 microcontrollers.
rcc.c File Reference
Include dependency graph for rcc.c:

Go to the source code of this file.

Functions

void rcc_osc_ready_int_clear (enum rcc_osc osc)
 RCC Clear the Oscillator Ready Interrupt Flag. More...
 
void rcc_osc_ready_int_enable (enum rcc_osc osc)
 RCC Enable the Oscillator Ready Interrupt. More...
 
void rcc_osc_ready_int_disable (enum rcc_osc osc)
 RCC Disable the Oscillator Ready Interrupt. More...
 
int rcc_osc_ready_int_flag (enum rcc_osc osc)
 RCC Read the Oscillator Ready Interrupt Flag. More...
 
void rcc_css_int_clear (void)
 RCC Clear the Clock Security System Interrupt Flag. More...
 
int rcc_css_int_flag (void)
 RCC Read the Clock Security System Interrupt Flag. More...
 
void rcc_wait_for_osc_ready (enum rcc_osc osc)
 RCC Wait for Oscillator Ready. More...
 
void rcc_osc_on (enum rcc_osc osc)
 RCC Turn on an Oscillator. More...
 
void rcc_osc_off (enum rcc_osc osc)
 RCC Turn off an Oscillator. More...
 
void rcc_css_enable (void)
 RCC Enable the Clock Security System. More...
 
void rcc_css_disable (void)
 RCC Disable the Clock Security System. More...
 
void rcc_set_sysclk_source (uint32_t clk)
 RCC Set the Source for the System Clock. More...
 
void rcc_set_pll_multiplication_factor (uint32_t mul)
 RCC Set the PLL Multiplication Factor. More...
 
void rcc_set_pll_source (uint32_t pllsrc)
 RCC Set the PLL Clock Source. More...
 
void rcc_set_pllxtpre (uint32_t pllxtpre)
 RCC Set the HSE Frequency Divider used as PLL Clock Source. More...
 
uint32_t rcc_rtc_clock_enabled_flag (void)
 RCC RTC Clock Enabled Flag. More...
 
void rcc_enable_rtc_clock (void)
 RCC Enable the RTC clock. More...
 
void rcc_set_rtc_clock_source (enum rcc_osc clock_source)
 RCC Set the Source for the RTC clock. More...
 
void rcc_set_adcpre (uint32_t adcpre)
 ADC Setup the A/D Clock. More...
 
void rcc_set_ppre2 (uint32_t ppre2)
 RCC Set the APB2 Prescale Factor. More...
 
void rcc_set_ppre1 (uint32_t ppre1)
 RCC Set the APB1 Prescale Factor. More...
 
void rcc_set_hpre (uint32_t hpre)
 RCC Set the AHB Prescale Factor. More...
 
void rcc_set_usbpre (uint32_t usbpre)
 RCC Set the USB Prescale Factor. More...
 
void rcc_set_prediv (uint32_t prediv)
 
uint32_t rcc_system_clock_source (void)
 RCC Get the System Clock Source. More...
 
void rcc_clock_setup_pll (const struct rcc_clock_scale *clock)
 Setup clocks to run from PLL. More...
 
void rcc_backupdomain_reset (void)
 RCC Reset the Backup Domain. More...
 

Variables

uint32_t rcc_apb1_frequency = 8000000
 Set the default clock frequencies. More...
 
uint32_t rcc_apb2_frequency = 8000000
 
uint32_t rcc_ahb_frequency = 8000000
 
const struct rcc_clock_scale rcc_hsi_configs []
 
const struct rcc_clock_scale rcc_hse8_configs []