summaryrefslogtreecommitdiff
path: root/nuttx/arch/arm/src/stm32/stm32_adc.h
diff options
context:
space:
mode:
Diffstat (limited to 'nuttx/arch/arm/src/stm32/stm32_adc.h')
-rw-r--r--nuttx/arch/arm/src/stm32/stm32_adc.h38
1 files changed, 38 insertions, 0 deletions
diff --git a/nuttx/arch/arm/src/stm32/stm32_adc.h b/nuttx/arch/arm/src/stm32/stm32_adc.h
index 6089217fe..508813bd1 100644
--- a/nuttx/arch/arm/src/stm32/stm32_adc.h
+++ b/nuttx/arch/arm/src/stm32/stm32_adc.h
@@ -47,5 +47,43 @@
#include <nuttx/analog/adc.h>
+/************************************************************************************
+ * Public Function Prototypes
+ ************************************************************************************/
+
+#ifndef __ASSEMBLY__
+#ifdef __cplusplus
+#define EXTERN extern "C"
+extern "C" {
+#else
+#define EXTERN extern
+#endif
+
+/****************************************************************************
+ * Name: stm32_adcinitialize
+ *
+ * Description:
+ * Initialize the ADC.
+ *
+ * Input Parameters:
+ * intf - Could be {1,2,3} for ADC1, ADC2, or ADC3
+ * chanlist - The list of channels
+ * nchannels - Number of channels
+ *
+ * Returned Value:
+ * Valid can device structure reference on succcess; a NULL on failure
+ *
+ ****************************************************************************/
+
+struct adc_dev_s;
+EXTERN struct adc_dev_s *stm32_adcinitialize(int intf, uint8_t *chanlist,
+ int nchannels);
+
+#undef EXTERN
+#ifdef __cplusplus
+}
+#endif
+#endif /* __ASSEMBLY__ */
+
#endif /* __ARCH_ARM_SRC_STM32_STM32_ADC_H */