Error when programming lora-e5 mini dev board to remove RDP

hello,

i have an error error when programming lora-e5 mini dev board, i use stlink v2 with latest firmware and
stm32cubeprogrammer. To be able to read I need to switch to HOT-PLUG mode and connect with pressing reset button.first attempt it did not find the device, second attempt is connect well and it can read the configuration bit. RDB is at β€˜BB’. So when I try to program AA it wont ant throw an error ?

Any idea ?

Best Regards,

laurent

Finally it was my genuine st-link v2 ? target voltage was never more than 1.2v. I bought a clone and all is ok,
i am able to remove RDP and target voltage is around 3.17v.

Laurent

now the problem even if RDP is removed, I cannot erase the flash or program a hex file ?
it continue saying to check flash protection ?

Laurent

RDB was locked at 0xAA and still no erase or flash capability, you need to set again RDP to 0xBB , unplug the board (very important, if not it will not work and stay locked at 0xAA), reconnect to the stm32, you will see RDP with a strange value 0xFF, that is ok, and set back RDP to 0xAA, this time you will be able to change the value.

Today all is ok, I can erase and flash anything :slight_smile: very very very strange …

1 Like

For anyone else stumbling upon this thead: with a genuine ST-Link V2 you need to connect 3.3V from LoRa-E5 mini to pin 1 or 2 of ST-Link V2 (MCU VDD) in addition to SWCLK/SWDIO/GND.

1 Like

Hello my RDP is locked because the RDP stays at 0xAA and I canΒ΄t change it back to 0xBB. I want to erase the flash memory. Can Anyone help me?

Edit:
IΒ΄ve managed it to set RDP back to 0xBB and here is how i did it:

  1. disconnect all devices from PC (ST-Link and LoRa E5 mini)
  2. connect both the ST Link with your PC and the LoRa Module
    ST Link V3 minie connectors β†’ LoRa Pins
    VCC β†’ 3v3
    RST β†’ RST
    GND β†’ GND
    CLK β†’ SWDLK
    TMS β†’ SWDIO
  3. open STM Cube Programmer
  4. press and hold the rst button on the LoRa E5 mini and click connect (Port = SWD; Mode = Hot Plug; Reset mode = Hardware Reset)
  5. go to OB (option bytes) β†’ Read Out Protection β†’ set RDP value to 0xBB β†’ click apply
  6. click Disconnect (located top right) and disconnect physically the boart from the PC
  7. reconnect the boards (ST Link and LoRa E5 mini) with the PC and click connect in STM Cube Programmer
  8. go to OB (option byte) and you will find the value od RDP is 0xFF

now you can change it back to 0xAA or erase flash memory