Hello "amishah0526",
coding with arduino is not as simple as installing a new adress-app on your smartphone and then start adding adresses. It is a lot of fun but it needs a little more knowledge than just how to type on a keyboard.
Whenever questions occur you can ask here in the forum. Though the experienced users don't like a ping-pong-game of short questions which would make it nescessary to ask back for details again and again.
please post the exact name of your ESP32-board.
Some of the ESP32-boards have an LED on board some not.
the error that occured is
fatal error: bits/c++config.h: No such file or directory
The compiler needs a certain file and can't find it.
Without the sketch that you tried to compile it is difficult to say exactly what is happening.
So please if you reply to this message, click on the Safe Draft button which will guide you to the "normal" reply-site. In this site you have a Texteditor with more options.
The button "</>" in the upper left corner is for inserting code.
If you click on it these commands will be inserted "[ code ] [ / code]"
Take your complete code copy it to the clipboard and paste it between the "] x [" where the "x" is located. So we can see how your code looks like.
otherwise we would have to speculate what the exact reason for the error is.
maybe your arduino-installation was made to a non-standard path or the code
looks up the include-file in the wrong place.
Alternative you could load a prewritten example
in ´the upper left corner click on the menu-item "file" in the popped up drop-downmenu click "examples" then click on "2. digital" then click on "BlinkWithoutDelay"
OK I tried it myself
@the leeader of the Arduino-project:
Even this example does NOT compile for an ESP32-Dev-module because a constant "LED_BUILTIN" is not defined. I suggest at least SOME quality-management that at least example should
a.) not beaccessable for other boards
or
b.) making sure that the example compile for each and every single board that can be imported
or
c.) add comments to each example that explains the restrictions of the example when it will work
This whole forum seems to be a evergrowing ineffective FAQ of the same questions again and again
caused for such reasons
here is the corrected sketch that should compile for an ESP32-dev-board
// constants won't change. Used here to set a pin number:
const int ledPin = 2;// LED_BUILTIN;// the number of the LED pin
// Variables will change:
int ledState = LOW; // ledState used to set the LED
// Generally, you should use "unsigned long" for variables that hold time
// The value will quickly become too large for an int to store
unsigned long previousMillis = 0; // will store last time LED was updated
// constants won't change:
const long interval = 1000; // interval at which to blink (milliseconds)
void setup() {
// set the digital pin as output:
pinMode(ledPin, OUTPUT);
}
void loop() {
// here is where you'd put code that needs to be running all the time.
// check to see if it's time to blink the LED; that is, if the difference
// between the current time and last time you blinked the LED is bigger than
// the interval at which you want to blink the LED.
unsigned long currentMillis = millis();
if (currentMillis - previousMillis >= interval) {
// save the last time you blinked the LED
previousMillis = currentMillis;
// if the LED is off turn it on and vice-versa:
if (ledState == LOW) {
ledState = HIGH;
} else {
ledState = LOW;
}
// set the LED with the ledState of the variable:
digitalWrite(ledPin, ledState);
}
}
best regards
Stefan