Hi,
sdk:ncs v1.6.1
board:9160dk_nrf9160
I use RTT to output log data, but I found that it can only output about 1k characters each time. Where can I modify it?
this my config about log

Hi,
sdk:ncs v1.6.1
board:9160dk_nrf9160
I use RTT to output log data, but I found that it can only output about 1k characters each time. Where can I modify it?
this my config about log

Hi,
I use RTT to output log data, but I found that it can only output about 1k characters each time. Where can I modify it?
Try setting "CONFIG_LOG_MINIMAL=y" (CONFIG_LOG_MODE_MINIMAL in ncs v1.7.0 and newer), which disables the logging thread.
You can also try to adjust "CONFIG_SEGGER_RTT_MAX_NUM_UP_BUFFERS".
If you do not want it to drop packets when the buffer is filled up, you can add this configuration:
CONFIG_SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL=y
Note that this will block if the FIFO is filled up, meaning that you need to open the RTT viewer to allow the program to run.
Kind regards,
Håkon
Hi,
I use RTT to output log data, but I found that it can only output about 1k characters each time. Where can I modify it?
Try setting "CONFIG_LOG_MINIMAL=y" (CONFIG_LOG_MODE_MINIMAL in ncs v1.7.0 and newer), which disables the logging thread.
You can also try to adjust "CONFIG_SEGGER_RTT_MAX_NUM_UP_BUFFERS".
If you do not want it to drop packets when the buffer is filled up, you can add this configuration:
CONFIG_SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL=y
Note that this will block if the FIFO is filled up, meaning that you need to open the RTT viewer to allow the program to run.
Kind regards,
Håkon
Hi Håkon,Thank you very much for your reply
I modified them separately according to your suggestions, but it didn’t seem to work
I did a more detailed test and found that only the first packet of data when the 9160 is turned on will be like this,all subsequent data are complete.
And I use the serial port to output log data, and there is no such problem at all.
It feels like a problem with RTT.
Hi,
Which settings did you enable?
If you are using a dedicated logger thread, you have to adjust the sizes there (see CONFIG_LOG_BUFFER_SIZE , CONFIG_LOG_BACKEND_RTT_OUTPUT_BUFFER_SIZE).
Did you set CONFIG_LOG_MINIMAL? If so, the SEGGER_RTT buffers need to be adjusted (ie. CONFIG_SEGGER_RTT_BUFFER_SIZE_UP and CONFIG_SEGGER_RTT_MAX_NUM_UP_BUFFERS) and you should look into setting CONFIG_SEGGER_RTT_MODE_BLOCK_IF_FIFO_FULL, as previously mentioned.
Kind regards,
Håkon