Unstable RTT logging

Hello,

I would love to use RTT in a nRF5340 project. I'm using Nordic Connect SDK v2.7.99-cs2. In a debug build, I very often see the problem, that some of expected log messages do not show up in JlinkRTTView:

Sometimes, I see the complete message:

00> [00:00:00.372,741] <inf> bt_hci_core: HW Platform: Nordic Semiconductor (0x0002)
00> [00:00:00.372,863] <inf> bt_hci_core: HW Variant: nRF53x (0x0003)
00> [00:00:00.372,924] <inf> bt_hci_core: Firmware: Standard Bluetooth controller (0x00) Version 195.39642 Build 3554797951
00> [00:00:14.046,875] <inf> bluetooth: connected: 0

but most often, I see just a fraction of the log messages:

00> [00:00:00.651,824] <inf> bt_hci_core: HW Platform: Nordic Semiconductor (0x0002)
00> [00:00:00.651,885] <inf> bt_hci_core: HW Variant: nRF53x (0x0003)
00> [00:00:00.651,947] <inf> bt_hci_core: Firmwa
00> 0m

The fraction is very reproducible, means whenever I see just part of the expected message, it is the very same fraction. Later, there are still log messages, so the output is not fully switched off.

This is the RTT configuration:

CONFIG_LOG=y
CONFIG_USE_SEGGER_RTT=y
CONFIG_LOG_BACKEND_RTT=y
CONFIG_LOG_BACKEND_UART=n
CONFIG_LOG_MODE_MINIMAL=n
CONFIG_LOG_PRINTK=y
CONFIG_LOG_MODE_DEFERRED=n
CONFIG_LOG_BUFFER_SIZE=65536

The used hardware is a J-Trace Pro Cortex. Any idea, what the problem could be here and how to improve the situation?

best regards

Torsten

Related