Hey there!
I'm just a beginner and was working on a simple UART project in Segger Embedded Studio. The codes were working fine until I started encountering multiple errors:
Building ‘saadc_pca10056’ from solution ‘saadc_pca10056’ in configuration ‘Debug’
Compiling ‘nrf_log_backend_rtt.c’
implicit declaration of function 'SEGGER_RTT_Init' [-Wimplicit-function-declaration]
implicit declaration of function 'SEGGER_RTT_WriteNoLock' [-Wimplicit-function-declaration]
Compiling ‘nrf_log_backend_serial.c’
Compiling ‘nrf_log_backend_uart.c’
Compiling ‘nrf_log_default_backends.c’
Compiling ‘nrf_log_frontend.c’
"NRF_LOG_MODULE_NAME" redefined
nrf_log.h
nrf_log_frontend.c
this is the location of the previous definition
"NRF_LOG_LEVEL" redefined
nrf_log_frontend.c
this is the location of the previous definition
nrf_log.h
nrf_log_frontend.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_FLUSH'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_WARNING'
in expansion of macro 'NRF_LOG_WARNING'
Compiling ‘nrf_log_str_formatter.c’
Compiling ‘boards.c’
Compiling ‘app_error_handler_gcc.c’
Compiling ‘app_error_weak.c’
"NRF_LOG_MODULE_NAME" redefined
nrf_log.h
app_error_weak.c
this is the location of the previous definition
nrf_log.h
app_error_weak.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_FLUSH'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_ERROR'
in expansion of macro 'NRF_LOG_ERROR'
Compiling ‘nrf_atomic.c’
Compiling ‘nrf_balloc.c’
Compiling ‘nrf_fprintf.c’
Compiling ‘nrf_fprintf_format.c’
Compiling ‘nrf_memobj.c’
Compiling ‘nrf_pwr_mgmt.c’
nrf_log.h
nrf_pwr_mgmt.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_FLUSH'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_INFO'
in expansion of macro 'NRF_LOG_INFO'
Compiling ‘nrf_ringbuf.c’
Compiling ‘nrf_section_iter.c’
Compiling ‘nrf_strerror.c’
Compiling ‘nrf_drv_ppi.c’
Compiling ‘nrf_drv_uart.c’
Compiling ‘nrfx_ppi.c’
nrf_log.h
nrfx_log.h
nrfx_ppi.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_DEBUG'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_INFO'
in expansion of macro 'NRF_LOG_INFO'
in expansion of macro 'TEST_MACRO_INFO'
in expansion of macro 'NRFX_LOG_INFO'
Compiling ‘nrfx_prs.c’
nrf_log.h
nrfx_log.h
nrfx_prs.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_DEBUG'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_WARNING'
in expansion of macro 'NRF_LOG_WARNING'
in expansion of macro 'NRFX_LOG_WARNING'
in expansion of macro 'LOG_FUNCTION_EXIT'
Compiling ‘nrfx_saadc.c’
nrf_log.h
nrfx_log.h
nrfx_saadc.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_DEBUG'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_DEBUG'
in expansion of macro 'NRF_LOG_DEBUG'
in expansion of macro 'NRFX_LOG_DEBUG'
Compiling ‘nrfx_timer.c’
nrf_log.h
nrfx_log.h
nrfx_timer.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_DEBUG'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_WARNING'
in expansion of macro 'NRF_LOG_WARNING'
in expansion of macro 'NRFX_LOG_WARNING'
Compiling ‘nrfx_uart.c’
nrf_log.h
nrfx_log.h
nrfx_uart.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_DEBUG'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_WARNING'
in expansion of macro 'NRF_LOG_WARNING'
in expansion of macro 'NRFX_LOG_WARNING'
Compiling ‘nrfx_uarte.c’
nrf_log.h
nrfx_log.h
nrfx_uarte.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_DEBUG'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_WARNING'
in expansion of macro 'NRF_LOG_WARNING'
in expansion of macro 'NRFX_LOG_WARNING'
Compiling ‘nrfx_gpiote.c’
nrf_log.h
nrfx_log.h
nrfx_gpiote.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_DEBUG'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_WARNING'
in expansion of macro 'NRF_LOG_WARNING'
in expansion of macro 'NRFX_LOG_WARNING'
Compiling ‘main.c’
nrf_log.h
main.c
implicit declaration of function 'NRF_LOG_INTERNAL_MODULE'; did you mean 'NRF_LOG_INTERNAL_FLUSH'? [-Wimplicit-function-declaration]
in expansion of macro 'NRF_LOG_INTERNAL_INFO'
in expansion of macro 'NRF_LOG_INFO'
passing argument 3 of 'nrfx_timer_init' from incompatible pointer type [-Wincompatible-pointer-types]
nrf_drv_timer.h
main.c
expected 'nrfx_timer_event_handler_t' {aka 'void (*)(nrf_timer_event_t, void *)'} but argument is of type 'void (*)()'
passing argument 2 of 'nrf_drv_saadc_init' from incompatible pointer type [-Wincompatible-pointer-types]
main.c
expected 'nrfx_saadc_event_handler_t' {aka 'void (*)(const nrfx_saadc_evt_t *)'} but argument is of type 'void (*)(const nrfx_saadc_evt_t *, const nrfx_saadc_config_t *)'
app_util_platform.h
nrfx_glue.h
nrfx.h
nrfx_saadc.h
nrf_drv_saadc.h
main.c
passing argument 2 of 'nrfx_saadc_init' from incompatible pointer type [-Wincompatible-pointer-types]
in definition of macro 'APP_ERROR_CHECK'
nrf_drv_saadc.h
main.c
expected 'nrfx_saadc_event_handler_t' {aka 'void (*)(const nrfx_saadc_evt_t *)'} but argument is of type 'void (*)(const nrfx_saadc_evt_t *, const nrfx_saadc_config_t *)'
Compiling ‘SEGGER_RTT.c’
Compiling ‘SEGGER_RTT_Syscalls_SES.c’
Compiling ‘SEGGER_RTT_printf.c’
Linking saadc_pca10056.elf
Output/Debug/Obj/saadc_pca10056/nrf_log_frontend.o: in function `nrf_log_frontend_dequeue':
undefined reference to `NRF_LOG_INTERNAL_MODULE'
Output/Debug/Obj/saadc_pca10056/app_error_weak.o: in function `app_error_fault_handler':
undefined reference to `NRF_LOG_INTERNAL_MODULE'
C:\Users\ZENLAB\Documents\6 - nRF5_SDK_15.2.0_9412b96_latest\components\libraries\util/app_error_weak.c:94: undefined reference to `NRF_LOG_INTERNAL_MODULE'
C:\Users\ZENLAB\Documents\6 - nRF5_SDK_15.2.0_9412b96_latest\components\libraries\util/app_error_weak.c:100: undefined reference to `NRF_LOG_INTERNAL_MODULE'
C:\Users\ZENLAB\Documents\6 - nRF5_SDK_15.2.0_9412b96_latest\components\libraries\util/app_error_weak.c:104: undefined reference to `NRF_LOG_INTERNAL_MODULE'
Output/Debug/Obj/saadc_pca10056/nrf_pwr_mgmt.o:C:\Users\ZENLAB\Documents\6 - nRF5_SDK_15.2.0_9412b96_latest\components\libraries\pwr_mgmt/nrf_pwr_mgmt.c:329: more undefined references to `NRF_LOG_INTERNAL_MODULE' follow
Build failed
This was confusing as it started appearing in projects that did work perfectly fine before. I included all the path and added the required source files.
A fast response would be highly appreciated. Thanks.