This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nRF5340 NVS and readback_protection

Hi Everybody,

We found little or no literature about readback_protection on the nRF5340 SOC. Our issue is that for development and debugging it is not practical to use nrfjprog -recover in order to re-flash as that completely erases the storage partition too. What is the right way to retain NVS data?

Thank you.

Regards,

Milan 

Parents
  • Hi Milan,

    You can find documentation about access port protection in the CTRL-AP - Control access port chapter in the product specification.

    If I understand you correctly, then this question is about how you handle this during development. And in that case it typically does not make sense to prevent debugging, so then you simply disable access port protection. If you program an application that has been built without ENABLE_APPROTECT defined then you should be good to go (as nrfjprog --recover will have written to UICR.APPROTECT allready, and as long as you do not do a full chip erase or write more to that register, it retains its value and debugging will continue to be enabled as long as you do not program firmware built with ENABLE_APPROTECT defined.

  • Almost all clear.

    Except, it is still totally unclear how this is done in practice. There are mentions of using a 32-bit key (?) for both the 

    NRF_CTRLAP_S->APPROTECT.DISABLE register and the debugger. But again this is just speculation. Can you please point me to a guide how to disable this? And re-enable in case. 
  • Hi,

    The chapter in the product specification I linked to shows the specific details, including that the magic word is 0x50FA50FA.

    In practice this is handled by the tools. When you get a new device or a locked device that you want to debug, you can recover using nrfjprog --recover. This will write to UICR.APPROTECT, and also flash a very simple temporary application that enables debugging. When you subsequently build your firmware the MDK is included and ENABLE_APPROTECT is not defined by default. So any new firmware you build and program will disable AP protection, i.e. keep enabling debugging.

    Note that west has a --recover option which lets you recover (including write to UICR.APPROTECT) and program in a single operation: west flash --recover

  • Hi Einar,

    Thank you. That seems to be clear. The problem is that in Zephyr 2.6.99-ncs it is re-enabled all the time. I cannot exactly locate where this happens.  And that makes development work impossible as I have to recover the SOC between every flashing. Loosing NVS storage as well.

    CONFIG_NRF_SECURE_APPROTECT_LOCK=n does not seem to be supported yet. I assume this will solve the issue for Zephyr 2.7.0.
  • I do not see this on my side using nRF Connect SDK 1.7.0 (which uses v2.6.99-ncs1 tag of the NCS zephyr fork). Are you using NCS or are you using Zephyr stand-alone? If using NCS, then please let me know the details of how you work so that perhaps I can spot the issue (if you for instance do a full chip erase without subsequently recovering or similar).

    CONFIG_NRF_SECURE_APPROTECT_LOCK does not exist in the current nRF Connect SDK release (1.7.0).

Reply
  • I do not see this on my side using nRF Connect SDK 1.7.0 (which uses v2.6.99-ncs1 tag of the NCS zephyr fork). Are you using NCS or are you using Zephyr stand-alone? If using NCS, then please let me know the details of how you work so that perhaps I can spot the issue (if you for instance do a full chip erase without subsequently recovering or similar).

    CONFIG_NRF_SECURE_APPROTECT_LOCK does not exist in the current nRF Connect SDK release (1.7.0).

Children
  • Yes, I am using the exact same version. From the ncs master branch. 
    After running --recover all works fine for the first flashing, the second one fails due to read protection.

    ERROR: The operation attempted is unavailable due to readback protection in
    ERROR: your device. Please use --recover to unlock the device.
    ERROR: runners.nrfjprog: Flashing failed because the target must be recovered.
      To fix, run "west flash --recover" instead.
      Note: your target is an nRF53; all flash memory for both the network and application cores will be erased prior to reflashing.
    FATAL ERROR: command exited with status 16: nrfjprog --program .../build/zephyr/GENERATED_CP_NETWORK_merged_domains.hex --sectorerase -f NRF53 --snr 960180710 --coprocessor CP_NETWORK

  • Can you share exact details of which application you build and flash and every single command you use between recovering the first time and when this fails with the second application? For this to fail, there must be some point where either the UICR.APPROTECT is modified to no longer contain the magic word, or you program an application which does not enable debugging. We just need to find out which step you do that cases one of these things to happen.

  • It is basically the zigbee coordinator CLI example with CONFIG_NVS=y and CONFIG_SHELL=y. The only command that is used between recovery and flash is "west flash" with the nrfjprog runner. 

  • Isee. But please provide exact steps to increase my chances of reproducing. From starting fresh, then changing to this directory, then calling this command, so this command, etc, until the issue is seen (by for instance not being able to read flash using nrfjprog --memrd).

    Please also include which nRF Connect SDK version you are using, which nrfjprog version, etc. Please elaborate.

  • No problem. (I could not reply to your latest comment).

    The step by step flow is as is.

    Step nr.1:
    
    nrfjprog version: 10.14.0 external
    JLinkARM.dll version: 7.52d
    
    % nrfjprog --recover                                                   
    Recovering device. This operation might take 30s.
    Writing image to disable ap protect.
    Erasing user code and UICR flash areas.
    
    STEP nr.2:
    
    -- west flash: using runner nrfjprog
    Using board 960180710
    -- runners.nrfjprog: Flashing file: .../build/zephyr/merged_domains.hex
    -- runners.nrfjprog: .../build/zephyr/merged_domains.hex targets both nRF53 coprocessors; splitting it into: .../build/zephyr/GENERATED_CP_NETWORK_merged_domains.hex and .../build/zephyr/GENERATED_CP_APPLICATION_merged_domains.hex
    Parsing image file.
    Applying system reset.
    Verified OK.
    Parsing image file.
    Applying system reset.
    Verified OK.
    Applying pin reset.
    -- runners.nrfjprog: Board with serial number 960180710 flashed successfully.
    
    Terminal will be reused by tasks, press any key to close it.
    
    STEP nr.3:
    
    > Executing task in folder zephyr_zigbee_slave: west flash <
    
    -- west flash: rebuilding
    [0/4] Performing build step for '802154_rpmsg_subimage'
    ninja: no work to do.
    -- west flash: using runner nrfjprog
    Using board 960180710
    -- runners.nrfjprog: Flashing file: .../build/zephyr/merged_domains.hex
    -- runners.nrfjprog: .../build/zephyr/merged_domains.hex targets both nRF53 coprocessors; splitting it into: .../build/zephyr/GENERATED_CP_NETWORK_merged_domains.hex and .../build/zephyr/GENERATED_CP_APPLICATION_merged_domains.hex
    Parsing image file.
    Applying system reset.
    Verified OK.
    Parsing image file.
    ERROR: nrfjprog failed for an unknown reason. Run the same command again with
    ERROR: argument --log, contact Nordic Semiconductor and provide the generated
    ERROR: log.log file to them.
    NOTE: For additional output, try running again with logging enabled (--log).
    NOTE: Any generated log error messages will be displayed.
    FATAL ERROR: command exited with status 65: nrfjprog --program .../build/zephyr/GENERATED_CP_APPLICATION_merged_domains.hex --sectorerase -f NRF53 --snr 960180710 --coprocessor CP_APPLICATION
    The terminal process "zsh '-c', 'west flash'" terminated with exit code: 65.
    
    Terminal will be reused by tasks, press any key to close it.
    
    STEP nr.4:
    
    % nrfjprog --memrd 0x01000000
    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.
    % nrfjprog --memrd 0x01000000 --log
    ERROR: [  JLink] - Could not find core in Coresight setup 
    ERROR: [SeggerBackend] - JLinkARM.dll reported error -1 at line 4410.
    ERROR: [SeggerBackend] - JLinkARM.dll reported "-261", "Could not find supported CPU.".
    ERROR: [  JLink] - Could not find core in Coresight setup 
    ERROR: [SeggerBackend] - JLinkARM.dll reported error -1 at line 4410.
    ERROR: [SeggerBackend] - JLinkARM.dll reported "-261", "Could not find supported CPU.".
    ERROR: [  JLink] - Could not find core in Coresight setup 
    ERROR: [SeggerBackend] - JLinkARM.dll reported error -1 at line 4410.
    ERROR: [SeggerBackend] - JLinkARM.dll reported "-261", "Could not find supported CPU.".
    ERROR: [  JLink] - Could not find core in Coresight setup 
    ERROR: [SeggerBackend] - JLinkARM.dll reported error -1 at line 4410.
    ERROR: [SeggerBackend] - JLinkARM.dll reported "-261", "Could not find supported CPU.".
    ERROR: [  JLink] - Could not find core in Coresight setup 
    ERROR: [SeggerBackend] - JLinkARM.dll reported error -1 at line 4410.
    ERROR: [SeggerBackend] - JLinkARM.dll reported "-261", "Could not find supported CPU.".
    

    I had logs from before updated the command line tools and Jlinkt to the latest. 

    --------------------------------------------------------------------------------
    [2021-Sept-28 15:44:02] [ info] nrfjprog --program .../build/zephyr/GENERATED_CP_NETWORK_merged_domains.hex --sectorerase -f NRF53 --snr 960180710 --coprocessor CP_NETWORK --log 
    [2021-Sept-28 15:44:02] [ info] nrfjprog version 10.12.1 
    [2021-Sept-28 15:44:02] [ info] --------------------------------------------------------------------------------
    [2021-Sept-28 15:44:02] [debug] [ nRF0x0] - open_dll
    [2021-Sept-28 15:44:02] [ info] [ nRF0x0] - Load library at /Applications/Nordic Semiconductor/nrfjprog/libjlinkarm_nrf53_nrfjprogdll.dylib.
    [2021-Sept-28 15:44:02] [ info] [ nRF0x0] - Library loaded, loading member functions.
    [2021-Sept-28 15:44:02] [ info] [ nRF0x0] - Member functions succesfully loaded.
    [2021-Sept-28 15:44:02] [ info] [Backend] - Logger callback at 0x105221300 registered in Segger backend logger.
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Logger callback at 0x105221300 registered in JLink logger.
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - open
    [2021-Sept-28 15:44:02] [debug] [Backend] - open_dll
    [2021-Sept-28 15:44:02] [ info] [Backend] - No J-Link DLL path was provided. Attempting to auto detect.
    [2021-Sept-28 15:44:02] [ info] [Backend] - Load library at /Applications/SEGGER/JLink/libjlinkarm.7.20.0.dylib.
    [2021-Sept-28 15:44:02] [ info] [Backend] - Library loaded, loading member functions.
    [2021-Sept-28 15:44:02] [ info] [Backend] - Member functions succesfully loaded.
    [2021-Sept-28 15:44:02] [debug] [Backend] - dll_version
    [2021-Sept-28 15:44:02] [ info] [Backend] - Segger dll version 7.20.  loaded.
    [2021-Sept-28 15:44:02] [debug] [ nRF0x0] - enum_emu_snr
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - enum_emu_snr
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_emu
    [2021-Sept-28 15:44:02] [debug] [Backend] - enum_emu_snr
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_enum_emu_snr
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_get_num_emus
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_emu
    [2021-Sept-28 15:44:02] [debug] [ nRF0x0] - connect_to_emu_with_snr
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - connect_to_emu_with_snr
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_emu
    [2021-Sept-28 15:44:02] [debug] [Backend] - connect_to_emu_with_snr
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_emu
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_enum_emu_snr
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_get_num_emus
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_connect_to_emu_with_snr
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_connect_to_emu_without_snr
    [2021-Sept-28 15:44:02] [ info] [Backend] - Segger logging enabled.
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Firmware: J-Link OB-K22-NordicSemi compiled Apr 29 2021 15:10:52
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Firmware: J-Link OB-K22-NordicSemi compiled Apr 29 2021 15:10:52
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Decompressing FW timestamp took 217 us
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Hardware: V1.00
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] S/N: 960180710
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] OEM: SEGGER
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Feature(s): RDI, FlashBP, FlashDL, JFlash, GDB
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] TELNET listener socket opened on port 19021
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] WEBSRV Starting webserver
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] WEBSRV Webserver running on local port 19080
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 39.603ms returns "O.K."  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_Lock()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_GetHWStatus(...)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.313ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_ExecCommand("SetRestartOnClose = 0", ...).   
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.005ms returns 0x01  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_ExecCommand("DisableFlashDL", ...).   
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.008ms returns 0x00  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_ExecCommand("ExcludeFlashCacheRange 0x0-0xFFFFFFFF", ...).   
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.009ms returns 0x00  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_SetHookUnsecureDialog  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_SetHookUnsecureDialog(...)
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.022ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_TIF_Select(JLINKARM_TIF_SWD)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 1.073ms returns 0x00  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_SetSpeed(2000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.253ms  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_GetSN()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.007ms returns 960180710  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_load_core_data
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_ExecCommand("CORESIGHT_SetIndexAHBAPToUse = 0", ...).   
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.008ms returns 0x00  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_ExecCommand("device = Cortex-M33", ...).   
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] XML file found at: /Applications/SEGGER/JLink_V720/JLinkDevices.xml 
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] /Applications/SEGGER/JLink_V720/JLinkDevices.xml evaluated successfully. 
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Device "CORTEX-M33" selected.
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Device "CORTEX-M33" selected.
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 25.140ms returns 0x00  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_debug_port_idr
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - coresight_configure
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_Configure()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.707ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 255, DP Bank 0, AP Bank 255
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.364ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(DP reg 0x00)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x6BA02477
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.356ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.029ms  
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - enable_coprocessor
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_emu
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_IsOpen()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.004ms returns 0x01  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_Lock()  
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_enable_coprocessor
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_is_secure_debug_available
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_is_debug_region_powered
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 255, DP Bank 0, AP Bank 255
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.342ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(DP reg 0x01)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0xF0000040
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.386ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_access_port_register
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(AP reg 0x00)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x43000002
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 1.598ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_is_peripheral_mapped_secure
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_is_secure_debug_available
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_access_port_register
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(AP reg 0x00)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x43000002
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.341ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [warning] [nRF530x0] - Secure trustzone access required to read SPU config. Assume NS access.
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_readback_status
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 2, DP Bank 0, AP Bank 0
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x02000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 1.435ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(AP reg 0x03)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x00000003
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.352ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 0, DP Bank 0, AP Bank 0
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.335ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(AP reg 0x00)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x43000002
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.432ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [nRF530x0] - Protection status read as APPROTECT -> ALL
    [2021-Sept-28 15:44:02] [ info] [nRF530x0] - Application core access protection is enabled, can't enable coprocessor.
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.009ms  
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - select_coprocessor
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_emu
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_IsOpen()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.004ms returns 0x01  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_Lock()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_device
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_device
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_IsConnected()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.004ms returns FALSE  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_select_coprocessor
    [2021-Sept-28 15:44:02] [ info] [nRF530x0] - Loading new coprocessor data.
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_load_coprocessor_data
    [2021-Sept-28 15:44:02] [debug] [Backend] - set_core_data
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.011ms  
    [2021-Sept-28 15:44:02] [debug] [ nRF0x0] - read_device_version
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - read_device_info
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_emu
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_IsOpen()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.004ms returns 0x01  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_Lock()  
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_read_device_version
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_is_debug_region_powered
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 255, DP Bank 0, AP Bank 255
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 1.541ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(DP reg 0x01)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0xF0000040
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.332ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 3, DP Bank 0, AP Bank 3
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x03000030)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.343ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(AP reg 0x00)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x00000007
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.424ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_access_port_register
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(AP reg 0x01)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x00000005
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.500ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_decode_device_version
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.007ms  
    [2021-Sept-28 15:44:02] [debug] [ nRF0x0] - is_bprot_enabled
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - is_bprot_enabled
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_emu
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_IsOpen()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.011ms returns 0x01  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_Lock()  
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_is_bprot_enabled
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - Just_readback_status
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_is_debug_region_powered
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 255, DP Bank 0, AP Bank 255
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.580ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(DP reg 0x01)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0xF0000040
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 1.667ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 3, DP Bank 0, AP Bank 0
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x03000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.276ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(AP reg 0x03)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x00000001
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.242ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_access_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 1, DP Bank 0, AP Bank 0
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x01000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.281ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(AP reg 0x00)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x43000002
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.241ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [nRF530x0] - Protection status read as APPROTECT -> ALL
    [2021-Sept-28 15:44:02] [ info] [nRF530x0] - Access protection is enabled, can't read block protection state.
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.032ms  
    [2021-Sept-28 15:44:02] [debug] [ nRF0x0] - close_dll
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - close
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_emu
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_IsOpen()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.004ms returns 0x01  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_Lock()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - close
    [2021-Sept-28 15:44:02] [debug] [Backend] - disconnect_from_emu
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_disconnect_from_emu
    [2021-Sept-28 15:44:02] [debug] [Backend] - is_connected_to_device
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_IsConnected()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.004ms returns FALSE  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_is_debug_region_powered
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - Select AP 255, DP Bank 0, AP Bank 255
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x02, 0x00000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.329ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(DP reg 0x01)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0xF0000040
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.385ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - unpower_debug_and_system_regions
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_write_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_debug_port_register
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_WriteAPDPReg(DP reg 0x01, 0x00000000)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.252ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_is_debug_region_powered
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_read_debug_port_register
    [2021-Sept-28 15:44:02] [debug] [Backend] - ---just_select_debug_port_register
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_CORESIGHT_ReadAPDPReg(DP reg 0x01)  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] Value=0x00000040
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.372ms returns 0  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_HasError()  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] - 0.005ms  
    [2021-Sept-28 15:44:02] [ info] [  JLink] - [Info    ] [JLink     ] JLINK_Close()  
    [2021-Sept-28 15:44:02] [debug] [Backend] - Segger Backend closed.
    [2021-Sept-28 15:44:02] [debug] [nRF530x0] - nRF family DLL closed
    

    nrfSDK version is as: 1.7.99

Related