Bibliotheken in VS Code und Platformio

Hallo Leute, ich bin am verzweifeln. ich relativ neu im den Thema Arduiono/ ESp32 programieren.
War in arduino schon bisschen unterwegs. Nun möchte ich gern das ganze im Vs Code und Platformio umsetzten bezüglich Architekthur und geschwindikeit des VSC.

Nur bringe ich es nicht hin, dass Ich die Libs zu laufen kriege. Nur #include fehler egal was ich probiere. Bin das Netz am wälzen, habe leider noch keinen zufriedenstellenden Ansatz gefunden.

Mir hat jemand eine komplette Skech Datei gegeben die bei Ihm auf Arduino 1.8.9 compieliert wird und auf dem Esp32 dev kit läuft.
auch wenn ich die ino in pio Importiere oder neues Projekt erstelle und die Daten einfüge, kommen die gleichen Probleme:

Z.B. er findet die SPI.h nicht obwohl die TFT_espi instaliert ist.

Ich hoffe, jemand kennt eine Lösungs-richtung.

In file included from src/GfxUi.h:26,
                 from src/GfxUi.cpp:25:
.pio/libdeps/esp32doit-devkit-v1/TFT_eSPI/TFT_eSPI.h:33:12: fatal error: SPI.h: No such file or directory

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

   #include <SPI.h>
            ^~~~~~~
compilation terminated.
In file included from C:/Users/pingg/OneDrive/Dokumente/PlatformIO/Projects/240117-153224-esp32doit-devkit-v1/src/ESP32_DS_2.ino:31:
.pio/libdeps/esp32doit-devkit-v1/TFT_eSPI/TFT_eSPI.h:33:12: fatal error: SPI.h: No such file or directory

*************************************************************
* Looking for SPI.hCompiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatFileWrite.cpp.o
 dependency? Check our library registry!
*
* CLI  > platformio lib search "header:SPI.h"
* Web  > https://registry.platformio.org/search?q=header:SPI.h
*
*************************************************************

   #include <SPI.h>
            ^~~~~~~
compilation terminated.
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatFormatter.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatName.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatPartition.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatVolume.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatDbg.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFile.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFileLFN.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFilePrint.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFileSFN.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFormatter.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatName.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatPartition.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatVolume.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FreeStack.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FsLib\FsFile.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FsLib\FsNew.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FsLib\FsVolume.cpp.o
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\MinimumSerial.cpp.o
.pio/libdeps/esp32doit-devkit-v1/TFT_eSPI/FS.cpp:22:10: fatal error: FSImpl.h: No such file or directory

****************************************************************
* Looking for Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\SdCard\SdCardInfo.cpp.o
FSImpl.h dependency? Check our library registry!
*
* CLI  > platformio lib search "header:FSImpl.h"
* Web  > https://registry.platformio.org/search?q=header:FSImpl.h
*
****************************************************************

 #include "FSImpl.h"
          ^~~~~~~~~~
compilation terminated.
Compiling .pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\SdCard\SdSpiCard.cpp.o
*** [.pio\build\esp32doit-devkit-v1\src\GfxUi.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\src\ESP32_DS_2.ino.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\libe97\TFT_eSPI\FS.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/TFT_eSPI/TFT_eSPI.cpp:16:
.pio/libdeps/esp32doit-devkit-v1/TFT_eSPI/TFT_eSPI.h:33:12: fatal error: SPI.h: No such file or directory

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

   #include <SPI.h>
            ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\libe97\TFT_eSPI\TFT_eSPI.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatPartition.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFile.h:37,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFilePrint.cpp:27:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatPartition.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFile.h:37,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFile.cpp:28:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
compilation terminated.
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatPartition.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFile.h:37,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatDbg.cpp:25:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatDbg.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatFile.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatFilePrint.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatPartition.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFile.h:37,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFileWrite.cpp:27:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatFileWrite.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatPartition.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFile.h:37,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFormatter.cpp:28:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatPartition.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFile.h:37,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatName.cpp:29:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatFormatter.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatName.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatPartition.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFile.h:37,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatPartition.cpp:27:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatPartition.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatPartition.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatFile.h:37,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/ExFatLib/ExFatVolume.cpp:27:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\ExFatLib\ExFatVolume.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatDbg.cpp:25:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatDbg.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.cpp:27:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFile.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFileLFN.cpp:29:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFilePrint.cpp:28:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFileLFN.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFilePrint.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFormatter.cpp:25:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFileSFN.cpp:27:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFormatter.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatFileSFN.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatName.cpp:28:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.cpp:28:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FatLib/FatVolume.cpp:27:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatName.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatPartition.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FatLib\FatVolume.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/FsVolume.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/FsLib.h:31,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/FsFile.cpp:25:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdCard.h:28,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/../common/FsBlockDevice.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/FatPartition.h:33,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/FatFile.h:38,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/FatVolume.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/../FatLib/FatLib.h:27,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/FsVolume.h:32,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/FsLib.h:31,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/FsLib/FsVolume.cpp:25:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FsLib\FsFile.cpp.o] Error 1
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\FsLib\FsVolume.cpp.o] Error 1
In file included from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.h:35,
                 from .pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/SdSpiCard.cpp:25:
.pio/libdeps/esp32doit-devkit-v1/SdFat - Adafruit Fork/src/SdCard/../SpiDriver/SdSpiDriver.h:85:10: fatal error: SPI.h: No such file or directory

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

 #include "SPI.h"
          ^~~~~~~
compilation terminated.
*** [.pio\build\esp32doit-devkit-v1\lib821\SdFat - Adafruit Fork\SdCard\SdSpiCard.cpp.o] Error 1

Hier steht wie es geht

https://docs.platformio.org/en/latest/faq/ino-to-cpp.html

In der platformio.ini müssen min. folgende Werte korrekt eingetragen sein:
platform = espressif32
framework = arduino
board = esp32dev

Füge mal ein #include <Arduino.h> am Anfang des Sketches hinzu.

So steht es u.a. in der verlinkten Beschreibung...

1 Like

Bin gerade wieder unterwegs. So wie ich das richtig im Kopf habe, kenne ich die Thematik.
Habs so auch probiert, nur hat's auch nicht geholfen, werde es aber nochmals überprüfen, sobald ich wieder am Pc bin..

Wenn Du noch beschreiben würdest, welche Bibliotheken in Deinem Code eingebunden werden, wäre auch eine konkretere Hilfe möglich.

In der Arduino ide liegen die Bibliotheken global, soll heißen, du installierst sie 1x und kannst sie mithilfe von include in jedem Projekt benutzen.
Bei Platform io funktioniert das anders. Dort muss die zu verwendete Bibliothek für jedes Projekt extra installiert werden und diesem auch extra hinzugefügt werden. Klingt erstmal kompliziert (und wenn man von der Arduino ide kommt) auch unnötig, aber der Vorteil ist, du kannst so Projekte haben mit verschiedenen Versionen der einzelnen Bibliotheken. Und wenn mal eine neue Version einer Bibliothek kommt zerschießt du dir deine Projekte im Zweifel nicht, da du bei Platform io gezielter updaten kannst.

Oben wird ja die SPI.h bemängelt.

Und die SPI.h musste ich bisher nie installieren oder in den Bibliothek Ordner kopieren.

Muss man auch nicht. Das sollte sich auflösen, wenn die Arduino.h inkludiert wird, so wie Du es auch schon geschrieben hast.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.