cancel
Showing results for 
Search instead for 
Did you mean: 

STM32G474: Put ADC in known reset state?

TwelveSquared
Senior

My board can startup from a variety of different ways: from power-up reset, jump between application and bootloader, external watchdog reset, or software restart for other reasons.

I want to ensure ADC1 and ADC2 are initialized from a clean known state.

Is it okay to use the AHB2RSTR register, ADC12RST bits, at the beginning of the program, to ensure the ADC are starting up same as from power-up reset?

3 REPLIES 3
Bouraoui Chemli
ST Employee

Hi @TwelveSquared​ 

Yes, you can use that bit to reset the ADC.

Bouraoui

TwelveSquared
Senior

Hello @Bouraoui Chemli​ 

Will there be any problems if the ADC is enabled, doing conversions, etc., while this bit is used to reset it?

Thanks for your reply

Bouraoui Chemli
ST Employee

Hi @TwelveSquared​ 

There will be no problem. It is OK to use it when ADC is enabled.

Bouraoui