Application logs and modem traces over RTT - Parallel capture

Asset Tracker Template

tags
Asset Tracker Template

For simultaneous modem traces and application logs over RTT:

Add to prj.conf:

CONFIG_USE_SEGGER_RTT=y
CONFIG_LOG_BACKEND_RTT=y
CONFIG_SHELL_BACKEND_RTT=y
CONFIG_SHELL_BACKEND_RTT_BUFFER=1

Capture in separate terminals on different RTT channels:

# Terminal 1 - Modem traces
JLinkRTTLogger -Device NRF9160_XXAA -If SWD -Speed 50000 -RTTChannel 2 modem_trace.bin

# Terminal 2 - Application logs
JLinkRTTLogger -Device NRF9160_XXAA -If SWD -Speed 50000 -RTTChannel 0 terminal.txt

Note

You may need to adjust the RTT channel numbers depending on your configuration. The following is the default channel mapping:

  • Terminal: 0
  • Shell: 1
  • Modem trace: 2

For more information, see nRF Connect SDK Modem Tracing.