Run GRBL on vscode with platformio

It is possible to run GRBL code developed for Arduino uno to run on platformio? I’ve tried a few times but get different errors each time. I see its a mix of C. So I was bot sire if its even possible. The grbl code I have compiles and runs fine on the Arduino IDE but I want to be able to debug and make changes. I have searched github but no one has posted anything I have see to run in vscode

Every sketch that compiles for the Arduino IDE should compile equally well using PlatformIO.

Please post the exact project that fails to compile. Use Github if needed. Also state under which Arduino IDE settings (board, Tools settings) you use.

Thank you your reply. I will try to post code but its 20 files. You answered my question that it is possible so I will give it another try. I am new to platformio. I have since found
GitHub - bdring/Grbl_Esp32: A port of Grbl CNC Firmware for ESP32
And was able to compile so I think that is the direction I will follow for now.