STM32G0 register factory values (device delivery) are different from reset values
Hi,
I have acquired a new STM32G031 microcontroller that has not been previously flashed and have observed an unexpected behavior when powering up my circuit prior to the initial software upload.
Upon further investigation, I discovered that multiple registers were not at their reset values, but instead at different values that were not anticipated. Specifically, the registers of GPIOA (such as MODER) had critical (in my application) pins set to pull-up (e.g., MODER set to 0xEBEB FFAF).
As such, I would like to know:
Is the initial state of the registers documented anywhere? I was unable to find such information in the reference manual (RM0444.pdf).
When in production with the final PCB already assembled, what is the safest approach to ensure the registers are at their reset values even when flashing fails (e.g erasing the device prior to flashing)?
I appreciate your assistance with this matter.
Note: While I understand that the safest solution would be to ensure that the external circuit can accommodate any pin state, this is not a viable option at present.
Best regards,
Martin
