diff --git a/libopencm3 b/libopencm3 index 505ac65c..84352873 160000 --- a/libopencm3 +++ b/libopencm3 @@ -1 +1 @@ -Subproject commit 505ac65c05b776af031dac3c15b69573b5709850 +Subproject commit 8435287300e5ca9af9f889c529e7b1fa019c42fb diff --git a/src/platforms/f4discovery/platform.c b/src/platforms/f4discovery/platform.c index 53705138..2eb6bcbc 100644 --- a/src/platforms/f4discovery/platform.c +++ b/src/platforms/f4discovery/platform.c @@ -27,7 +27,7 @@ #include "usbuart.h" #include "morse.h" -#include +#include #include #include #include diff --git a/src/platforms/hydrabus/platform.c b/src/platforms/hydrabus/platform.c index 1b02976f..afac95a5 100644 --- a/src/platforms/hydrabus/platform.c +++ b/src/platforms/hydrabus/platform.c @@ -27,7 +27,7 @@ #include "usbuart.h" #include "morse.h" -#include +#include #include #include #include diff --git a/src/platforms/native/platform.c b/src/platforms/native/platform.c index e16632b6..2f6e87f4 100644 --- a/src/platforms/native/platform.c +++ b/src/platforms/native/platform.c @@ -27,14 +27,14 @@ #include "usbuart.h" #include "morse.h" -#include +#include #include #include #include #include #include #include -#include +#include static void adc_init(void); static void setup_vbus_irq(void); @@ -97,7 +97,7 @@ void platform_init(void) initialise_monitor_handles(); #endif - rcc_clock_setup_in_hse_8mhz_out_72mhz(); + rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_72MHZ]); /* Enable peripherals */ rcc_periph_clock_enable(RCC_USB); diff --git a/src/platforms/native/usbdfu.c b/src/platforms/native/usbdfu.c index db44002c..5a3a6892 100644 --- a/src/platforms/native/usbdfu.c +++ b/src/platforms/native/usbdfu.c @@ -44,7 +44,7 @@ int main(void) dfu_protect(false); - rcc_clock_setup_in_hse_8mhz_out_72mhz(); + rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_72MHZ]); systick_set_clocksource(STK_CSR_CLKSOURCE_AHB_DIV8); systick_set_reload(900000); diff --git a/src/platforms/stlink/platform.c b/src/platforms/stlink/platform.c index a38b0a7f..93b0a3b0 100644 --- a/src/platforms/stlink/platform.c +++ b/src/platforms/stlink/platform.c @@ -52,7 +52,7 @@ void platform_init(void) void initialise_monitor_handles(void); initialise_monitor_handles(); #endif - rcc_clock_setup_in_hse_8mhz_out_72mhz(); + rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_72MHZ]); if (rev == 0) { led_idle_run = GPIO8; srst_pin = SRST_PIN_V1; diff --git a/src/platforms/stlink/platform.h b/src/platforms/stlink/platform.h index 97c219d9..12c498d9 100644 --- a/src/platforms/stlink/platform.h +++ b/src/platforms/stlink/platform.h @@ -29,7 +29,7 @@ #include "timing_stm32.h" #include -#include +#include #include #ifdef ENABLE_DEBUG diff --git a/src/platforms/stlink/usbdfu.c b/src/platforms/stlink/usbdfu.c index 8b1cf7cf..12f83991 100644 --- a/src/platforms/stlink/usbdfu.c +++ b/src/platforms/stlink/usbdfu.c @@ -65,7 +65,7 @@ int main(void) dfu_jump_app_if_valid(); dfu_protect(false); - rcc_clock_setup_in_hse_8mhz_out_72mhz(); + rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_72MHZ]); systick_set_clocksource(STK_CSR_CLKSOURCE_AHB_DIV8); systick_set_reload(900000); diff --git a/src/platforms/swlink/platform.c b/src/platforms/swlink/platform.c index a11ea55b..24b6140c 100644 --- a/src/platforms/swlink/platform.c +++ b/src/platforms/swlink/platform.c @@ -27,13 +27,13 @@ #include "cdcacm.h" #include "usbuart.h" -#include +#include #include #include #include #include #include -#include +#include uint32_t led_error_port; uint16_t led_error_pin; @@ -54,8 +54,7 @@ void platform_init(void) void initialise_monitor_handles(void); initialise_monitor_handles(); #endif - rcc_clock_setup_in_hse_8mhz_out_72mhz(); - + rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_72MHZ]); rev = detect_rev(); /* Enable peripherals */ rcc_periph_clock_enable(RCC_AFIO); diff --git a/src/platforms/swlink/usbdfu.c b/src/platforms/swlink/usbdfu.c index c6a2b282..1d763804 100644 --- a/src/platforms/swlink/usbdfu.c +++ b/src/platforms/swlink/usbdfu.c @@ -77,7 +77,7 @@ int main(void) dfu_protect(false); - rcc_clock_setup_in_hse_8mhz_out_72mhz(); + rcc_clock_setup_pll(&rcc_hse_configs[RCC_CLOCK_HSE8_72MHZ]); systick_set_clocksource(STK_CSR_CLKSOURCE_AHB_DIV8); systick_set_reload(900000);