diff --git a/Source/ADC.cpp b/Source/ADC.cpp index 80158eb..8165e52 100644 --- a/Source/ADC.cpp +++ b/Source/ADC.cpp @@ -172,10 +172,12 @@ namespace ElektronischeLast /** Configure Regular Channel */ LL_ADC_REG_SetSequencerRanks(ADC1, LL_ADC_REG_RANK_2, LL_ADC_CHANNEL_1); + LL_ADC_SetChannelSamplingTime(ADC1, LL_ADC_CHANNEL_1, LL_ADC_SAMPLINGTIME_COMMON_1); /** Configure Regular Channel */ LL_ADC_REG_SetSequencerRanks(ADC1, LL_ADC_REG_RANK_3, LL_ADC_CHANNEL_6); + LL_ADC_SetChannelSamplingTime(ADC1, LL_ADC_CHANNEL_2, LL_ADC_SAMPLINGTIME_COMMON_1); /* Poll for ADC channel configuration ready */ while (LL_ADC_IsActiveFlag_CCRDY(ADC1) == 0) @@ -183,7 +185,6 @@ namespace ElektronischeLast } /* Clear flag ADC channel configuration ready */ LL_ADC_ClearFlag_CCRDY(ADC1); - LL_ADC_SetChannelSamplingTime(ADC1, LL_ADC_CHANNEL_1, LL_ADC_SAMPLINGTIME_COMMON_1); LL_TIM_InitTypeDef TIM_InitStruct = {