2023-01-16 04:39 AM
I'm using a STM32G070 MCU which I flash via i2c when the boot0 pin is set to high.
This works fine until I connect a ST-link to the MCU, program it and then disconnect the ST-link again. After that the i2c flash will fail, I have checked the boot0 and reset pin and these are set correctly, but when checking the i2c communication it seems like there is no reply from the boot loader address 0x51.
When I power cycle the MCU the i2c flash works fine again.
I have checked the boot select bit in the user option byte and it looks ok.
Anyone know if this is expected behavior after the ST link has been used or if it might be something I have missed?
Solved! Go to Solution.
2023-01-17 08:16 AM
Hi @ChrisTh.2,
it would appear that by connecting the debug interface, you have engaged read protection. That can only be lifted using power cycle, not by a system reset. It's a precaution to prevent reading the system memory (which contains more than just the i2c bootloader).
BR,
J
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2023-01-17 08:16 AM
Hi @ChrisTh.2,
it would appear that by connecting the debug interface, you have engaged read protection. That can only be lifted using power cycle, not by a system reset. It's a precaution to prevent reading the system memory (which contains more than just the i2c bootloader).
BR,
J
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2023-01-19 04:51 AM
Ok I didn't know about the read protection, but then it makes sense.
Thanks for the reply!