JLink read for new NRF52832 REV3 xxAA board

Hi~ I have a new NRF52832 REV3 xxAA board, and I need to read its SRAM value. However, when I use the JLink command to read it, I get 0. I have tried recover and eraseall, and still get 0. What should i do to obtain a normal bin file ?

Parents
  • Hi,

    Revision 3 of the DK use nRF5340 as onboard debugger. This should not matter in this case. However, it also uses revision 3 of the nRF52832, which was introduced with revision 2.2.0 of the DK. This has a difference that may be relevant here, as it has an improved access port protection where debugger access is blocked by default. If you are attempting to read the memory of a device with debugger access blocked you will have to do a full chip erase (including a SRAM erase) in order to disable debugger access. Could that be what has happened here? If not, perhaps you can describe in detail what you do so that I can attempt to reproduce on my end?

  • Thank you very much! 

    After getting the new board, I first read the SRAM directly with JLink. There was no prompt here, and I read 524288 bits 0.

    Secondly, I used nRFgo Studio to erase the board, but when I clicked nRF5x Programming, I was prompted that no device is detected, and I saw the recover button on the interface. After clicking the recover button , I was prompted that recover completed. However,the interface was not changed. Then I used nRF Connect for Desktop to erase the board, and the read SRAM values were still 0.

    Finally, I used the "nrfjprog -- recover - f NRF52 "command ,  then erased the board with nRF Connect for Desktop, and read the SRAM with JLink again. The values were  still 0. I also tried to turn off the board. After the board was opened and connected with the nRF Connect for Desktop programmer, I got a prompt that the device was protected.

  • I see, then what you are seeing is expected. Just to be clear, when the device is protected (access port protection is enabled, which is default), the only way to un-protect it is to recover (erase all), and that will set the SRAM to all zeros.

    If you use updated tools and SDKs this should not be a problem, as it is handled for you, and access port protection is disabled by default. Note that nRFgo Studio is legacy software that does not support these new devices. If you want a graphical programmer, you should look at nRF Connect Programmer.

    So please start using updated tools, and let me know if you still have problems. In that case, specify which version of the tools and SDK you are using, and what you have programmed on the device.

  • I expect that about half of the SRAM values read are 1, which is similar to NRF52832 REV2 . 

  • I see. That is what you would expect normally, but  not after an erase all (recover), as that explicitly sets all SRAM to 0. If you do a subsequent power cycle and read out the SRAM again you should see about 50% 1's, though. (this assumes that you use a updated nRF Command Line tools, as that will write a small application that unlocks debugger access when you do "nrfjprog --recover").

Reply Children
No Data
Related