Hi
In SDK 12.3.0 custom project use NRF_LOG_INFO output log, keil show: warning: #47-D: incompatible redefinition of macro "NRF_LOG_MODULE_NAME" (declared at line 60 of "....\components\libraries\log\nrf_log.h")
Hi
In SDK 12.3.0 custom project use NRF_LOG_INFO output log, keil show: warning: #47-D: incompatible redefinition of macro "NRF_LOG_MODULE_NAME" (declared at line 60 of "....\components\libraries\log\nrf_log.h")
You should include "nrf_log.h" only in C files. It's because of the trick with redefining NRF_LOG_MODULE_NAME to get module name string added to a log message. It you really want to use logger in header files (for inline functions) then you need to undef NRF_LOG_MODULE_NAME at the bottom of such header file.
You should include "nrf_log.h" only in C files. It's because of the trick with redefining NRF_LOG_MODULE_NAME to get module name string added to a log message. It you really want to use logger in header files (for inline functions) then you need to undef NRF_LOG_MODULE_NAME at the bottom of such header file.