Skip to main content
JFieb.1
Visitor II
March 13, 2023
Question

STM32H750IB How set the RDP Level ?

  • March 13, 2023
  • 1 reply
  • 1294 views

When I set the RDP Level 1 the Controller stops working.

I must unpower the Controller and power it agin, NRST didn't work.

I use the code:

       HAL_FLASH_Unlock();

       HAL_FLASH_OB_Unlock();

       OBIni.OptionType = OPTIONBYTE_RDP;

       OBIni.RDPLevel = OB_RDP_LEVEL_1;

       if ( HAL_FLASHEx_OBProgram(&OBIni) != HAL_OK )

       {

          HAL_FLASH_OB_Lock();

          HAL_FLASH_Lock();

          return;

       }

       HAL_FLASH_OB_Launch();

       /* We should not make it past the Launch, so lock

        * flash memory and return an error from function

        */

       HAL_FLASH_OB_Lock();

       HAL_FLASH_Lock();          

What must I do, that the controller didnt stop after the HAL_FLASH_OB_Launch(); ?

This topic has been closed for replies.

1 reply

Technical Moderator
April 13, 2023

Hello @Jürgen Fiebig​,

Check this article How to program STM32 Option Bytes with the HAL API 2. Setting RDP Level

Note:  HAL_FLASH_OB_Launch(); is called to generate System Reset to load the new option byte values.

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.Best regards,FBL