I'm using arm-none-eabi-gcc 7.2.1 with nRF5_SDK_15.0.0_a53641a
with soft device s140_nrf52_6.0.0_softdevice.hex
I'm trying to modify one of the bluetooth examples to add a call to `ble_radio_notification_init`
I've been adding the c files to `SRC_FILES` and the directories for the headers into `INC_FOLDERS` in the makefile as I get errors.
I turned off treating warnings as errors temporarily, just so I could get through the process of making it compile again.
Issue A: The issue which I can't solve:
Compiling file: nrf_nvic.c
../../../../../../components/drivers_nrf/nrf_soc_nosd/nrf_nvic.c: In function 'sd_nvic_EnableIRQ':
../../../../../../components/drivers_nrf/nrf_soc_nosd/nrf_nvic.c:49:12: error: 'NRF_SUCCESS' undeclared (first use in this function); did you
mean 'EXIT_SUCCESS'?
return NRF_SUCCESS;
NRF_SUCCESS is defined in `nrf_error.h` files
`nrf_nvic.c` includes `nrf_error.h`. There are two copies of `nrf_error.h` that might be included,
./components/drivers_nrf/nrf_soc_nosd/nrf_error.h
./components/softdevice/s140/headers/nrf_error.h
I'm not sure which one is getting included, but they both define `NRF_SUCCESS` so it shouldn't matter.
How should I be trying to fix this?
Issue B: The issue I can solve by modifying the SDK:
Compiling file: ble_radio_notification.c
../../../../../../components/ble/ble_radio_notification/ble_radio_notification.c: In function 'ble_radio_notification_init':
../../../../../../components/ble/ble_radio_notification/ble_radio_notification.c:67:16: warning: implicit declaration of function 'sd_nvic_Cle
arPendingIRQ'; did you mean 'NVIC_ClearPendingIRQ'? [-Wimplicit-function-declaration]
err_code = sd_nvic_ClearPendingIRQ(SWI1_IRQn);
^~~~~~~~~~~~~~~~~~~~~~~
NVIC_ClearPendingIRQ
If I add `#include "nrf_nvic.h"` to `ble_radio_nofification.h` that (and a few similar) error goes away.
Is this a bug I should be reporting or am I just doing something wrong?