aboutsummaryrefslogtreecommitdiff
path: root/ports/stm32/adc.c
diff options
context:
space:
mode:
Diffstat (limited to 'ports/stm32/adc.c')
-rw-r--r--ports/stm32/adc.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ports/stm32/adc.c b/ports/stm32/adc.c
index b8b4f4e56..ffa16c2f9 100644
--- a/ports/stm32/adc.c
+++ b/ports/stm32/adc.c
@@ -35,6 +35,8 @@
#include "genhdr/pins.h"
#include "timer.h"
+#if MICROPY_HW_ENABLE_ADC
+
/// \moduleref pyb
/// \class ADC - analog to digital conversion: read analog values on a pin
///
@@ -683,3 +685,5 @@ const mp_obj_type_t pyb_adc_all_type = {
.make_new = adc_all_make_new,
.locals_dict = (mp_obj_dict_t*)&adc_all_locals_dict,
};
+
+#endif // MICROPY_HW_ENABLE_ADC