boards/nucleo-f446re: fix adc example
fix adc example for nucleo-f446re: - the second ADC channel should be different from first channel - enable ADC SCAN mode so we get convertion on CH0 and CH1 - disable software trigger from application, we use hardware triggering from timer Signed-off-by: raiden00pl <raiden00@railab.me>
This commit is contained in:
parent
2912b3347c
commit
b37e8ecf3c
2 changed files with 2 additions and 3 deletions
|
|
@ -10,7 +10,6 @@
|
|||
# CONFIG_NSH_CMDOPT_HEXDUMP is not set
|
||||
# CONFIG_NSH_DISABLE_IFCONFIG is not set
|
||||
# CONFIG_NSH_DISABLE_PS is not set
|
||||
# CONFIG_STM32_ADC1_SCAN is not set
|
||||
# CONFIG_STM32_FLASH_PREFETCH is not set
|
||||
CONFIG_ADC=y
|
||||
CONFIG_ANALOG=y
|
||||
|
|
@ -27,7 +26,6 @@ CONFIG_BOARD_LOOPSPERMSEC=8499
|
|||
CONFIG_BUILTIN=y
|
||||
CONFIG_EXAMPLES_ADC=y
|
||||
CONFIG_EXAMPLES_ADC_GROUPSIZE=2
|
||||
CONFIG_EXAMPLES_ADC_SWTRIG=y
|
||||
CONFIG_HAVE_CXX=y
|
||||
CONFIG_HAVE_CXXINITIALIZE=y
|
||||
CONFIG_INIT_ENTRYPOINT="nsh_main"
|
||||
|
|
@ -48,6 +46,7 @@ CONFIG_START_MONTH=10
|
|||
CONFIG_START_YEAR=2014
|
||||
CONFIG_STM32_ADC1=y
|
||||
CONFIG_STM32_ADC1_DMA=y
|
||||
CONFIG_STM32_ADC1_SAMPLE_FREQUENCY=1
|
||||
CONFIG_STM32_DMA2=y
|
||||
CONFIG_STM32_JTAG_SW_ENABLE=y
|
||||
CONFIG_STM32_TIM1=y
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@ static const uint8_t g_adc1_chanlist[ADC1_NCHANNELS] =
|
|||
static const uint32_t g_adc1_pinlist[ADC1_NCHANNELS] =
|
||||
{
|
||||
GPIO_ADC1_IN0,
|
||||
GPIO_ADC1_IN0
|
||||
GPIO_ADC1_IN1
|
||||
};
|
||||
|
||||
#else
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue