AH2005NA / m5stick-shark

GNU General Public License v3.0
34 stars 3 forks source link

SPI.h #7

Open davicastaldini opened 1 month ago

davicastaldini commented 1 month ago

I can't upload because i am getting this error:

...\Arduino\libraries\m5stick-shark-main/SD.h:6:12: fatal error: SPI.h: No such file or directory

include

        ^~~~~~~

compilation terminated. exit status 1

Compilation error: exit status 1

AH2005NA commented 1 month ago

do you have some some other errors or is this the only one?

davicastaldini commented 1 month ago

do you have some some other errors or is this the only one?

this has been the only

AH2005NA commented 1 month ago

Can you send me the first 17 lines of your code and which device do you use?

davicastaldini commented 1 month ago

Can you send me the first 17 lines of your code and which device do you use?

// Shark Firmware for the M5 Stack Stick C Plus // github.com/AH2005NA

// -=-=-=-=-=-=- Uncomment the platform you're building for -=-=-=-=-=-=- // #define STICK_C_PLUS

define STICK_C_PLUS2

// #define STICK_C // #define CARDPUTER // -=-=- Uncommenting more than one at a time will result in errors -=-=-

// -=-=- Shark Language for Menu and Portal -=- Thanks, @marivaaldo and @Mmatuda! -=-=- // #define LANGUAGE_EN_US // #define LANGUAGE_PT_BR // #define LANGUAGE_GER // #define LANGUAGE_IT_IT // #define LANGUAGE_FR_FR

I am using a M5StickC Plus 2

AH2005NA commented 1 month ago

On which line is the error

davicastaldini commented 1 month ago

On which line is the error

I was looking the error again and I came across this

In file included from ...\Arduino\libraries\m5stick-shark-main/SD.h:5, ...\Arduino\libraries\m5stick-shark-main/SD.h:4:18: error: #include nested too deeply

include

              ^

...\Arduino\libraries\m5stick-shark-main/SD.h:5:18: error: #include nested too deeply

include

              ^

...\Arduino\libraries\m5stick-shark-main/SD.h:6:19: error: #include nested too deeply

include

FatherDivine commented 1 month ago

On which line is the error

I was looking the error again and I came across this

In file included from ...\Arduino\libraries\m5stick-shark-main/SD.h:5, ...\Arduino\libraries\m5stick-shark-main/SD.h:4:18: error: #include nested too deeply #include ^ ...\Arduino\libraries\m5stick-shark-main/SD.h:5:18: error: #include nested too deeply #include ^ ...\Arduino\libraries\m5stick-shark-main/SD.h:6:19: error: #include nested too deeply #include

If that is your only error, the fix is moving the folder you're working in somewhere else, like the base of your drive (C:\ or maybe /home/user/ for *nix). "nested too deeply" is that it's too many folders.

Edit Seems nested too deeply can be something else in coding world. Try this:

Hi, " This error occurs if the preprocessor encounters too many nested "#include" directives. It is usually caused by two or more files trying to include each other, leading to an infinite recursion. Example: / foo.h /

include "bar.h"

... / bar.h /

include "foo.h"

... The solution to this problem is to ensure that files do not mutually include each other "

Maybe between those 3 files is a loop (FS.h, Sd.h, SPI.h). I would use search in the code and see what headers are called in each and see if one calls back to the other which calls back to the same one which is a loop.

AH2005NA commented 1 month ago

@davicastaldini does it work now?