Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs
This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Eclipse setup with nRF5_SDK_15.0.0_a53641a

Hi all

I've already setup my Eclipse environment as described in Development with GCC and Eclipse.

Now I want to use the SPI libraries for my example.
But I got the first problem by setting up an instance like this:

static const nrf_drv_spi_t m_spi_master_0 = NRF_DRV_SPI_INSTANCE(0);

Output:

make VERBOSE=1 all
Compiling file: main.c
'C:/Program Files/GNU Tools ARM Embedded/7 2017-q4-major/bin/arm-none-eabi-gcc' -std=c99 -MP -MD -c -o _build/nrf52832_xxaa/main.c.o ./main.c -O0 -g3 -DBOARD_PCA10040 -DCONFIG_GPIO_AS_PINRESET -DFLOAT_ABI_HARD -DNRF52 -DNRF52832_XXAA -DNRF52_PAN_74 -mcpu=cortex-m4 -mthumb -mabi=aapcs -Wall -Werror -mfloat-abi=hard -mfpu=fpv4-sp-d16 -ffunction-sections -fdata-sections -fno-strict-aliasing -fno-builtin -fshort-enums -D__HEAP_SIZE=8192 -D__STACK_SIZE=8192 -I../Nordic_NRF5_SDK//components -I../Nordic_NRF5_SDK//components/libraries/experimental_memobj -I../Nordic_NRF5_SDK//components/libraries/experimental_section_vars -I../Nordic_NRF5_SDK//modules/nrfx/mdk -I../Nordic_NRF5_SDK//modules/nrfx/hal -I../Nordic_NRF5_SDK//components/libraries/balloc -I../Nordic_NRF5_SDK//components/libraries/experimental_log -I../Nordic_NRF5_SDK//components/libraries/experimental_log/src -I../Nordic_NRF5_SDK//components/libraries/delay -I../Nordic_NRF5_SDK//integration/nrfx -I../Nordic_NRF5_SDK//components/libraries/bsp -I../Nordic_NRF5_SDK//components/drivers_nrf/nrf_soc_nosd -I../Nordic_NRF5_SDK//config/nrf52832/config -I./lib/inc -I./lib/src -I../Nordic_NRF5_SDK//components/libraries/strerror -I../Nordic_NRF5_SDK//components/boards -I../Nordic_NRF5_SDK//components/toolchain/cmsis/include -I../Nordic_NRF5_SDK//modules/nrfx -I. -I../Nordic_NRF5_SDK//components/libraries/util -I../Nordic_NRF5_SDK//integration/nrfx/legacy -I../Nordic_NRF5_SDK//modules/nrfx/drivers/include -I../Nordic_NRF5_SDK//components/libraries/spi_mngr -I../Nordic_NRF5_SDK//components/libraries/queue -I../Nordic_NRF5_SDK//components/libraries/atomic/ -I../Nordic_NRF5_SDK//components/libraries/timer/ -I../Nordic_NRF5_SDK//components/libraries/pwr_mgmt/ -I../Nordic_NRF5_SDK//components/libraries/gfx -I../Nordic_NRF5_SDK//external/thedotfactory_fonts -I../Nordic_NRF5_SDK//components/libraries/button
In file included from ../Nordic_NRF5_SDK//components/libraries/spi_mngr/nrf_spi_mngr.h:44:0,
from ./lib/inc/cap1188_touchsense.h:15,
from ./main.c:16:
../Nordic_NRF5_SDK//integration/nrfx/legacy/nrf_drv_spi.h:120:37: error: 'NRF_DRV_SPI_INSTANCE_0' undeclared here (not in a function); did you mean 'NRF_DRV_SPI_INSTANCE_'?
#define NRF_DRV_SPI_INSTANCE_(id) NRF_DRV_SPI_INSTANCE_ ## id
^
../Nordic_NRF5_SDK//integration/nrfx/legacy/nrf_drv_spi.h:119:37: note: in expansion of macro 'NRF_DRV_SPI_INSTANCE_'
#define NRF_DRV_SPI_INSTANCE(id) NRF_DRV_SPI_INSTANCE_(id)
^~~~~~~~~~~~~~~~~~~~~
./lib/inc/cap1188_touchsense.h:35:45: note: in expansion of macro 'NRF_DRV_SPI_INSTANCE'
static const nrf_drv_spi_t m_spi_master_0 = NRF_DRV_SPI_INSTANCE(0); // NRF_DRV_SPI_INSTANCE(0);
^~~~~~~~~~~~~~~~~~~~
make: *** [../Nordic_NRF5_SDK//components/toolchain/gcc/Makefile.common:272: _build/nrf52832_xxaa/main.c.o] Error 1


Do you know the reason?

Best regards
Marco

Parents Reply Children
No Data
Related