87 ADC_Type *
const base = s_adcBase[instance];
112 const ADC_Type *
const base = s_adcBase[instance];
135 ADC_Type *
const base = s_adcBase[instance];
175 ADC_Type *
const base = s_adcBase[instance];
197 const ADC_Type *
const base = s_adcBase[instance];
238 ADC_Type *
const base = s_adcBase[instance];
257 const ADC_Type *
const base = s_adcBase[instance];
290 const uint8_t chanIndex,
297 ADC_Type *
const base = s_adcBase[instance];
311 const uint8_t chanIndex,
318 const ADC_Type *
const base = s_adcBase[instance];
335 const ADC_Type *
const base = s_adcBase[instance];
351 const uint8_t chanIndex,
352 uint16_t *
const result)
358 const ADC_Type *
const base = s_adcBase[instance];
374 ADC_Type *
const base = s_adcBase[instance];
437 ADC_Type *
const base = s_adcBase[instance];
456 const ADC_Type *
const base = s_adcBase[instance];
491 ADC_Type *
const base = s_adcBase[instance];
514 ADC_Type *
const base = s_adcBase[instance];
529 const ADC_Type *
const base = s_adcBase[instance];
#define ADC_INPUTCHAN_DISABLED
static ADC_Type *const s_adcBase[ADC_INSTANCE_COUNT]
static void ADC_HAL_SetContinuousConvFlag(ADC_Type *const baseAddr, const bool state)
Sets the Continuous Conversion Flag state.
static bool ADC_HAL_GetHwAverageEnableFlag(const ADC_Type *const baseAddr)
Gets the Hardware Average Enable Flag state.
Defines the user calibration configuration.
static uint16_t ADC_HAL_GetChanResult(const ADC_Type *const baseAddr, const uint8_t chanIndex)
Gets the conversion result for the selected measurement channel.
static void ADC_HAL_SetChanInterruptEnableFlag(ADC_Type *const baseAddr, const uint8_t chanIndex, const bool state)
Sets the Channel Interrupt Enable to a new state.
bool continuousConvEnable
uint32_t ADC_DRV_GetTriggerErrorFlags(const uint32_t instance)
This function returns the trigger error flags bits of the ADC instance.
void ADC_DRV_AutoCalibration(const uint32_t instance)
Executes an Auto-Calibration.
static void ADC_HAL_SetSampleTime(ADC_Type *const baseAddr, uint8_t sampletime)
Sets the Sample time in AD clock cycles.
static bool ADC_HAL_GetHwCompareGtEnableFlag(const ADC_Type *const baseAddr)
Gets the Hardware Compare Greater Than Enable Flag state.
adc_voltage_reference_t voltageRef
void ADC_DRV_GetHwAverageConfig(const uint32_t instance, adc_average_config_t *const config)
Gets the current Hardware Average configuration.
static void ADC_HAL_SetUserOffsetValue(ADC_Type *const baseAddr, const uint16_t value)
Sets the User Offset Register value.
void ADC_DRV_InitHwCompareStruct(adc_compare_config_t *const config)
Initializes the Hardware Compare configuration structure.
void ADC_DRV_InitHwAverageStruct(adc_average_config_t *const config)
Initializes the Hardware Average configuration structure.
static adc_trigger_t ADC_HAL_GetTriggerMode(const ADC_Type *const baseAddr)
Gets the ADC Trigger Mode.
static bool ADC_HAL_GetConvActiveFlag(const ADC_Type *const baseAddr)
Gets the Conversion Active Flag.
void ADC_DRV_ConfigConverter(const uint32_t instance, const adc_converter_config_t *const config)
Configures the converter with the given configuration structure.
static uint16_t ADC_HAL_GetHwCompareComp2Value(const ADC_Type *const baseAddr)
Gets the Compare Register 2 value.
static void ADC_HAL_SetInputClock(ADC_Type *const baseAddr, const adc_input_clock_t inputClock)
Sets the AD Clock Input configuration.
static void ADC_HAL_SetCalibrationActiveFlag(ADC_Type *const baseAddr, const bool state)
Sets the Calibration Active Flag state.
adc_input_clock_t inputClock
void ADC_DRV_ConfigUserCalibration(const uint32_t instance, const adc_calibration_t *const config)
Configures the User Calibration feature with the given configuration structure.
static void ADC_HAL_SetClockDivide(ADC_Type *const baseAddr, const adc_clk_divide_t clockDivide)
Sets the ADC clock divider configuration.
IRQn_Type
Defines the Interrupt Numbers definitions.
void ADC_DRV_Reset(const uint32_t instance)
Resets the converter (sets all configurations to reset values)
adc_clk_divide_t clockDivide
void ADC_DRV_GetChanResult(const uint32_t instance, const uint8_t chanIndex, uint16_t *const result)
Gets the last result for the selected control channel.
Defines the hardware average configuration.
void ADC_DRV_ConfigChan(const uint32_t instance, const uint8_t chanIndex, const adc_chan_config_t *const config)
Configures the selected control channel with the given configuration structure.
static bool ADC_HAL_GetContinuousConvFlag(const ADC_Type *const baseAddr)
Gets the Continuous Conversion Flag state.
void ADC_DRV_ConfigHwCompare(const uint32_t instance, const adc_compare_config_t *const config)
Configures the Hardware Compare feature with the given configuration structure.
void ADC_DRV_GetChanConfig(const uint32_t instance, const uint8_t chanIndex, adc_chan_config_t *const config)
Gets the current control channel configuration for the selected channel index.
static uint16_t ADC_HAL_GetUserGainValue(const ADC_Type *const baseAddr)
Gets the User Gain Register value.
void ADC_DRV_InitChanStruct(adc_chan_config_t *const config)
Initializes the control channel configuration structure.
void ADC_DRV_InitConverterStruct(adc_converter_config_t *const config)
Initializes the converter configuration structure.
void ADC_DRV_ClearTriggerErrors(const uint32_t instance)
Clear all latch trigger error.
static void ADC_HAL_ClearLatchTriggers(ADC_Type *const baseAddr)
Clear the latched triggers.
void ADC_DRV_GetConverterConfig(const uint32_t instance, adc_converter_config_t *const config)
Gets the current converter configuration.
static bool ADC_HAL_GetHwCompareRangeEnableFlag(const ADC_Type *const baseAddr)
Gets the Hardware Compare Range Enable state.
static void ADC_HAL_SetUserGainValue(ADC_Type *const baseAddr, const uint16_t value)
Sets the User Gain Register value.
void ADC_DRV_InitUserCalibrationStruct(adc_calibration_t *const config)
Initializes the User Calibration configuration structure.
static void ADC_HAL_SetHwAverageEnableFlag(ADC_Type *const baseAddr, const bool state)
Sets the Hardware Average Enable Flag state.
IRQn_Type ADC_DRV_GetInterruptNumber(const uint32_t instance)
Returns the interrupt number for the ADC instance.
static uint32_t ADC_HAL_GetTriggerLatchFlags(const ADC_Type *const baseAddr)
Get the trigger latch flags bits.
bool compareRangeFuncEnable
static adc_inputchannel_t ADC_HAL_GetInputChannel(const ADC_Type *const baseAddr, const uint8_t chanIndex)
Gets the configured input channel for the selected measurement channel.
static void ADC_HAL_SetResolution(ADC_Type *const baseAddr, const adc_resolution_t resolution)
Sets the Resolution Mode configuration.
Defines the converter configuration.
static void ADC_HAL_SetHwCompareComp1Value(ADC_Type *const baseAddr, const uint16_t value)
Sets the Compare Register 1 value.
static uint32_t ADC_HAL_GetTriggerErrorFlags(const ADC_Type *const baseAddr)
Get the trigger latch error flags.
static void ADC_HAL_ClearTriggerErrorFlags(ADC_Type *const baseAddr)
Clear the latch trigger error flags.
#define ADC_INSTANCE_COUNT
void ADC_HAL_Init(ADC_Type *const baseAddr)
Initializes the ADC instance to reset values.
adc_average_t
Hardware average selection Implements : adc_average_t_Class.
static void ADC_HAL_SetHwCompareGtEnableFlag(ADC_Type *const baseAddr, const bool state)
Sets the Hardware Compare Greater Than Enable Flag state.
static void ADC_HAL_SetInputChannel(ADC_Type *const baseAddr, const uint8_t chanIndex, const adc_inputchannel_t inputChan)
Sets the input channel configuration for the measurement channel.
static adc_clk_divide_t ADC_HAL_GetClockDivide(const ADC_Type *const baseAddr)
Gets the current ADC clock divider configuration.
static bool ADC_HAL_GetDMAEnableFlag(const ADC_Type *const baseAddr)
Gets the DMA Enable Flag state.
static adc_average_t ADC_HAL_GetHwAverageMode(const ADC_Type *const baseAddr)
Gets the Hardware Average Mode.
void ADC_DRV_GetUserCalibration(const uint32_t instance, adc_calibration_t *const config)
Gets the current User Calibration configuration.
static uint16_t ADC_HAL_GetUserOffsetValue(const ADC_Type *const baseAddr)
Gets the User Offset Register value.
static void ADC_HAL_SetTriggerMode(ADC_Type *const baseAddr, const adc_trigger_t trigger)
Sets the ADC Trigger Mode.
adc_trigger_t
Trigger type selection Implements : adc_trigger_t_Class.
static void ADC_HAL_SetHwCompareEnableFlag(ADC_Type *const baseAddr, const bool state)
Sets the Hardware Compare Enable Flag state.
static void ADC_HAL_SetHwCompareRangeEnableFlag(ADC_Type *const baseAddr, const bool state)
Sets the Hardware Compare Range Enable state.
static adc_voltage_reference_t ADC_HAL_GetVoltageReference(const ADC_Type *const baseAddr)
Gets the ADC Reference Voltage selection.
static void ADC_HAL_SetHwCompareComp2Value(ADC_Type *const baseAddr, const uint16_t value)
Sets the Compare Register 2 value.
static uint16_t ADC_HAL_GetHwCompareComp1Value(const ADC_Type *const baseAddr)
Gets the Compare Register 1 value.
static void ADC_HAL_SetVoltageReference(ADC_Type *const baseAddr, const adc_voltage_reference_t voltageRef)
Sets the ADC Reference Voltage selection.
static adc_resolution_t ADC_HAL_GetResolution(const ADC_Type *const baseAddr)
Gets the Resolution Mode configuration.
bool compareGreaterThanEnable
void ADC_DRV_ClearLatchedTriggers(const uint32_t instance, const adc_latch_clear_t clearMode)
Clear latched triggers under processing.
static adc_input_clock_t ADC_HAL_GetInputClock(const ADC_Type *const baseAddr)
Gets the AD Clock Input configuration.
static void ADC_HAL_SetDMAEnableFlag(ADC_Type *const baseAddr, const bool state)
Sets the DMA Enable Flag state.
adc_latch_clear_t
Defines the trigger latch clear method Implements : adc_latch_clear_t_Class.
static uint8_t ADC_HAL_GetSampleTime(const ADC_Type *const baseAddr)
Gets the Sample time in AD clock cycles.
static void ADC_HAL_SetHwAverageMode(ADC_Type *const baseAddr, const adc_average_t averageMode)
Sets the Hardware Average Mode.
void ADC_DRV_WaitConvDone(const uint32_t instance)
Waits for a conversion/calibration to finish.
static bool ADC_HAL_GetChanInterruptEnableFlag(const ADC_Type *const baseAddr, const uint8_t chanIndex)
Gets the Channel Interrupt Enable state.
adc_resolution_t resolution
void ADC_DRV_GetHwCompareConfig(const uint32_t instance, adc_compare_config_t *const config)
Gets the current Hardware Compare configuration.
static bool ADC_HAL_GetCalibrationActiveFlag(const ADC_Type *const baseAddr)
Gets the Calibration Active Flag state.
static bool ADC_HAL_GetHwCompareEnableFlag(const ADC_Type *const baseAddr)
Gets the Hardware Compare Enable Flag state.
void ADC_DRV_ConfigHwAverage(const uint32_t instance, const adc_average_config_t *const config)
Configures the Hardware Average feature with the given configuration structure.
Defines the hardware compare configuration.
adc_inputchannel_t channel
Defines the control channel configuration.