diff --git a/libraries/AP_HAL_ChibiOS/hwdef/common/stm32f47_mcuconf.h b/libraries/AP_HAL_ChibiOS/hwdef/common/stm32f47_mcuconf.h index 41cab6f73f..015b3856a4 100644 --- a/libraries/AP_HAL_ChibiOS/hwdef/common/stm32f47_mcuconf.h +++ b/libraries/AP_HAL_ChibiOS/hwdef/common/stm32f47_mcuconf.h @@ -94,9 +94,15 @@ #define STM32_PLLQ_VALUE 7 #endif +#ifndef STM32_HPRE #define STM32_HPRE STM32_HPRE_DIV1 +#endif +#ifndef STM32_PPRE1 #define STM32_PPRE1 STM32_PPRE1_DIV4 +#endif +#ifndef STM32_PPRE2 #define STM32_PPRE2 STM32_PPRE2_DIV2 +#endif #define STM32_RTCSEL STM32_RTCSEL_LSI #define STM32_RTCPRE_VALUE 8 #define STM32_MCO1SEL STM32_MCO1SEL_HSI @@ -114,9 +120,15 @@ * ADC driver system settings. */ #define STM32_ADC_ADCPRE ADC_CCR_ADCPRE_DIV4 +#ifndef STM32_ADC_USE_ADC1 #define STM32_ADC_USE_ADC1 TRUE +#endif +#ifndef STM32_ADC_USE_ADC2 #define STM32_ADC_USE_ADC2 FALSE +#endif +#ifndef STM32_ADC_USE_ADC3 #define STM32_ADC_USE_ADC3 FALSE +#endif #define STM32_ADC_ADC1_DMA_PRIORITY 2 #define STM32_ADC_ADC2_DMA_PRIORITY 2 #define STM32_ADC_ADC3_DMA_PRIORITY 2