diff --git a/examples/demo/demo.ino b/examples/demo/demo.ino index a7d962e..063706e 100644 --- a/examples/demo/demo.ino +++ b/examples/demo/demo.ino @@ -53,8 +53,14 @@ void setup() { void loop() { delay(2000); + // we suggest you to use `print + "\n"` instead of `println` + // because the println will send "\n" separately, which means + // it will cost a sending buffer just for storage "\n". (there + // only 8 buffer space in ESPAsyncWebServer by default) WebSerial.print(F("IP address: ")); - WebSerial.println(WiFi.localIP()); + // if not use toString the ip will be sent in 7 part, + // which means it will cost 7 sending buffer. + WebSerial.println(WiFi.localIP().toString()); WebSerial.printf("Millis=%lu\n", millis()); WebSerial.printf("Free heap=[%u]\n", ESP.getFreeHeap()); } \ No newline at end of file diff --git a/examples/demo_ap/demo_ap.ino b/examples/demo_ap/demo_ap.ino index 507895a..a8c42f9 100644 --- a/examples/demo_ap/demo_ap.ino +++ b/examples/demo_ap/demo_ap.ino @@ -50,8 +50,14 @@ void setup() { void loop() { delay(2000); + // we suggest you to use `print + "\n"` instead of `println` + // because the println will send "\n" separately, which means + // it will cost a sending buffer just for storage "\n". (there + // only 8 buffer space in ESPAsyncWebServer by default) WebSerial.print(F("IP address: ")); - WebSerial.println(WiFi.localIP()); + // if not use toString the ip will be sent in 7 part, + // which means it will cost 7 sending buffer. + WebSerial.println(WiFi.localIP().toString()); WebSerial.printf("Millis=%lu\n", millis()); WebSerial.printf("Free heap=[%u]\n", ESP.getFreeHeap()); } \ No newline at end of file