We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a5ad4e8 commit 29d0660Copy full SHA for 29d0660
drivers/adc/adc_stm32.c
@@ -40,6 +40,9 @@ LOG_MODULE_REGISTER(adc_stm32);
40
#endif
41
42
43
+/* reference voltage for the ADC */
44
+#define STM32_ADC_VREF_MV DT_INST_PROP(0, vref_mv)
45
+
46
#if !defined(CONFIG_SOC_SERIES_STM32F0X) && \
47
!defined(CONFIG_SOC_SERIES_STM32G0X) && \
48
!defined(CONFIG_SOC_SERIES_STM32L0X) && \
@@ -1079,6 +1082,7 @@ static const struct adc_driver_api api_stm32_driver_api = {
1079
1082
#ifdef CONFIG_ADC_ASYNC
1080
1083
.read_async = adc_stm32_read_async,
1081
1084
1085
+ .ref_internal = STM32_ADC_VREF_MV, /* VREF is usually connected to VDD */
1086
};
1087
1088
#ifdef CONFIG_ADC_STM32_SHARED_IRQS
0 commit comments