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

Why was NRF_LOG_PRINTF and its tie-in to Segger output eliminated in SDK 12?

In SDK 11, there was an immensely useful function known as NRF_LOG_PRINTF. in SDK 12, this seems to have been replaced by NRF_LOG_DEBUG, NRF_LOG_INFO, NRF_LOG_ERROR. However, if you expand the macros to these functions, it becomes clear that the only value one can ever use is a uint32_t. What happened to the ability to print strings, individual hex values, etc?

One reasonably ugly workaround seems to be something like:

#include "SEGGER_RTT.h"

then global search and replace every occurrence of NRF_LOG_DEBUG(xxx) by

SEGGER_RTT_printf(0,xxx)

Seems like a major step backwards from what had been a very useful debug tool.

Parents Reply Children
Related