Can I turn off the setting with myFunction in the main.cpp

Hi, All :
I try to use the PlatformIO for ESP32 in VS code


. But I don’t know why the new project always begins with the myFunction(int, int) in the main.cpp. ( My PlatformIO version is 3.4.4 ) I see the other training video does not have this. Can I close this setting? Thank your help for this.

This is provided as an example. You can delete lines 3,4 and 15,16,17,18.

1 Like

This is just to train you to use .cpp syntax properly. Without line 4, the code would not be a compilable .cpp file, but people coming from the Arduino IDE (which uses .ino syntax) never write such a line. See also FAQ.

Of course, line 3-4, 8 and 15-18 can be deleted with no issues.

1 Like

Hi, Zapta :
Thank your reply, is there any setting I should take care, no need
every time to delete these lines.

Hi, Maxgerthardt:

Thank your reply.