0

i have been working with platformio for a few weeks now and have been able to create quite a bit for my microcontroller (atmega328p). I have always tried to get away from the Arduino structure. So no “void setup” or “void loop” but simple C. Now I got a ESP8266, which I would like to compile with a C environment. When I create the project now (for the 12E) it asks which framework I should use. I have tried them all by replacing the Arduino setup and loop with the int main(){} function, however it always came up with errors. Does anyone know how I can use a pure C environment for the ESP8266?

2
  • Have you read on how to pick and setup the framework you are going to used in platformio. You will even find the links to examples there. BTW, neither ESP8266 non-os SDK nor ESP8266 rtos exposes main() in the user space, it all use internal and only expose a user_int() function for you work on, just like Arduino framework, where setup() and loop() are the functions within a main() behind the scene. Having a main() is not the reason why you should pick up a language(c++ versus c) or framework. Commented Apr 26, 2022 at 3:02
  • Don't tag arudion-esp8266 when you have no intention to use the Arduino framework. Commented Apr 26, 2022 at 3:04

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.