42 int numChannels = 1,
i, rank = 1;
#define DMA_MemoryInc_Enable
uint32_t ADC_ExternalTrigConv
uint16_t adcGetChannel(uint8_t channel)
void ADC_ResetCalibration(ADC_TypeDef *ADCx)
Resets the selected ADC calibration registers.
DMA Init structure definition.
ADC Init structure definition.
#define ADC_Mode_Independent
void ADC_Cmd(ADC_TypeDef *ADCx, FunctionalState NewState)
Enables or disables the specified ADC peripheral.
FunctionalState ADC_ContinuousConvMode
void DMA_DeInit(DMA_Stream_TypeDef *DMAy_Streamx)
Deinitialize the DMAy Streamx registers to their default reset values.
#define DMA_PeripheralInc_Disable
FlagStatus ADC_GetCalibrationStatus(ADC_TypeDef *ADCx)
Gets the selected ADC calibration status.
static volatile uint16_t adcValues[ADC_CHANNEL_MAX]
uint32_t DMA_MemoryDataSize
void ADC_DMACmd(ADC_TypeDef *ADCx, FunctionalState NewState)
Enables or disables the specified ADC DMA request.
#define DMA_Priority_High
void DMA_Init(DMA_Stream_TypeDef *DMAy_Streamx, DMA_InitTypeDef *DMA_InitStruct)
Initializes the DMAy Streamx according to the specified parameters in the DMA_InitStruct structure...
#define DMA_PeripheralDataSize_HalfWord
uint32_t DMA_PeripheralInc
uint32_t DMA_PeripheralDataSize
void adcInit(bool haveADC5)
uint32_t DMA_MemoryBaseAddr
#define DMA_MemoryDataSize_HalfWord
void DMA_Cmd(DMA_Stream_TypeDef *DMAy_Streamx, FunctionalState NewState)
Enables or disables the specified DMAy Streamx.
uint32_t DMA_PeripheralBaseAddr
FlagStatus ADC_GetResetCalibrationStatus(ADC_TypeDef *ADCx)
Gets the selected ADC reset calibration registers status.
#define DMA_DIR_PeripheralSRC
void ADC_SoftwareStartConvCmd(ADC_TypeDef *ADCx, FunctionalState NewState)
Enables or disables the selected ADC software start conversion .
FunctionalState ADC_ScanConvMode
#define DMA_MemoryInc_Disable
void ADC_StartCalibration(ADC_TypeDef *ADCx)
Starts the selected ADC calibration process.
#define ADC_ExternalTrigConv_None
#define ADC_SampleTime_239Cycles5
static adc_config_t adcConfig[ADC_CHANNEL_MAX]
void ADC_RegularChannelConfig(ADC_TypeDef *ADCx, uint8_t ADC_Channel, uint8_t Rank, uint8_t ADC_SampleTime)
Configures for the selected ADC regular channel its corresponding rank in the sequencer and its sampl...
#define DMA_Mode_Circular
#define ADC_DataAlign_Right
struct adc_config_t adc_config_t
void ADC_Init(ADC_TypeDef *ADCx, ADC_InitTypeDef *ADC_InitStruct)
Initializes the ADCx peripheral according to the specified parameters in the ADC_InitStruct.