Skip to content

Commit 11a4e77

Browse files
authored
Update HALConfig.cpp
Forgot disable method for Dual Mode
1 parent d01db9f commit 11a4e77

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/HALConfig.cpp

+6
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,12 @@ int hal_enable_dual_mode()
172172
return(1);
173173
}
174174

175+
int hal_disable_dual_mode()
176+
{
177+
LL_ADC_SetMultimode(__LL_ADC_COMMON_INSTANCE(ADC1), LL_ADC_MULTI_INDEPENDENT);
178+
return(1);
179+
}
180+
175181
int hal_adc_config(ADC_HandleTypeDef *adc, uint32_t resolution, uint32_t trigger, PinName *adc_pins, uint32_t n_channels) {
176182
// Set ADC clock source.
177183
__HAL_RCC_ADC_CONFIG(RCC_ADCCLKSOURCE_CLKP);

0 commit comments

Comments
 (0)