Skip to content
This repository was archived by the owner on Feb 4, 2023. It is now read-only.

Commit 9075cb4

Browse files
authored
v1.2.0 to save heap when sending large data
### Release v1.2.0 1. Support using `CString` to save heap to send `very large data`. Check [request->send(200, textPlainStr, jsonChartDataCharStr); - Without using String Class - to save heap #8](khoih-prog/Portenta_H7_AsyncWebServer#8) 2. Add multiple examples to demo the new feature
1 parent c1ae603 commit 9075cb4

37 files changed

+1838
-176
lines changed

CONTRIBUTING.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,10 @@ Arduino IDE version: 1.8.19
3131
RP2040 core v2.5.4
3232
RASPBERRY_PI_PICO_W Module
3333
OS: Ubuntu 20.04 LTS
34-
Linux xy-Inspiron-3593 5.15.0-46-generic #49~20.04.1-Ubuntu SMP Thu Aug 4 19:15:44 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
34+
Linux xy-Inspiron-3593 5.15.0-48-generic #54~20.04.1-Ubuntu SMP Thu Sep 1 16:17:26 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
3535
3636
Context:
37-
I encountered a crash while using Async_AdvancedWebServer
37+
I encountered a crash while using this library
3838
3939
Steps to reproduce:
4040
1. ...

changelog.md

+6
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
## Table of Contents
1212

1313
* [Changelog](#changelog)
14+
* [Release v1.2.0](#Release-v120)
1415
* [Release v1.1.2](#Release-v112)
1516
* [Release v1.1.1](#Release-v111)
1617
* [Release v1.1.0](#Release-v110)
@@ -24,6 +25,11 @@
2425

2526
## Changelog
2627

28+
### Release v1.2.0
29+
30+
1. Support using `CString` to save heap to send `very large data`. Check [request->send(200, textPlainStr, jsonChartDataCharStr); - Without using String Class - to save heap #8](https://github.com/khoih-prog/Portenta_H7_AsyncWebServer/pull/8)
31+
2. Add multiple examples to demo the new feature
32+
2733
### Release v1.1.2
2834

2935
1. Add functions and example `Async_AdvancedWebServer_favicon` to support `favicon.ico`

examples/Async_AdvancedWebServer/Async_AdvancedWebServer.ino

+3-2
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ void handleRoot(AsyncWebServerRequest *request)
8484
snprintf(temp, BUFFER_SIZE - 1,
8585
"<html>\
8686
<head>\
87-
<meta http-equiv='refresh' content='5'/>\
87+
<meta http-equiv='refresh' content='60'/>\
8888
<title>AsyncWebServer-%s</title>\
8989
<style>\
9090
body { background-color: #cccccc; font-family: Arial, Helvetica, Sans-Serif; Color: #000088; }\
@@ -146,6 +146,7 @@ void drawGraph(AsyncWebServerRequest *request)
146146
out += temp;
147147
y = y2;
148148
}
149+
149150
out += "</g>\n</svg>\n";
150151

151152
request->send(200, "image/svg+xml", out);
@@ -181,7 +182,7 @@ void setup()
181182
digitalWrite(LED_BUILTIN, LED_OFF);
182183

183184
Serial.begin(115200);
184-
while (!Serial);
185+
while (!Serial && millis() < 5000);
185186

186187
delay(200);
187188

examples/Async_AdvancedWebServer_Country/Async_AdvancedWebServer_Country.ino

+2-2
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ void handleRoot(AsyncWebServerRequest *request)
8787
snprintf(temp, BUFFER_SIZE - 1,
8888
"<html>\
8989
<head>\
90-
<meta http-equiv='refresh' content='5'/>\
90+
<meta http-equiv='refresh' content='60'/>\
9191
<title>AsyncWebServer-%s</title>\
9292
<style>\
9393
body { background-color: #cccccc; font-family: Arial, Helvetica, Sans-Serif; Color: #000088; }\
@@ -183,7 +183,7 @@ void setup()
183183
digitalWrite(LED_BUILTIN, LED_OFF);
184184

185185
Serial.begin(115200);
186-
while (!Serial);
186+
while (!Serial && millis() < 5000);
187187

188188
delay(200);
189189

0 commit comments

Comments
 (0)