Hi folks,
I found that there is a WIFI sample application with the nRF52840 listed as supported development kit. So I tried to build that one but got strange errors regarding nrf700x. Here is the output of the build command:
west build -b nrf52840dk_nrf52840 [1/13] Building C object modules/nrf/drivers/wifi/nrf700x/CMakeFiles/..__nrf__drivers__wifi__nrf700x.dir/zephyr/src/qspi/src/rpu_hw_if.c.obj FAILED: modules/nrf/drivers/wifi/nrf700x/CMakeFiles/..__nrf__drivers__wifi__nrf700x.dir/zephyr/src/qspi/src/rpu_hw_if.c.obj ccache /home/mhummels/zephyr-sdk-0.16.0/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc -DKERNEL -DNRF52840_XXAA -DUSE_PARTITION_MANAGER=0 -D_ANSI_SOURCE -D_FORTIFY_SOURCE=1 -D__LINUX_ERRNO_EXTENSIONS__ -D__PROGRAM_START -D__ZEPHYR__=1 -I/home/mhummels/ncs/zephyr/include -I/home/mhummels/ncs/nrf/samples/wifi/scan/build/zephyr/include/generated -I/home/mhummels/ncs/zephyr/soc/arm/nordic_nrf/nrf52 -I/home/mhummels/ncs/zephyr/lib/libc/newlib/include -I/home/mhummels/ncs/zephyr/soc/arm/nordic_nrf/common/. -I/home/mhummels/ncs/zephyr/subsys/net/l2 -I/home/mhummels/ncs/nrf/include -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/inc -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/osal/utils/inc -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/osal/os_if/inc -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/osal/bus_if/bus/qspi/inc -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/osal/bus_if/bal/inc -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/osal/fw_if/umac_if/inc -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/osal/fw_load/mips/fw/inc -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/osal/hw_if/hal/inc -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/inc -I/home/mhummels/ncs/zephyr/subsys/net/ip -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/osal/hw_if/hal/inc/fw -I/home/mhummels/ncs/nrf/drivers/wifi/nrf700x/osal/fw_if/umac_if/inc/fw -I/home/mhummels/ncs/nrf/tests/include -I/home/mhummels/ncs/modules/hal/cmsis/CMSIS/Core/Include -I/home/mhummels/ncs/modules/hal/nordic/nrfx -I/home/mhummels/ncs/modules/hal/nordic/nrfx/drivers/include -I/home/mhummels/ncs/modules/hal/nordic/nrfx/mdk -I/home/mhummels/ncs/zephyr/modules/hal_nordic/nrfx/. -I/home/mhummels/ncs/modules/debug/segger/SEGGER -I/home/mhummels/ncs/modules/debug/segger/Config -I/home/mhummels/ncs/zephyr/modules/segger/. -isystem /home/mhummels/ncs/nrfxlib/crypto/nrf_cc310_platform/include -fno-strict-aliasing -Os -imacros /home/mhummels/ncs/nrf/samples/wifi/scan/build/zephyr/include/generated/autoconf.h -ffreestanding -fno-common -g -gdwarf-4 -fdiagnostics-color=always -mcpu=cortex-m4 -mthumb -mabi=aapcs -mfp16-format=ieee --sysroot=/home/mhummels/zephyr-sdk-0.16.0/arm-zephyr-eabi/arm-zephyr-eabi -imacros /home/mhummels/ncs/zephyr/include/zephyr/toolchain/zephyr_stdint.h -Wall -Wformat -Wformat-security -Wno-format-zero-length -Wno-main -Wno-pointer-sign -Wpointer-arith -Wexpansion-to-defined -Wno-unused-but-set-variable -Werror=implicit-int -fno-pic -fno-pie -fno-asynchronous-unwind-tables -fno-reorder-functions --param=min-pagesize=0 -fno-defer-pop -fmacro-prefix-map=/home/mhummels/ncs/nrf/samples/wifi/scan=CMAKE_SOURCE_DIR -fmacro-prefix-map=/home/mhummels/ncs/zephyr=ZEPHYR_BASE -fmacro-prefix-map=/home/mhummels/ncs=WEST_TOPDIR -ffunction-sections -fdata-sections -std=c99 -MD -MT modules/nrf/drivers/wifi/nrf700x/CMakeFiles/..__nrf__drivers__wifi__nrf700x.dir/zephyr/src/qspi/src/rpu_hw_if.c.obj -MF modules/nrf/drivers/wifi/nrf700x/CMakeFiles/..__nrf__drivers__wifi__nrf700x.dir/zephyr/src/qspi/src/rpu_hw_if.c.obj.d -o modules/nrf/drivers/wifi/nrf700x/CMakeFiles/..__nrf__drivers__wifi__nrf700x.dir/zephyr/src/qspi/src/rpu_hw_if.c.obj -c /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c In file included from /home/mhummels/ncs/zephyr/include/zephyr/toolchain/gcc.h:89, from /home/mhummels/ncs/zephyr/include/zephyr/toolchain.h:50, from /home/mhummels/ncs/zephyr/include/zephyr/kernel_includes.h:19, from /home/mhummels/ncs/zephyr/include/zephyr/kernel.h:17, from /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:15: /home/mhummels/ncs/zephyr/include/zephyr/device.h:83:41: error: '__device_dts_ord_DT_N_NODELABEL_nrf7002_P_host_irq_gpios_IDX_0_PH_ORD' undeclared here (not in a function) 83 | #define DEVICE_NAME_GET(dev_id) _CONCAT(__device_, dev_id) | ^~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/toolchain/common.h:132:26: note: in definition of macro '_DO_CONCAT' 132 | #define _DO_CONCAT(x, y) x ## y | ^ /home/mhummels/ncs/zephyr/include/zephyr/device.h:83:33: note: in expansion of macro '_CONCAT' 83 | #define DEVICE_NAME_GET(dev_id) _CONCAT(__device_, dev_id) | ^~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/device.h:209:37: note: in expansion of macro 'DEVICE_NAME_GET' 209 | #define DEVICE_DT_NAME_GET(node_id) DEVICE_NAME_GET(Z_DEVICE_DT_DEV_ID(node_id)) | ^~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/device.h:226:34: note: in expansion of macro 'DEVICE_DT_NAME_GET' 226 | #define DEVICE_DT_GET(node_id) (&DEVICE_DT_NAME_GET(node_id)) | ^~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:316:25: note: in expansion of macro 'DEVICE_DT_GET' 316 | .port = DEVICE_DT_GET(DT_GPIO_CTLR_BY_IDX(node_id, prop, idx)),\ | ^~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:352:9: note: in expansion of macro 'GPIO_DT_SPEC_GET_BY_IDX' 352 | GPIO_DT_SPEC_GET_BY_IDX(node_id, prop, 0) | ^~~~~~~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:30:1: note: in expansion of macro 'GPIO_DT_SPEC_GET' 30 | GPIO_DT_SPEC_GET(NRF7002_NODE, host_irq_gpios); | ^~~~~~~~~~~~~~~~ In file included from /home/mhummels/ncs/zephyr/include/zephyr/arch/arm/aarch32/arch.h:20, from /home/mhummels/ncs/zephyr/include/zephyr/arch/cpu.h:19, from /home/mhummels/ncs/zephyr/include/zephyr/kernel_includes.h:33: /home/mhummels/ncs/zephyr/include/zephyr/devicetree.h:190:36: error: 'DT_N_NODELABEL_nrf7002_P_host_irq_gpios_IDX_0_VAL_pin' undeclared here (not in a function) 190 | #define DT_NODELABEL(label) DT_CAT(DT_N_NODELABEL_, label) | ^~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree.h:3912:9: note: in definition of macro 'DT_CAT7' 3912 | a1 ## a2 ## a3 ## a4 ## a5 ## a6 ## a7 | ^~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree/gpio.h:164:9: note: in expansion of macro 'DT_PHA_BY_IDX' 164 | DT_PHA_BY_IDX(node_id, gpio_pha, idx, pin) | ^~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:317:24: note: in expansion of macro 'DT_GPIO_PIN_BY_IDX' 317 | .pin = DT_GPIO_PIN_BY_IDX(node_id, prop, idx), \ | ^~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:352:9: note: in expansion of macro 'GPIO_DT_SPEC_GET_BY_IDX' 352 | GPIO_DT_SPEC_GET_BY_IDX(node_id, prop, 0) | ^~~~~~~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:30:1: note: in expansion of macro 'GPIO_DT_SPEC_GET' 30 | GPIO_DT_SPEC_GET(NRF7002_NODE, host_irq_gpios); | ^~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree.h:190:29: note: in expansion of macro 'DT_CAT' 190 | #define DT_NODELABEL(label) DT_CAT(DT_N_NODELABEL_, label) | ^~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:27:22: note: in expansion of macro 'DT_NODELABEL' 27 | #define NRF7002_NODE DT_NODELABEL(nrf7002) | ^~~~~~~~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:30:18: note: in expansion of macro 'NRF7002_NODE' 30 | GPIO_DT_SPEC_GET(NRF7002_NODE, host_irq_gpios); | ^~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/device.h:83:41: error: '__device_dts_ord_DT_N_NODELABEL_nrf7002_P_iovdd_ctrl_gpios_IDX_0_PH_ORD' undeclared here (not in a function) 83 | #define DEVICE_NAME_GET(dev_id) _CONCAT(__device_, dev_id) | ^~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/toolchain/common.h:132:26: note: in definition of macro '_DO_CONCAT' 132 | #define _DO_CONCAT(x, y) x ## y | ^ /home/mhummels/ncs/zephyr/include/zephyr/device.h:83:33: note: in expansion of macro '_CONCAT' 83 | #define DEVICE_NAME_GET(dev_id) _CONCAT(__device_, dev_id) | ^~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/device.h:209:37: note: in expansion of macro 'DEVICE_NAME_GET' 209 | #define DEVICE_DT_NAME_GET(node_id) DEVICE_NAME_GET(Z_DEVICE_DT_DEV_ID(node_id)) | ^~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/device.h:226:34: note: in expansion of macro 'DEVICE_DT_NAME_GET' 226 | #define DEVICE_DT_GET(node_id) (&DEVICE_DT_NAME_GET(node_id)) | ^~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:316:25: note: in expansion of macro 'DEVICE_DT_GET' 316 | .port = DEVICE_DT_GET(DT_GPIO_CTLR_BY_IDX(node_id, prop, idx)),\ | ^~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:352:9: note: in expansion of macro 'GPIO_DT_SPEC_GET_BY_IDX' 352 | GPIO_DT_SPEC_GET_BY_IDX(node_id, prop, 0) | ^~~~~~~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:33:1: note: in expansion of macro 'GPIO_DT_SPEC_GET' 33 | GPIO_DT_SPEC_GET(NRF7002_NODE, iovdd_ctrl_gpios); | ^~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree.h:190:36: error: 'DT_N_NODELABEL_nrf7002_P_iovdd_ctrl_gpios_IDX_0_VAL_pin' undeclared here (not in a function) 190 | #define DT_NODELABEL(label) DT_CAT(DT_N_NODELABEL_, label) | ^~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree.h:3912:9: note: in definition of macro 'DT_CAT7' 3912 | a1 ## a2 ## a3 ## a4 ## a5 ## a6 ## a7 | ^~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree/gpio.h:164:9: note: in expansion of macro 'DT_PHA_BY_IDX' 164 | DT_PHA_BY_IDX(node_id, gpio_pha, idx, pin) | ^~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:317:24: note: in expansion of macro 'DT_GPIO_PIN_BY_IDX' 317 | .pin = DT_GPIO_PIN_BY_IDX(node_id, prop, idx), \ | ^~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:352:9: note: in expansion of macro 'GPIO_DT_SPEC_GET_BY_IDX' 352 | GPIO_DT_SPEC_GET_BY_IDX(node_id, prop, 0) | ^~~~~~~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:33:1: note: in expansion of macro 'GPIO_DT_SPEC_GET' 33 | GPIO_DT_SPEC_GET(NRF7002_NODE, iovdd_ctrl_gpios); | ^~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree.h:190:29: note: in expansion of macro 'DT_CAT' 190 | #define DT_NODELABEL(label) DT_CAT(DT_N_NODELABEL_, label) | ^~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:27:22: note: in expansion of macro 'DT_NODELABEL' 27 | #define NRF7002_NODE DT_NODELABEL(nrf7002) | ^~~~~~~~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:33:18: note: in expansion of macro 'NRF7002_NODE' 33 | GPIO_DT_SPEC_GET(NRF7002_NODE, iovdd_ctrl_gpios); | ^~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/device.h:83:41: error: '__device_dts_ord_DT_N_NODELABEL_nrf7002_P_bucken_gpios_IDX_0_PH_ORD' undeclared here (not in a function) 83 | #define DEVICE_NAME_GET(dev_id) _CONCAT(__device_, dev_id) | ^~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/toolchain/common.h:132:26: note: in definition of macro '_DO_CONCAT' 132 | #define _DO_CONCAT(x, y) x ## y | ^ /home/mhummels/ncs/zephyr/include/zephyr/device.h:83:33: note: in expansion of macro '_CONCAT' 83 | #define DEVICE_NAME_GET(dev_id) _CONCAT(__device_, dev_id) | ^~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/device.h:209:37: note: in expansion of macro 'DEVICE_NAME_GET' 209 | #define DEVICE_DT_NAME_GET(node_id) DEVICE_NAME_GET(Z_DEVICE_DT_DEV_ID(node_id)) | ^~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/device.h:226:34: note: in expansion of macro 'DEVICE_DT_NAME_GET' 226 | #define DEVICE_DT_GET(node_id) (&DEVICE_DT_NAME_GET(node_id)) | ^~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:316:25: note: in expansion of macro 'DEVICE_DT_GET' 316 | .port = DEVICE_DT_GET(DT_GPIO_CTLR_BY_IDX(node_id, prop, idx)),\ | ^~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:352:9: note: in expansion of macro 'GPIO_DT_SPEC_GET_BY_IDX' 352 | GPIO_DT_SPEC_GET_BY_IDX(node_id, prop, 0) | ^~~~~~~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:36:1: note: in expansion of macro 'GPIO_DT_SPEC_GET' 36 | GPIO_DT_SPEC_GET(NRF7002_NODE, bucken_gpios); | ^~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree.h:190:36: error: 'DT_N_NODELABEL_nrf7002_P_bucken_gpios_IDX_0_VAL_pin' undeclared here (not in a function) 190 | #define DT_NODELABEL(label) DT_CAT(DT_N_NODELABEL_, label) | ^~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree.h:3912:9: note: in definition of macro 'DT_CAT7' 3912 | a1 ## a2 ## a3 ## a4 ## a5 ## a6 ## a7 | ^~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree/gpio.h:164:9: note: in expansion of macro 'DT_PHA_BY_IDX' 164 | DT_PHA_BY_IDX(node_id, gpio_pha, idx, pin) | ^~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:317:24: note: in expansion of macro 'DT_GPIO_PIN_BY_IDX' 317 | .pin = DT_GPIO_PIN_BY_IDX(node_id, prop, idx), \ | ^~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/drivers/gpio.h:352:9: note: in expansion of macro 'GPIO_DT_SPEC_GET_BY_IDX' 352 | GPIO_DT_SPEC_GET_BY_IDX(node_id, prop, 0) | ^~~~~~~~~~~~~~~~~~~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:36:1: note: in expansion of macro 'GPIO_DT_SPEC_GET' 36 | GPIO_DT_SPEC_GET(NRF7002_NODE, bucken_gpios); | ^~~~~~~~~~~~~~~~ /home/mhummels/ncs/zephyr/include/zephyr/devicetree.h:190:29: note: in expansion of macro 'DT_CAT' 190 | #define DT_NODELABEL(label) DT_CAT(DT_N_NODELABEL_, label) | ^~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:27:22: note: in expansion of macro 'DT_NODELABEL' 27 | #define NRF7002_NODE DT_NODELABEL(nrf7002) | ^~~~~~~~~~~~ /home/mhummels/ncs/nrf/drivers/wifi/nrf700x/zephyr/src/qspi/src/rpu_hw_if.c:36:18: note: in expansion of macro 'NRF7002_NODE' 36 | GPIO_DT_SPEC_GET(NRF7002_NODE, bucken_gpios); | ^~~~~~~~~~~~ ninja: build stopped: subcommand failed. FATAL ERROR: command exited with status 1: /usr/bin/cmake --build /home/mhummels/ncs/nrf/samples/wifi/scan/build
If I try to build a simple example like the hardware ID one, it builds just fine.
I am a little confused why there is the nrf700x mentioned. Do I need to connect the companion chip to the devkit to be able to run this sample application? Where can I find the documentation on doing so? And even if I would have done so, why is the sample application code not building?
Thank you very much.
Best Regards,
M. Hummels