Create new project starting from source file

Hi there,

I started to work on a project for an ATmel328P.
The project source file are contained only inside a src folder and there is no an .ino file.
Only the main.c plus several libraries (
.c + *.h).

I have only the makefile (
I can compile without errors and now I’m wonder if it possible to debug the code from linux.

I looking for a solution using VS Code + Platformio but I don’t know how to start and I want to mantain the original folder structure.

Basically all the code must be inside the src folder.

Any help will be appreciated.

BR, Federico

That’s not mandatory. You can abitrarily redirect where PlatformIO thinks the src/ folder is, e.g. the same directory as the platformio.ini is in.

See documentation.

An example is e.g. available at GitHub - maxgerhardt/OpenSprinkler-Firmware: OpenSprinkler Unified Firmware for OpenSprinkler, OpenSprinkler Pi, and OpenSprinkler Beagle..