AnsweredAssumed Answered

STM032L072 ADC empty sequence analog input pin sourcing current

Question asked by Ruud van Helden on Mar 6, 2018

I have a circuit which can measure an input voltage. It is connected with an 100K/10K divider with a 10nF added for HF suppression. The same connection point is also connected to an analog comparator which is attached to an digital input. So i can use this input as an analog input, or as a digital input with interrupt options.


I got an interrupt on my digital input pin at a certain point in my code, even with nothing attached to this circuit. I attached my scope (blue 2V/div, red 0,4V/div, 20us/div). red center of the divider; blue comparator output;

when i lift / disconnect the pin from the pcb the problem is solved. (lqfp)

The exact moment where it happens is when the HAL_ADC_Start(&hadc) starts the conversion of the regular group at 

hadc->Instance->CR |= ADC_CR_ADSTART;


The problem only happens when the regular group has no channels to measure. The solution is to not start the measurement with an empty regular group.

When there is at least 1 regular group member there is no problem.

I constantly change the regular group as i have a complex system. And starting conversion with empty group is silly, but current coming out of the analog input pin is even more?


I can't see any warning (errata/datasheet/reference_manual) to not start with an empty regular group. Is this behaviour known?


I wan't to check because i wan't to know for sure that it is the problem as i describe, and it is fixed correctly. 


Thanks in advance!