PlatformIO Community

Adafruit CLUE board (adafruit_clue_nrf52840)

I am trying to use the CLUE board from Adafruit. A simple HelloWorld code (Serial.println(“HelloWorld”)) worked fine, however, when I added deps adafruit/Adafruit Arcada Library@^2.5.0 and adafruit/Adafruit Sensor Lab @ ^0.4.2, the compiler complained that it can’t find Adafruit_GFX.h which was included from Arcada. I looked in the .pio/libdeps all the dependencies of Arcada and Sensor Lab were there including Adafruit_GFX

Anyone know why?

[env:adafruit_clue_nrf52840]
platform = nordicnrf52
board = adafruit_clue_nrf52840
framework = arduino
lib_deps = adafruit/Adafruit Arcada Library@^2.5.0
                 adafruit/Adafruit Sensor Lab @ ^0.4.2

Below are the error messages

- toolchain-gccarmnoneeabi 1.70201.0 (7.2.1)
LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 29 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <Adafruit Arcada Library> 2.5.0
|-- <Adafruit Sensor Lab> 0.4.2
Building in release mode
Compiling .pio/build/adafruit_clue_nrf52840/src/main.cpp.o
Compiling .pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada.cpp.o
Compiling .pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada_Alerts.cpp.o
Compiling .pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada_Config.cpp.o
In file included from .pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada.cpp:1:0:
.pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada.h:9:10: fatal error: Adafruit_GFX.h: No such file or directory

**********************************************************************
* Looking for Adafruit_GFX.h dependency? Check our library registry!
*
* CLI  > platformio lib search "header:Adafruit_GFX.h"
* Web  > https://platformio.org/lib/search?query=header:Adafruit_GFX.h
*
**********************************************************************

 #include <Adafruit_GFX.h>
          ^~~~~~~~~~~~~~~~
compilation terminated.
*** [.pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada.cpp.o] Error 1
In file included from .pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada_Alerts.cpp:1:0:
.pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada.h:9:10: fatal error: Adafruit_GFX.h: No such file or directory

**********************************************************************
* Looking for Adafruit_GFX.h dependency? Check our library registry!
*
* CLI  > platformio lib search "header:Adafruit_GFX.h"
* Web  > https://platformio.org/lib/search?query=header:Adafruit_GFX.h
*
**********************************************************************

 #include <Adafruit_GFX.h>
          ^~~~~~~~~~~~~~~~
compilation terminated.
*** [.pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada_Alerts.cpp.o] Error 1
In file included from .pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada_Config.cpp:1:0:
.pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada.h:9:10: fatal error: Adafruit_GFX.h: No such file or directory

**********************************************************************
* Looking for Adafruit_GFX.h dependency? Check our library registry!
*
* CLI  > platformio lib search "header:Adafruit_GFX.h"
* Web  > https://platformio.org/lib/search?query=header:Adafruit_GFX.h
*
**********************************************************************

 #include <Adafruit_GFX.h>
          ^~~~~~~~~~~~~~~~
compilation terminated.
*** [.pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada_Config.cpp.o] Error 1
=================================================== [FAILED] Took 3.32 seconds ===================================================
The terminal process "platformio 'run', '--target', 'upload'" terminated with exit code: 1.

Terminal will be reused by tasks, press any key to close it.

> Executing task: platformio run --target upload <

Processing adafruit_clue_nrf52840 (platform: nordicnrf52; board: adafruit_clue_nrf52840; framework: arduino)
--------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/nordicnrf52/adafruit_clue_nrf52840.html
PLATFORM: Nordic nRF52 (4.4.1) > Adafruit CLUE nRF52840
HARDWARE: NRF52840 64MHz, 243KB RAM, 796KB Flash
DEBUG: Current (cmsis-dap) External (cmsis-dap, jlink, stlink)
PACKAGES: 
 - framework-arduinoadafruitnrf52 1.1900.200603 (19.0) 
 - tool-bossac-nordicnrf52 1.10866.191129 (1.8.66) 
 - tool-openocd 2.1000.200630 (10.0) 
 - tool-sreccat 1.164.0 (1.64) 
 - toolchain-gccarmnoneeabi 1.70201.0 (7.2.1)
LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 55 compatible libraries
Scanning dependencies...
Dependency Graph
|-- <Adafruit Arcada Library> 2.5.0
|-- <Adafruit Sensor Lab> 0.4.2
Building in release mode
Compiling .pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada.cpp.o
Compiling .pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada_Alerts.cpp.o
Compiling .pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada_Config.cpp.o
Compiling .pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada_Filesystem.cpp.o
In file included from .pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada.cpp:1:0:
.pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada.h:9:10: fatal error: Adafruit_GFX.h: No such file or directory

**********************************************************************
* Looking for Adafruit_GFX.h dependency? Check our library registry!
*
* CLI  > platformio lib search "header:Adafruit_GFX.h"
* Web  > https://platformio.org/lib/search?query=header:Adafruit_GFX.h
*
**********************************************************************

 #include <Adafruit_GFX.h>
          ^~~~~~~~~~~~~~~~
compilation terminated.
*** [.pio/build/adafruit_clue_nrf52840/lib09d/Adafruit Arcada Library/Adafruit_Arcada.cpp.o] Error 1
In file included from .pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada_Alerts.cpp:1:0:
.pio/libdeps/adafruit_clue_nrf52840/Adafruit Arcada Library/Adafruit_Arcada.h:9:10: fatal error: Adafruit_GFX.h: No such file or directory

Try specifying the Adafruit GFX dependency also in lib_deps or use a lib_ldf_mode = chain+ directive (docs). Might also be related to a possible regression in the library dependency finder (https://github.com/platformio/platformio-core/issues/3668).

1 Like

Thanks maxgerhardt

Though, chain+ did not work for me. I looked through the documentation that you mentioned, I used deep+ which got me further until more dependency issues showed up. Looking through the error messages, I manually added 3 more libs (Adafruit EPD, WavePlayer and TinyUSB) which made the build process went through without any errors.

These 3 libs that I added manually, were specified as dependencies by Adafruit Arcada and Adafruit GFX in file library.properties. However, PlatformIO did not pull them down somehow?

Anyway thanks for your help

Psksvp


; PlatformIO Project Configuration File
;
;   Build options: build flags, source filter
;   Upload options: custom upload port, speed and extra flags
;   Library options: dependencies, extra library storages
;   Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html

[env:adafruit_clue_nrf52840]
platform = nordicnrf52
board = adafruit_clue_nrf52840
framework = arduino
lib_ldf_mode = deep+
lib_deps = adafruit/Adafruit Arcada Library @ ^2.5.0
           adafruit/Adafruit Sensor Lab @ ^0.4.2
           adafruit/Adafruit EPD @ ^3.0.0
           adafruit/Adafruit WavePlayer Library @ ^1.0.3
           adafruit/Adafruit TinyUSB Library @ ^0.10.0