diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2015-03-31 15:00:23 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2015-03-31 15:00:23 -0600 |
commit | 494dfe2ae6157348956b941eb7a1f57b66181a56 (patch) | |
tree | 7201b16b309f34b73f46936ed1980c0ef0b8154a /nuttx/configs/stm3220g-eval | |
parent | 49a7570f92a3ae31838f2eea2fa71354361f2881 (diff) | |
download | px4-nuttx-494dfe2ae6157348956b941eb7a1f57b66181a56.tar.gz px4-nuttx-494dfe2ae6157348956b941eb7a1f57b66181a56.tar.bz2 px4-nuttx-494dfe2ae6157348956b941eb7a1f57b66181a56.zip |
Rename adc_devinit() to board_adc_setup(). Add support to the boardctl() interface so that it can call board_adc_setup() on behalf of an application. Change apps/examples/adc to that is now calls boardctl() instead of adc_devinit() in order to initalize the ADC device.
Diffstat (limited to 'nuttx/configs/stm3220g-eval')
-rw-r--r-- | nuttx/configs/stm3220g-eval/src/stm32_adc.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/nuttx/configs/stm3220g-eval/src/stm32_adc.c b/nuttx/configs/stm3220g-eval/src/stm32_adc.c index 6347f1cfe..94f3c2d42 100644 --- a/nuttx/configs/stm3220g-eval/src/stm32_adc.c +++ b/nuttx/configs/stm3220g-eval/src/stm32_adc.c @@ -42,6 +42,7 @@ #include <errno.h> #include <debug.h> +#include <nuttx/board.h> #include <nuttx/analog/adc.h> #include <arch/board/board.h> @@ -107,7 +108,7 @@ static const uint32_t g_pinlist[ADC3_NCHANNELS] = {GPIO_ADC3_IN7}; ************************************************************************************/ /************************************************************************************ - * Name: adc_devinit + * Name: board_adc_setup * * Description: * All STM32 architectures must provide the following interface to work with @@ -115,7 +116,7 @@ static const uint32_t g_pinlist[ADC3_NCHANNELS] = {GPIO_ADC3_IN7}; * ************************************************************************************/ -int adc_devinit(void) +int board_adc_setup(void) { #ifdef CONFIG_STM32_ADC3 static bool initialized = false; |