Skip to main content
孟祝.1
Associate
October 26, 2021
Solved

Reason why stm32l412 read protection cannot be lowered

  • October 26, 2021
  • 6 replies
  • 3714 views

When preparing to set the option byte, it is found that the read protection setting is at level 1 and cannot be changed to level 0. Then, it cannot be applied when preparing to apply, as shown in figures 50693W00000FDkLLQA1.png

This topic has been closed for replies.
Best answer by Imen.D

Try to set RDP option byte to 0xBB (level 1) and then back to 0xAA (level 0).

Please let me know if this solves your problem.

6 replies

ST Technical Moderator
October 26, 2021

Hello @孟�?� �?​ ,

You can try using STM32CubeProgrammer. Try connecting under reset.

Have you checked if this behavior has occurred with other boards?

When your question is answered, please come back to the Community with update and close this topic by choosing Select as Best.

Imen

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Thanks
孟祝.1
孟祝.1Author
Associate
October 26, 2021

Thank you for your reply. When I download the program using stm32cubeprogrammer according to your suggestion, I still prompt "error: failed to erase memory", so I think the read-write protection should be cancelled. Is there any way to solve it? I haven't met in other development boards yet

Imen.DBest answer
ST Technical Moderator
October 26, 2021

Try to set RDP option byte to 0xBB (level 1) and then back to 0xAA (level 0).

Please let me know if this solves your problem.

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Thanks
Manny
Associate II
October 28, 2021

Are you able to connect to the target using stm32cubeprogrammer?

What was the condition of the mcu (where you able to program it earlier or it is a brand new mcu and has come with RDP out of the box)?

孟祝.1
孟祝.1Author
Associate
October 28, 2021

According to the above suggestions, use stm32cubeprogrammer to set the RDP value to FF, and then restore it to AA value. The problem of read protection has been solved. Thank you very much.

ST Technical Moderator
October 28, 2021

Hi @孟�?� �?​ ,

Glad to know the issue has been solved, and thanks for closing this thread.

Imen

In order to give better visibility on the answered topics, please click on 'Best answer' on the reply which solved your issue or answered your question. Thanks