Edge Impulse as a Zephyr module

Question/Issue:
Hi, I want to use Edge Impulse in an existing nRF Connect SDK project. I tried to follow this tutorial: Edge Impulse Zephyr Module Deployment - Edge Impulse Documentation using the NCS example application as a base application. I cloned the wake word detection tutorial project to have a trained impulse (as my project will eventually use a microphone), added it to the app folder, and added the following to my west.yml:

    - name: edge-impulse-sdk-zephyr
      description: Edge Impulse SDK for Zephyr
      path: modules/edge-impulse-sdk-zephyr
      west-commands: west/west-commands.yml
      revision: v1.93.27
      url: https://github.com/edgeimpulse/edge-impulse-sdk-zephyr

I also changed my CMakeLists.txt file to the following:

#-------------------------------------------------------------------------------
# Zephyr Example Application
#
# Copyright (c) 2021 Nordic Semiconductor ASA
# SPDX-License-Identifier: Apache-2.0

if (WIN32)
  set(CMAKE_OBJECT_PATH_MAX 350)
endif ()

cmake_minimum_required(VERSION 3.13.1)

find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})

list(APPEND ZEPHYR_EXTRA_MODULES ${CMAKE_CURRENT_SOURCE_DIR}/model)

project(app LANGUAGES C)

target_sources(app PRIVATE src/main.c)

and added these lines to my prj.conf file:

# enable c++ support
CONFIG_CPP=y
CONFIG_GLIBCXX_LIBCPP=y
CONFIG_FPU=y

# Edge Impulse SDK
CONFIG_EDGE_IMPULSE_SDK=y
CONFIG_HEAP_MEM_POOL_SIZE=8192

This should make the Edge Impulse SDK compile into the application even though no application code uses edge impulse to de inferencing yet. I tried building the basic application with west build -b custom_plank app -p always but I got the following error:

[834/842] Linking CXX static library modules\edge-impulse-sdk-zephyr\edge-impulse-sdk\cmake\zephyr\libedge-impulse-sdk.a
FAILED: [code=1] modules/edge-impulse-sdk-zephyr/edge-impulse-sdk/cmake/zephyr/libedge-impulse-sdk.a 
C:\WINDOWS\system32\cmd.exe /C "cd . && ccache C:\ncs\toolchains\dcbdc366a1\opt\bin\cmake.exe -E rm -f modules\edge-impulse-sdk-zephyr\edge-impulse-sdk\cmake\zephyr\libedge-impulse-sdk.a && ccache C:\ncs\toolchains\dcbdc366a1\opt\zephyr-sdk\gnu\arm-zephyr-eabi\bin\arm-zephyr-eabi-ar.exe qc modules\edge-impulse-sdk-zephyr\edge-impulse-sdk\cmake\zephyr\libedge-impulse-sdk.a  @CMakeFiles\edge-impulse-sdk.rsp && ccache C:\ncs\toolchains\dcbdc366a1\opt\zephyr-sdk\gnu\arm-zephyr-eabi\bin\arm-zephyr-eabi-ranlib.exe modules\edge-impulse-sdk-zephyr\edge-impulse-sdk\cmake\zephyr\libedge-impulse-sdk.a && cd ."
C:\ncs\toolchains\dcbdc366a1\opt\zephyr-sdk\gnu\arm-zephyr-eabi\bin\arm-zephyr-eabi-ar.exe: modules\edge-impulse-sdk-zephyr\edge-impulse-sdk\cmake\zephyr\libedge-impulse-sdk.a: error reading modules/edge-impulse-sdk-zephyr/edge-impulse-sdk/cmake/zephyr/CMakeFiles/edge-impulse-sdk.dir/C_/Users/nicol/Documents/xiao-ble-test/modules/edge-impulse-sdk-zephyr/edge-impulse-sdk/classifier/ei_run_classifier_c.cpp.obj: No such file or directory

What can I do to get rid of this error ?

Project ID:
1065806

Expected Outcome:
Project builds successfully.

Actual Outcome:
Project does not build

Reproducibility:

  • [x] Always
  • [ ] Sometimes
  • [ ] Rarely

Environment:

  • Platform: nrf52840 DK
  • Build Environment Details: NCS v3.4.0
  • OS Version: Windows
  • Edge Impulse Version (Firmware): 1.93.27
  • Edge Impulse CLI Version: N/A
  • Project Version: N/A