Question
Detecting current channel in ADC interrupt callback
Posted on April 13, 2017 at 00:00
I have enabled analog watchdog in multi channel continues mode and now I'm trying to figure out how to find out which channel has triggered HAL_ADC_LevelOutOfWindowCallback. I have examinedhadc->NbrOfCurrentConversionRank but it seems this parameter is always 0 when it reaches to AWD callback.
void HAL_ADC_LevelOutOfWindowCallback(ADC_HandleTypeDef* hadc){
if(hadc->NbrOfCurrentConversionRank == 1)
__NOP;
else if(hadc->NbrOfCurrentConversionRank == 2)
__NOP;
}�?�?�?�?�?�?
How can I find number of the channel triggered AWD?
#hal #adc