can you help me out please:
I have followed devzone.nordicsemi.com/.../ and have configured as it shows.
But NRF_LOG_INFO does not work however SEGGER_RTT_printf does.
What should i do?
Which SDK version are you using? Have you set NRF_LOG_ENABLED and NRF_LOG_BACKEND_SERIAL_USES_RTT? Are you using NRF_LOG_DEFERRED? If you are, you need to call NRF_LOG_FLUSH() to process the log buffer.
I have a similar issue with SDK15.3. I managed to get the NRF_LOG working on one project after reading all the forum posts but when I try on a virgin instance of ble_app_multilink_central using this knowledge, logging does not work.
- I have compiled and run debug config
- Project settings are debug level 3
- NRF_LOG_ENABLED, NRF_LOG_BACKEND_RTT_ENABLED are enabled and NRF_LOG_DEFERRED disabled in sdk_config.h via CMSIS configurator. NRF_LOG_BACKEND_UART_ENABLED also disabled
No log messages are printed at any level. Printf works fine....
I just tested the ble_app_multilink_central example. UART logging works out of the box, setting NRF_LOG_BACKEND_RTT_ENABLED to 1 enables output in RTT viewer as well. Please try with a completely fresh copy of the entire SDK.
Thanks for the reply - I tried what you suggested and ran ble_app_multilink_central from a fresh copy of the SDK (nRF5_SDK_15.3.0_59ac345) and looking at the output via the Segger Studio after enabling NRF_LOG_BACKEND_RTT_ENABLED via CMSIS, saving, cleaning and rebuilding and I still see no output. Are there any other checks I can do? My other project still prints debug via RTT fine but I can't see what the difference is...
Are you sure that the config actually got set? CMSIS config wizard seems to require you to switch to view another config before saving for the value to be updated. I would recommend that you open the sdk_config.h file in a text editor and make sure the config is set there.
I agree that sometimes this can happen but I have confirmed settings are OK for what I understand is required:
I have tried other sample projects and none of them seem to work OOTB either although I did manage to get one working which is what I have been using as my base - wish I could remember what I did...
You are able to debug the application in SES? Which version of SES and J-Link are you using? I'm not sure what can cause issues if you are not able to see the logs with a clean SDK. As I said, I tested this and it worked well.