GD32 changed calculation for delay() loop to use F_CPU
This commit is contained in:
parent
7bea296b11
commit
d79f346747
|
@ -227,27 +227,8 @@ extern "C" {
|
|||
# define STM32_PCLK2 F_CPU
|
||||
# endif
|
||||
# ifndef STM32_DELAY_US_MULT
|
||||
#if F_CPU == 120000000
|
||||
#define STM32_DELAY_US_MULT 40 /* FIXME: value is incorrect. */
|
||||
#elif F_CPU == 96000000
|
||||
#define STM32_DELAY_US_MULT 32 /* FIXME: value is incorrect. */
|
||||
#elif F_CPU == 72000000
|
||||
#define STM32_DELAY_US_MULT 24 /* FIXME: value is incorrect. */
|
||||
#endif
|
||||
# define STM32_DELAY_US_MULT (F_CPU / 3000000L)
|
||||
# endif
|
||||
#elif STM32_F1_LINE == STM32_F1_LINE_VALUE /* TODO */
|
||||
# ifndef STM32_PCLK1
|
||||
# define STM32_PCLK1 12000000U
|
||||
# endif
|
||||
# ifndef STM32_PCLK2
|
||||
# define STM32_PCLK2 24000000U
|
||||
# endif
|
||||
# ifndef STM32_DELAY_US_MULT
|
||||
# define STM32_DELAY_US_MULT 8 /* FIXME: value is incorrect. */
|
||||
# endif
|
||||
#elif STM32_F1_LINE == STM32_F1_LINE_ACCESS /* TODO */
|
||||
#elif STM32_F1_LINE == STM32_F1_LINE_USB_ACCESS /* TODO */
|
||||
#elif STM32_F1_LINE == STM32_F1_LINE_CONNECTIVITY /* TODO */
|
||||
#endif
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue