I’ve been working on a project using the Adafruit Feather 32u4 and outgrew it.
So I decided to switch the project over to the Adafruit Feather M0.
Unfortunately, the build then failed with
atal error: SPI.h: No such file or directory
So I added SPI to lib_deps in platformio.ini.
The build now fails with
fatal error: Adafruit_ZeroDMA.h: No such file or directory
Adding Adafruit_ZeroDMA to lib_deps results in
Warning! Could not find the package with 'Adafruit_ZeroDMA' requirements for your system 'darwin_x86_64'
First, what do I need to add to lib_deps to build for the Feather M0?
Second, why does it think that my platform is darwin_x86_64?
Are you running on a Mac? Darwin is Mac OS (kernel).
What’s your full
That’s wrong, per
the library name is as seen above.
lib_deps should look something like
adafruit/Adafruit Zero DMA Library @ ^1.0.8
First, thanks for the fast reply.
When you wrote
lib_deps = Adafruit_ZeroDMA it tries to find this ‘package’ (a library is also a package in PlatformIO terms) but couldn’t find it, so in the error message it outputted the platform you’re on (e.g. Windows x86_64, Darwin, Linux, …) as side information. Packages can also be e.g. compilers / toolchains, and then the packages have to declare the correct platform, since you can’t run a Windows binary on Mac fo example. This is unimportant for libraries, which don’t depend on the host computer’s platform.
Right at the top bar there’s
the library registry. Also PIO gives you a direct search link after the compiler error message…
…which nicely leads you to the library search page…
…which directly feeds you how to install the library.
Got it. Thanks very much.
Searching for the missing header did, indeed, show me the correct package.