Updated all rcc_clock_setups to use the new lookup tables.

The old "one function per config" system is depricated for quite a while
now...
This commit is contained in:
Piotr Esden-Tempski
2021-06-19 00:56:57 -07:00
parent 02f48ef616
commit e599e34073
73 changed files with 73 additions and 73 deletions

View File

@@ -37,7 +37,7 @@ int _write(int file, char *ptr, int len);
static void clock_setup(void)
{
rcc_clock_setup_in_hsi_out_24mhz();
rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSI_24MHZ]);
/* Enable clocks for USART2 and DAC*/
rcc_periph_clock_enable(RCC_USART2);
rcc_periph_clock_enable(RCC_DAC);

View File

@@ -24,7 +24,7 @@
/* Set STM32 to 24 MHz. */
static void clock_setup(void)
{
rcc_clock_setup_in_hse_8mhz_out_24mhz();
rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_24MHZ]);
}
static void gpio_setup(void)

View File

@@ -25,7 +25,7 @@
/* Set STM32 to 24 MHz. */
static void clock_setup(void)
{
rcc_clock_setup_in_hse_8mhz_out_24mhz();
rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_24MHZ]);
/* Enable GPIOC clock. */
rcc_periph_clock_enable(RCC_GPIOC);

View File

@@ -27,7 +27,7 @@
static void clock_setup(void)
{
rcc_clock_setup_in_hse_8mhz_out_24mhz();
rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_24MHZ]);
/* Enable GPIOC clock. */
rcc_periph_clock_enable(RCC_GPIOC);

View File

@@ -30,7 +30,7 @@ int _write(int file, char *ptr, int len);
static void clock_setup(void)
{
rcc_clock_setup_in_hse_8mhz_out_24mhz();
rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_24MHZ]);
/* Enable GPIOA, GPIOB, GPIOC clock. */
rcc_periph_clock_enable(RCC_GPIOA);

View File

@@ -23,7 +23,7 @@
static void clock_setup(void)
{
rcc_clock_setup_in_hse_8mhz_out_24mhz();
rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_24MHZ]);
/* Enable GPIOC clock. */
rcc_periph_clock_enable(RCC_GPIOC);