ESP32DEV C3 Serial Port Not Working Correctly

With this very simple code, the LED is blinking correctly as expected, but there are no outputs from the serial ports. I've tried setting the baud rate to 9600 and 115200 but didn't work. I've tried reset method and reinstalling Arduino but still have no outputs.

void setup() {
  Serial.begin(115200);
  pinMode(1,OUTPUT);
}

void loop() {
  digitalWrite(1,HIGH);
  while(!Serial);
  delay(100);
  Serial.println("hello");
  digitalWrite(1,LOW);
  delay(100);
}

Did you activate the "USB CDC on boot option"?

2 Likes

Are you using the following ESP32 C3 Super Mini board?

Which IDE are you using? IDE 1.x?

Hi @kp4good ,

the led connected to pin 1 quite likely interferes with Serial on UART0

Source: https://randomnerdtutorials.com/esp32-uart-communication-serial-arduino/#esp32-uart-peripherals

What happens if you move the led to a different pin?

Good luck!
ec2021

Thank you for your advice! Seems like there are conflicts between the pins. After switching to a different project and unplugging the pins the Serial seems to be working fine.

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.