Configuring Spresense SDK in EI Firmware

I am trying to figure out how to configure the Spresense SDK in the EI Firmware. I want to be able to configure the different features/devices as described here: Spresense SDK Getting Started Guide (CLI)

I want to make sure the LTE Board support is enabled.

I followed the directions here:

but I get this error when I try to build the firmware (it compiled fine prior):

In file included from **main.cpp:1**:

**spresense-exported-sdk/nuttx/include/stdio.h:28:10:** **fatal error:** nuttx/config.h: No such file or directory

28 | #include **<nuttx/config.h>**

I have also tried copying in the full Spresense SDK instead of the exported version, but that doesn’t work either.

What are the proper steps for configuring the Spresense SDK? Should I instead try to bring an exported EI C++ Library into a Spresense SDK created App?

Hi Luke,

Our pre-made example firmware aren’t really well suited towards working with the 4G LTE kit and the like, even if you enable this you won’t have the proper code anywhere in our firmware to interface through the 4G LTE baseboard.

Specifically for the issue you are seeing, those instructions in our repo will generate an older version of the Spresense SDK, which may not be properly compiling with the latest version of the spresense tooling on GH. If you did build the latest and then try to export, there’s likely changes in our firmware to work with the bleeding edge spresense SDK version.

What will work best for a custom FW project using both spresense and EI is to either use the Arduino SDK provided by spresense, with any arduino library export from Edge Impulse. This has been used for a 4g-lte wildlife camera project we did with Sony earlier this year:

You should be able to build CPP examples with spresense as well - using their latest export with our standalone repo:

However based on the error I think you might run into the same problem. Could you try to replicate the issue when building the latest SDK (following Sony’s instructions followed by make exportsdk and then using it with the standalone repo below:

Thanks @daschwar That got a lot further… I combined the EI Standalone Inference Example + my EI C++ Library + an export of the current Spresense SDK. It made it all the way to the end, but then barfed:

"arm-none-eabi-ld" --entry=__start -nostartfiles -nodefaultlibs -Tspresense-exported-sdk/nuttx/scripts/ramconfig.ld --gc-sections -Map=build/ -o build/firmware.elf --start-group -u spresense_main -u board_timerhook build/libapp.a spresense-exported-sdk/nuttx/libs/libapps.a spresense-exported-sdk/nuttx/libs/libnuttx.a "/Users/luke/spresenseenv/usr/bin/../lib/gcc/arm-none-eabi/9.2.1/thumb/v7e-m+fp/hard/libgcc.a" "/Users/luke/spresenseenv/usr/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/lib/thumb/v7e-m+fp/hard/libm.a" "/Users/luke/spresenseenv/usr/bin/../lib/gcc/arm-none-eabi/9.2.1/../../../../arm-none-eabi/lib/thumb/v7e-m+fp/hard/libstdc++.a" --end-group -Lbuild --print-memory-usage

arm-none-eabi-ld: cannot find spresense-exported-sdk/nuttx/libs/libnuttx.a: No such file or directory

make: *** [build/firmware.elf] Error 1

I will take a look at the Makefile that Spresense generates for its examples and see how they are linking in Nuttx.

For now though, I will pivot over to Arduino. I am seeing worse classification latency there (~1200ms vs 500ms), but it will be good enough for a proof of concept.

I will let you know if I figure anything out.