Serial Monitor for esp-idf
MIT License
This project is a Serial Monitor for esp-idf that can be accessed remotely via a web browser. Webpage are stored in program memory of ESP32.
I referred to this.
ESP-IDF V5.0 or later. ESP-IDF V4.4 release branch reached EOL in July 2024. ESP-IDF V5.1 is required when using ESP32-C6.
unsigned long lastMillis = 0;
void setup() {
Serial.begin(115200);
}
void loop() {
while (Serial.available()) {
String command = Serial.readStringUntil('\n');
Serial.println(command);
}
if(lastMillis + 1000 <= millis()){
Serial.print("Hello World ");
Serial.println(millis());
lastMillis += 1000;
}
delay(1);
}
git clone https://github.com/nopnop2002/esp-idf-web-serial
cd esp-idf-web-serial/
git clone https://github.com/Molorius/esp32-websocket components/websocket
idf.py set-target {esp32/esp32s2/esp32s3/esp32c2/esp32c3}
idf.py menuconfig
Set the information of your access point.
Set the information of your time zone.
Set GPIO to use with UART.
AtMega328 | ESP32 | ESP32-S2/S3 | ESP32-C2/C3 | |
---|---|---|---|---|
TX | -- | GPIO16 | GPIO34 | GPIO0 |
RX | -- | GPIO17 | GPIO35 | GPIO1 |
GND | -- | GND | GND | GND |
You can change it to any pin using menuconfig.
idf.py flash monitor
http:://{IP of ESP32}/
or
http://esp32-server.local/
WEB Pages are stored in the html folder. You cam change root.html as you like.