Example #1
0
void stm32_clockconfig(void)
{
  /* Make sure that we are starting in the reset state */

  rcc_reset();
  
#if defined(CONFIG_ARCH_BOARD_STM32_CUSTOM_CLOCKCONFIG)

  /* Invoke Board Custom Clock Configuration */

  stm32_board_clockconfig();
  
#else

  /* Invoke standard, fixed clock configuration based on definitions in board.h */

  stm32_stdclockconfig();

#endif

  /* Enable peripheral clocking */
  
  rcc_enableahb();
  rcc_enableapb2();
  rcc_enableapb1();
}
Example #2
0
static inline void rcc_enableperipherals(void)
{
  rcc_enableahb1();
  rcc_enableahb2();
  rcc_enableahb3();
  rcc_enableapb1();
  rcc_enableapb2();
}
Example #3
0
static inline void rcc_enableperipherals(void)
{
  rcc_enableahb();
  rcc_enableapb2();
  rcc_enableapb1();

#if defined(CONFIG_RTC_LSECLOCK)
  /* Low speed external clock source LSE
   * For F1 it requires PWR and BKP from APB1
   */

  stm32_rcc_enablelse();
#endif
}