Thanks for trying it.
I found a site that discusses the same issue, it seems to be specific to the ESP32C3. I am reading the comments now.
If I find out anything I will post it.
opened 07:01AM - 14 Jul 22 UTC
closed 10:47AM - 14 Dec 22 UTC
Area: Performance
Area: Peripherals API
### Board
ESP32C3M1
### Device Description
Custom board:

### Hardware Configuration
GPIO 18 & 19 are connected to USB. USB is used to program the device and to monitor Serial.print output.
### Version
v2.0.3
### IDE Name
Arduino
### Operating System
MacOS 10.15.7
### Flash frequency
40Mhz
### PSRAM enabled
yes
### Upload speed
115200
### Description
USB is used to program the device and to monitor Serial.print output. However, when the device is unplugged, and the Serial.print() lines are left in the code, they cause delays of a second or so. Plugging back in will make the delays go away. If I remove the Serial.print() lines, it makes the delays disappear too.
### Sketch
```cpp
#include <Wire.h>
#include <Adafruit_NeoPixel.h>
#define LED_PIN 6
#define NEOPIXEL_PIN LED_PIN
Adafruit_NeoPixel pixels(1, NEOPIXEL_PIN, NEO_GRB + NEO_KHZ800);
void setup() {
// put your setup code here, to run once:
Serial.begin(115200);
}
void loop() {
// put your main code here, to run repeatedly:
pixels.begin(); // INITIALIZE NeoPixel strip object (REQUIRED)
Serial.print("Red... ");
// drawMessage("Test Red LED");
pixels.setPixelColor(0, pixels.Color(64, 0, 0));
pixels.show();
delay(500);
Serial.print("Green... ");
// drawMessage("Test Green LED");
pixels.setPixelColor(0, pixels.Color(0, 64, 0));
pixels.show();
delay(500);
Serial.print("Blue... ");
// drawMessage("Test Blue LED");
pixels.setPixelColor(0, pixels.Color(0, 0, 64));
pixels.show();
delay(500);
Serial.print("White... ");
// drawMessage("Test Whitish LED");
pixels.setPixelColor(0, pixels.Color(64, 64, 64));
pixels.show();
delay(500);
Serial.print("Off... ");
pixels.clear();
pixels.show();
delay(500);
Serial.println("Done. Looping");
}```
```
### Debug Message
```plain
There is no debug or error message.
```
### Other Steps to Reproduce
Run the sketch. While the device is plugged into a computer with Arduino, the lights flash faster. When you unplug the USB cable the lights slow down.
With more or longer Serial.print output, the delay can be more than a second.
That same code above is running on the two boards in this video. When you plug the USB in, you can see that the flash rate increases on the one plugged in.
https://user-images.githubusercontent.com/1689095/178857842-551736c3-3ac0-4adc-9bf8-758c5a6fa6ad.mov
### I have checked existing issues, online documentation and the Troubleshooting Guide
- [X] I confirm I have checked existing issues, online documentation and Troubleshooting guide.