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

nrfjprog and SEGGER RTT Viewer do not work together. RTT Viewer and J-Flash Lite do.

There have been several other posts on this issue dating back a few years, such as this one.

On Windows 10, if I am using SEGGER's RTT Viewer and I flash a nRF52832 with SEGGER's J-Flash Lite, I experience no problems. The nRF52832 reboots and I immediately start to see messages in the RTT viewer.

However, if I instead flash the nRF52832 with nrfjprog, the connection to RTT Viewer is broken. If I reset the RTT Viewer connection then the messages restart.

Trying to flash with Zephyr's west tool while RTT Viewer breaks the RTT connection AND gives errors:

-- runners.nrfjprog: Flashing file: C:\Users\Chris\Nordic\v1.6.1\zephyr\samples\net\wifi\build\zephyr\zephyr.hex
Applying system reset.
Verified OK.
ERROR: JLinkARM DLL reported an error. Try again. If error condition
ERROR: persists, run the same command again with argument --log, contact Nordic
ERROR: Semiconductor and provide the generated log.log file to them.
FATAL ERROR: command exited with status 33: nrfjprog --pinresetenable -f NRF52 --snr 8010XXXXX

It should be possible for the RTT Viewer connection to remain connected since SEGGER is able to make this work, even though the RTT connection and the flashing are happening through SWD.

Parents
  • I assume this will be a feature request, since that combination is not supported today.

    For now you will either need to build and debug through SES, or you can for instance use west command line to build and flash the project and then Ozone for debugging. I am not aware of any way you can do this with nrfjprog + rtt viewer directly, though I can see it could be neat.

    Kenneth

  • I can see it could be neat.

    Definitely! Zephyr has some very nice support for RTT.

    The reason I posted here was that this thread from three years ago seems to suggest that it is known to work. Actually, your own reply suggests trying different USB ports or hubs. There are ways to work around it but, if nrfjprog was supposed to work this way (as that thread seemed to suggest), it would be the cleaner solution.

    Perhaps I'm misunderstanding the issue in that thread, but it does sound like the same problem.

    Anyway, if there is no support for RTT in nrfjprog, please add this to the feature request list. Slight smile

Reply
  • I can see it could be neat.

    Definitely! Zephyr has some very nice support for RTT.

    The reason I posted here was that this thread from three years ago seems to suggest that it is known to work. Actually, your own reply suggests trying different USB ports or hubs. There are ways to work around it but, if nrfjprog was supposed to work this way (as that thread seemed to suggest), it would be the cleaner solution.

    Perhaps I'm misunderstanding the issue in that thread, but it does sound like the same problem.

    Anyway, if there is no support for RTT in nrfjprog, please add this to the feature request list. Slight smile

Children
No Data
Related