Avalon Firmware
 
Loading...
Searching...
No Matches
adc.c File Reference

This file provides code for the configuration of the ADC instances. More...

#include "adc.h"

Functions

void MX_ADC1_Init (void)
 
void MX_ADC2_Init (void)
 
void MX_ADC3_Init (void)
 
void HAL_ADC_MspInit (ADC_HandleTypeDef *adcHandle)
 
void HAL_ADC_MspDeInit (ADC_HandleTypeDef *adcHandle)
 

Variables

ADC_HandleTypeDef hadc1
 
ADC_HandleTypeDef hadc2
 
ADC_HandleTypeDef hadc3
 
DMA_HandleTypeDef hdma_adc1
 
DMA_HandleTypeDef hdma_adc2
 
static uint32_t HAL_RCC_ADC12_CLK_ENABLED =0
 

Detailed Description

This file provides code for the configuration of the ADC instances.

Attention

Copyright (c) 2024 STMicroelectronics. All rights reserved.

This software is licensed under terms that can be found in the LICENSE file in the root directory of this software component. If no LICENSE file comes with this software, it is provided AS-IS.

Function Documentation

◆ HAL_ADC_MspDeInit()

void HAL_ADC_MspDeInit ( ADC_HandleTypeDef * adcHandle)

ADC1 GPIO Configuration PA0 ------> ADC1_IN1 PA1 ------> ADC1_IN2

Uncomment the line below to disable the "ADC1_2_IRQn" interrupt Be aware, disabling shared interrupt may affect other IPs

ADC2 GPIO Configuration PC1 ------> ADC2_IN7 PC2 ------> ADC2_IN8 PC3 ------> ADC2_IN9

Uncomment the line below to disable the "ADC1_2_IRQn" interrupt Be aware, disabling shared interrupt may affect other IPs

ADC3 GPIO Configuration PB1 ------> ADC3_IN1

◆ HAL_ADC_MspInit()

void HAL_ADC_MspInit ( ADC_HandleTypeDef * adcHandle)

Initializes the peripherals clocks

ADC1 GPIO Configuration PA0 ------> ADC1_IN1 PA1 ------> ADC1_IN2

Initializes the peripherals clocks

ADC2 GPIO Configuration PC1 ------> ADC2_IN7 PC2 ------> ADC2_IN8 PC3 ------> ADC2_IN9

Initializes the peripherals clocks

ADC3 GPIO Configuration PB1 ------> ADC3_IN1

◆ MX_ADC1_Init()

void MX_ADC1_Init ( void )

Common config

Configure the ADC multi-mode

Configure Regular Channel

Configure Regular Channel

◆ MX_ADC2_Init()

void MX_ADC2_Init ( void )

Common config

Configure Regular Channel

Configure Regular Channel

Configure Regular Channel

◆ MX_ADC3_Init()

void MX_ADC3_Init ( void )

Common config

Configure the ADC multi-mode

Configure Regular Channel

Variable Documentation

◆ hadc1

ADC_HandleTypeDef hadc1

◆ hadc2

ADC_HandleTypeDef hadc2

◆ hadc3

ADC_HandleTypeDef hadc3

◆ HAL_RCC_ADC12_CLK_ENABLED

uint32_t HAL_RCC_ADC12_CLK_ENABLED =0
static

◆ hdma_adc1

DMA_HandleTypeDef hdma_adc1

◆ hdma_adc2

DMA_HandleTypeDef hdma_adc2