nRF52840 readout protection problem

Hi,

I have a custom pcb with NRF52840-QIAA-F-R (rev3) on it. And when I tried to program it first time, nrfjprog shown the folowing error:

ERROR: The operation attempted is unavailable due to readback protection in
ERROR: your device. Please use --recover to unlock the device.

So the memory readout protection seems to be set by default. It shouldn't be like this. Then I run the recover, and tried to program with softdevice (s140_nrf52_7.2.0_softdevice.hex) it was successful, but then when I tried to program the test app (ble_app_beacon), I had got the same readout protection error.

So, it appears that read protection is automatically activated on this controller.

If I program the SD and the app at the same time and then reset, it works. But then I can't debug.

I have got an nRF52840-DK board (with nRF52840 rev2), and it works well, but my custom board is not.

I have programmed many other custom pcbs with nrf52832 controller and never had such a problem.

Parents Reply Children
  • It's very strange. The error is not consistent. Sometimes the memrd run successfully after programming. Sometimes nrfjpog say this:


    ERROR: The operation attempted is unavailable due to readback protection in
    ERROR: your device. Please use --recover to unlock the device.
    NOTE: For additional output, try running again with logging enabled (--log).
    NOTE: Any generated log error messages will be displayed.

    Usually if I try to reprogram with --sectorerase it is ok (and then the memrd is also ok), but after I try with --chiperase I get the above error.

    The protection problem usually appears when a program that uses the BT stack (SD) is started.
    If the program does not start because only the SD has been written, then the error occurs less frequently.

  • Please check if the UICR.APPROTECT register remains set to HwDisabled/0x5A after you have programmed the Bluetooth FW.

    nevi said:
    The error is not consistent. Sometimes the memrd run successfully after programming. Sometimes nrfjpog say this:

    Have you noticed if the error starts occurring after a pin reset or power on reset? A regular soft reset will not be enough to re-activate the readback protection after a '--recover'.

    Note: Register APPROTECT.DISABLE is reset after pin reset, power or brownout reset, watchdog reset, or wake from System OFF as mentioned above. (Access port protection)

Related