What code exactly are you running?
What does your platformio.ini file look like?
What is exactly the error that you get?
i already found the problem. One way or another the call for the arduino libary failed.
Wiht the inclusion of ARduino.h it worked
so you can close the issue