Blink GPIO2 on ESP-01
Posted: Tue Jul 14, 2015 7:28 am
Hi, I am experimenting with ESP-01 and Arduino IDE and I am trying to run the Blink GPIO2 example (code below).
The program seems to flash correctly, but then GPIO2 is stuck at 1 and never changes. Do you have any suggestions for debugging?
And do you know why Serial.print() instructions do not show up on the serial monitor?
Thanks!
void setup() {
pinMode(2, OUTPUT);
Serial.begin(9600);
Serial.println("setup");
}
void loop() {
digitalWrite(2, HIGH); // turn the LED on (HIGH is the voltage level)
Serial.println("HIGH");
delay(1000); // wait for a second
digitalWrite(2, LOW); // turn the LED off by making the voltage LOW Serial.println("LOW");
delay(1000); // wait for a second
}
The program seems to flash correctly, but then GPIO2 is stuck at 1 and never changes. Do you have any suggestions for debugging?
And do you know why Serial.print() instructions do not show up on the serial monitor?
Thanks!
void setup() {
pinMode(2, OUTPUT);
Serial.begin(9600);
Serial.println("setup");
}
void loop() {
digitalWrite(2, HIGH); // turn the LED on (HIGH is the voltage level)
Serial.println("HIGH");
delay(1000); // wait for a second
digitalWrite(2, LOW); // turn the LED off by making the voltage LOW Serial.println("LOW");
delay(1000); // wait for a second
}