Skip to main content
alex95
Associate
January 13, 2026
Solved

Enable RDP after UART dfu

  • January 13, 2026
  • 2 replies
  • 321 views

Hi,

we are experiencing an issue with the STM32G0B0 when RDP level 1 is enabled, following the steps below:

  1. Flash the device using J-Link
  2. Start the device and let the application set RDP = 1
  3. Enter the STM32 ROM bootloader (via UART)
  4. Disable RDP protection (perform mass erase)
  5. Program new firmware with bootloader
  6. Reboot the device and set RDP = 1 again

After this sequence, the device remains locked.
Even if we apply multiple resets using the NRST pin, the device does not recover.
The only way to unlock the device is to completely power-cycle it (turn the power off and on again).

Is it possible to re-enable RDP protection and start the new firmware without removing power from the device?

Thank you for your support.

Best answer by Bubbles

Hi @alex95,

some OB, usually those associated with lifecycle (RDP) require a POR to register (do OB loading). The usual HAL_FLASH_OB_Launch() is not enough.

There's a workaround, POR OBL is not only done on power-cycle, but also on wakeup from Standby and Shutdown low power modes. After programming OB, have the code enter and then leave the low power mode. For the wakeup, you can use for example RTC.

Then the RDP will be modified without need to power-cycle.

BR,

J

2 replies

Bubbles
BubblesBest answer
ST Employee
January 13, 2026

Hi @alex95,

some OB, usually those associated with lifecycle (RDP) require a POR to register (do OB loading). The usual HAL_FLASH_OB_Launch() is not enough.

There's a workaround, POR OBL is not only done on power-cycle, but also on wakeup from Standby and Shutdown low power modes. After programming OB, have the code enter and then leave the low power mode. For the wakeup, you can use for example RTC.

Then the RDP will be modified without need to power-cycle.

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.
AScha.3
Super User
January 13, 2026

Hi,

from rm

AScha3_0-1768304737613.png

So seems you have to do a power cycle , as you already found out.

"If you feel a post has answered your question, please click ""Accept as Solution""."