File tree Expand file tree Collapse file tree 5 files changed +8
-5
lines changed
Expand file tree Collapse file tree 5 files changed +8
-5
lines changed Original file line number Diff line number Diff line change 2323#ifndef PLATFORMS_BLACKPILL_F401CC_PLATFORM_H
2424#define PLATFORMS_BLACKPILL_F401CC_PLATFORM_H
2525
26- #define PLATFORM_IDENT "(BlackPill-F401CC) "
26+ #define PLATFORM_IDENT "(BlackPill-F401CC) "
27+ #define PLATFORM_CLOCK_FREQ RCC_CLOCK_3V3_84MHZ
2728
2829#include "blackpill-f4.h"
2930
Original file line number Diff line number Diff line change 2323#ifndef PLATFORMS_BLACKPILL_F401CE_PLATFORM_H
2424#define PLATFORMS_BLACKPILL_F401CE_PLATFORM_H
2525
26- #define PLATFORM_IDENT "(BlackPill-F401CE) "
26+ #define PLATFORM_IDENT "(BlackPill-F401CE) "
27+ #define PLATFORM_CLOCK_FREQ RCC_CLOCK_3V3_84MHZ
2728
2829#include "blackpill-f4.h"
2930
Original file line number Diff line number Diff line change 2323#ifndef PLATFORMS_BLACKPILL_F411CE_PLATFORM_H
2424#define PLATFORMS_BLACKPILL_F411CE_PLATFORM_H
2525
26- #define PLATFORM_IDENT "(BlackPill-F411CE) "
26+ #define PLATFORM_IDENT "(BlackPill-F411CE) "
27+ #define PLATFORM_CLOCK_FREQ RCC_CLOCK_3V3_96MHZ
2728
2829#include "blackpill-f4.h"
2930
Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ void platform_init(void)
6868 scb_reset_core ();
6969 }
7070#endif
71- rcc_clock_setup_pll (& rcc_hse_25mhz_3v3 [RCC_CLOCK_3V3_84MHZ ]);
71+ rcc_clock_setup_pll (& rcc_hse_25mhz_3v3 [PLATFORM_CLOCK_FREQ ]);
7272
7373 /* Enable peripherals */
7474 rcc_periph_clock_enable (RCC_OTGFS );
Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ int main(void)
5050 dfu_jump_app_if_valid ();
5151 }
5252
53- rcc_clock_setup_pll (& rcc_hse_25mhz_3v3 [RCC_CLOCK_3V3_84MHZ ]);
53+ rcc_clock_setup_pll (& rcc_hse_25mhz_3v3 [PLATFORM_CLOCK_FREQ ]);
5454
5555 /* Assert blue LED as indicator we are in the bootloader */
5656 rcc_periph_clock_enable (RCC_GPIOC );
You can’t perform that action at this time.
0 commit comments