Problems build hci_lpuart for thingy91 sdk2.9.0

I am trying to compile hci_lpuart for thingy91_nrf52840, but I have these issue.

hci_lpuart:

/opt/nordic/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr/serial_adapter.c
In file included from /opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/sys/util_macro.h:34,
from /opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/irq_multilevel.h:16,
from /opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/devicetree.h:20,
from /opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/device.h:12,
from /opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/drivers/uart.h:28,
from /opt/nordic/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr/serial_adapter.c:18:
/opt/nordic/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr/serial_adapter.c: In function 'boot_uart_fifo_init':
/opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/sys/util.h:97:55: error: size of unnamed array is negative
97 | #define ZERO_OR_COMPILE_ERROR(cond) ((int) sizeof(char[1 - 2 * !(cond)]) - 1)
| ^
/opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/sys/util_internal.h:72:26: note: in definition of macro '__DEBRACKET'
72 | #define __DEBRACKET(...) __VA_ARGS__
| ^~~~~~~~~~~
/opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/sys/util_internal.h:64:9: note: in expansion of macro '__GET_ARG2_DEBRACKET'
64 | __GET_ARG2_DEBRACKET(one_or_two_args _if_code, _else_code)
| ^~~~~~~~~~~~~~~~~~~~
/opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/sys/util_internal.h:59:9: note: in expansion of macro '__COND_CODE'
59 | __COND_CODE(_XXXX##_flag, _if_1_code, _else_code)
| ^~~~~~~~~~~
/opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/sys/util_macro.h:180:9: note: in expansion of macro 'Z_COND_CODE_1'
180 | Z_COND_CODE_1(_flag, _if_1_code, _else_code)
| ^~~~~~~~~~~~~
/opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/device.h:297:9: note: in expansion of macro 'COND_CODE_1'
297 | COND_CODE_1(DT_HAS_COMPAT_STATUS_OKAY(compat), \
| ^~~~~~~~~~~
/opt/nordic/ncs/v2.9.0/zephyr/include/zephyr/device.h:299:22: note: in expansion of macro 'ZERO_OR_COMPILE_ERROR'
299 | (ZERO_OR_COMPILE_ERROR(0)))
| ^~~~~~~~~~~~~~~~~~~~~
/opt/nordic/ncs/v2.9.0/bootloader/mcuboot/boot/zephyr/serial_adapter.c:217:20: note: in expansion of macro 'DEVICE_DT_GET_ONE'
217 | uart_dev = DEVICE_DT_GET_ONE(zephyr_cdc_acm_uart);
| ^~~~~~~~~~~~~~~~~
[260/325] Building C object modules/hal_nordic/nrfx/CMakeFiles/modules__hal_nordic__nrfx.dir/opt/nordic/ncs/v2.9.0/modules/hal/nordic/nrfx/helpers/nrfx_ram_ctrl.c.obj
ninja: build stopped: subcommand failed.
[10/20] No configure step for 'hci_lpuart'
FAILED: _sysbuild/sysbuild/images/bootloader/mcuboot-prefix/src/mcuboot-stamp/mcuboot-build /opt/nordic/ncs/v2.9.0/nrf/samples/bluetooth/hci_lpuart/build/_sysbuild/sysbuild/images/bootloader/mcuboot-prefix/src/mcuboot-stamp/mcuboot-build
cd /opt/nordic/ncs/v2.9.0/nrf/samples/bluetooth/hci_lpuart/build/mcuboot && /opt/nordic/ncs/toolchains/b8efef2ad5/Cellar/cmake/3.21.0/bin/cmake --build .
ninja: build stopped: subcommand failed.
FATAL ERROR: command exited with status 1: /opt/nordic/ncs/toolchains/b8efef2ad5/bin/cmake --build /opt/nordic/ncs/v2.9.0/nrf/samples/bluetooth/hci_lpuart/build

Any ideas on how to solve this? I'd really appreciate it.

And if you have any examples for sending data from an nRF7002, that would help.

Parents Reply Children
  • Yes, I flashed HCI to the nrf52840. You can then compile lte_ble_gateway with SDK 3.0.0.

    I am using examples lte_ble_gateway and hci_lpuart SDK 3.0.0

    But now I have this error.


    [00:00:00.227,783] <wrn> lpuart: req pin low when expected high
    [00:00:00.227,935] <err> lpuart: Empty receiver state:4
    *** Booting nRF Connect SDK v3.0.0-3bfc46578e42 ***
    *** Using Zephyr OS v4.0.99-a0e545cb437a ***
    [00:00:00.230,804] <inf> lte_ble_gw: LTE Sensor Gateway sample started
    [00:00:00.230,926] <inf> lte_ble_gw: Initializing Bluetooth..
    [00:00:00.476,013] <inf> lte_ble_gw: Establishing LTE link (this may take some time) ...
    [00:00:02.258,636] <wrn> lpuart: req pin low when expected high
    [00:00:02.258,758] <err> lpuart: Empty receiver state:4
    [00:00:04.339,965] <wrn> lpuart: req pin low when expected high
    [00:00:04.340,118] <err> lpuart: Empty receiver state:4
    [00:00:06.381,744] <wrn> lpuart: req pin low when expected high
    [00:00:06.381,896] <err> lpuart: Empty receiver state:4
    [00:00:08.398,681] <wrn> lpuart: req pin low when expected high
    [00:00:08.398,803] <err> lpuart: Empty receiver state:4
    ASSERTION FAIL [success] @ WEST_TOPDIR/zephyr/subsys/bluetooth/host/hci_core.c:432
    command opcode 0x0c03 timeout
    [00:00:10.241,455] <err> os: r0/a1: 0x00000003 r1/a2: 0x00000000 r2/a3: 0x00000002
    [00:00:10.241,485] <err> os: r3/a4: 0x00000003 r12/ip: 0x20018b28 r14/lr: 0x0002039f
    [00:00:10.241,485] <err> os: xpsr: 0x01000000
    [00:00:10.241,516] <err> os: Faulting instruction address (r15/pc): 0x000203ac
    [00:00:10.241,546] <err> os: >>> ZEPHYR FATAL ERROR 3: Kernel oops on CPU 0
    [00:00:10.241,577] <err> os: Current thread: 0x2000f6e8 (unknown)
    [00:00:10.456,787] <err> os: Halting system

Related