Hello @G00TH
I think the issue is with M5Core2 library not being ready/compatible for Arduino library version 3.x.x. (I get the same compilation errors as you are reporting.)
That said, you could downgrade Arduino library to version 2.x.x - then the Hello World example of the M5Core2 library works for me.
Or I suggest you try M5Unified with M5GFX libraries instead. For me they compile and run fine with Arduino library 2.x.x or 3.x.x.
#include <M5Unified.h>
#include <M5GFX.h>
void setup() {
auto cfg = M5.config();
M5.begin(cfg);
M5.Display.println("M5Core2 - Hello world");
}
void loop() {
}
Thanks
Felix