Connecting and disconnecting SWD debugger resets the device

Hello,

We have many nrf9160 based devices currently on the market running for our customers. These devices are facing some problems that we are trying to debug right now by letting them run overnight and reading the RTT logs from it.

However, as soon as we conenct and disconnect our devices with an SWD debugger, the device immediately resets, and hence we can not read any logs. I was reading that J-link might have that as part of their conenction sequence to have the device reset. However we are not sure why the device would reset during disconnection of the SWD port as well. Which led us to believe that it could be a Nordic way of connecting. 

Is there any way to connect to this devices over SWD to read RTT logs without resetting the device everytime? If so, how to do that?



Thanks
Sid

Parents
  • Hi Jonathan,

    We use the Jlink ultra plus debugger. We enabled RTT logging for debugging, hence we use J-link RTT Viewer to view the output logs. For uploading the firmware on the device, we use the nrfjprog command line tool. 

    For the device itself - We run our own firmware developed on connect sdk 2.4.2. The device is a 9160 based custom board and its functionalities include running gpio input and output pins, communicating to server over LTE, running Edge impulse model etc. 

    Let me know if you need any further information. 


    Best regards, 

    Sid

  • Hi,

    It should be possible to achieve a no reset situation I believe. So there are a few things I want you to test to see if this is something related to the J-Link RTT viewer sw or something else.

    - Does it reset when using nrfjprog, like flashing or reading any APB register. 

    From what I can find it does not seem that a reset should happen by default. And I know that a reset does not happen by default when using nrfjprog.  
    https://forum.segger.com/index.php/Thread/8947-ABANDONED-RTT-Viewer-Resetting-Target/ 

    - Can you test with some other application. Use a simpler sample to see if the and enable RTT logging, then see if the reset happens then as well. 
       It could be that there is an error happens during attachment and that is causing the reset. 


    Regards,
    Jonathan

Reply Children
No Data
Related