2021-08-24 03:52 AM
After resetting, the output of PA9 and PA10 of the STM32G030K8 microcontroller is high. These pins are not initialized, according to the datasheet after reset they should have the function of an analog input. Once configured, they function normally as outputs.
It is important for me that after the reset and before the adjustment, the outputs are like analog inputs.
2021-08-24 04:05 AM
Your flash is probably empty and you are in Bootloader Mode.
2021-08-24 04:16 AM
It can't be. If the microcontroller was in bootloader mode it would not execute my code. Even if the microcontroller is empty, according to the datasheet, the pins should be analog inputs.
2021-08-24 04:26 AM
You are correct that when the microcontroller is empty, PA9 and PA10 are high.
Pin BOOT0 is connected to GND through a resistor and the microcontroller should not be in bootloader mode.
2021-08-24 04:30 AM
Earlier, I see a high status of PA9 and PA10. I have now checked again with an empty code while (1); and PA9 and PA10 are not high
2021-08-24 04:42 AM
Carefully check AN2606 for the conditions of bootlloader empty.
2021-08-24 05:01 AM
These are the USB Power Delivery Dead-Battery (UCPDx_DBCCx) pins, even if the 'G030 DS does not mark them as such. RM0444 says:
The DBCC pads (GPIOs of FT_d type) present more leakage than standard GPIOs. Refer
to product datasheet for values.
I mistook it for 'G070, sorry.
JW
2021-08-24 11:14 AM
Hold the chip in reset. Do they behave as analog pins? If you release reset and they change, something is configuring them otherwise either in the bootloader or in user code.
If not, then either the RM is wrong, or you're mistaken.