Skip to main content
Associate
October 27, 2023
Question

readout protection without power on reset

  • October 27, 2023
  • 9 replies
  • 2635 views

Dear support team, 

I need to activate and deactivate the readout protection on a fully automated CI enviroment and according to the RM0440 (Note: If the read protection is set while the debugger is still connected through JTAG/SWD, apply
a POR (power-on reset) instead of a system reset.) a POR cycle is required. 

Is there a way to solve this without a POR? The used hardware for CI does not provide means to perform a POR. Is there any G3 register I can manipulate to have the desired result?

Why the behavior is different from STM32F3x? For F3 no POR is required.

Thanks in advance!

 

BR

Bruno

This topic has been closed for replies.

9 replies

Peter BENSCH
ST Technical Moderator
October 27, 2023

Welcome @bruno_mazzarotto, to the community!

Please have a look at this video (STM32 Security tips - 3 RDP without POR) and check if you can get on with the transition from standby state, the STM32G4 should behave identically. All materials (including sources of the examples) related to this video you can find using this link.

Hope that helps?

Good luck!
/Peter

In order 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.
Associate
October 27, 2023

Hi Peter, thanks for the support.

Unfortunately I can not add the code to trigger standy mode to our code.

Is there a way I can achieve the same results by writing registers with open_ocd?

 

Peter BENSCH
ST Technical Moderator
October 27, 2023

I am not aware of any other way than the alternative mentioned.

Regards
/Peter

In order 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.
Associate
October 30, 2023

Maybe by manipulating FLASH_CR register, setting OBL_LAUNCH bit to 1 and wait a bit. Maybe you'll need to re-attach the openocd connection because it will reset the target.

Hagi_0-1698693016121.png

 

Associate
October 31, 2023

Hi, no, this does not work. Only thing that helps is to do a Power On cycle when the debugger cable is attached

Douglas MILLER
ST Employee
October 30, 2023

This forum thread was marked by the moderator as needing a little more investigation, so a Support case was created in your name and will be handled off-line.

waclawek.jan
Super User
May 2, 2024

Hi @bruno_mazzarotto ,

Have you been able to solve this problem?

Thanks,

JW

Associate
May 2, 2024

Hi, I've added a power on cycle on the process and then it worked.

waclawek.jan
Super User
May 3, 2024

@bruno_mazzarotto,

I see. That's the straighforward solution anyway.

Thanks.

JW