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

Fix server.send buffer size limited to 4k #25

Closed
khoih-prog opened this issue Nov 14, 2022 · 2 comments
Closed

Fix server.send buffer size limited to 4k #25

khoih-prog opened this issue Nov 14, 2022 · 2 comments
Labels
bug Something isn't working enhancement New feature or request

Comments

@khoih-prog
Copy link
Owner

khoih-prog commented Nov 14, 2022

Created by @jlemieux55 as server.send buffer size limited to 4k #23

html file or message is > 4500 bytes
server.send buffer truncates at > 4096
String message="";
message+=("html content is over 4500 bytes");
server.send(200, "text/html", message);

Platform: Arduino MKR1010 (wifinina)

Closed via WiFiNINA_Generic v1.8.15-0 which permits sending much larger data than total 4K.


Releases v1.8.15-0

  1. Fix severe limitation to permit sending much larger data than total 4K. Check server.send buffer size limited to 4k #23
  2. Add examples WiFiWebServer_BigData to demo how to send much larger data than total 4K
  3. Optimize code
  4. Clean up

Debug Terminal

The following is debug terminal output when running example WiFiWebServer_BigData on NANO_RP2040_CONNECT board, using this WiFiNINA_Generic Library, to demo how to send much larger data than total 4K

Start WiFiWebServer_BigData on NANO_RP2040_CONNECT
WiFiNINA_Generic v1.8.15-0
WiFiWebServer v1.10.0
Attempting to connect to SSID: HueNet
Attempting to connect to SSID: HueNet
SSID: HueNet
IP Address: 192.168.2.117
Signal strength (RSSI):-24 dBm
String Len = 27609
String Len = 27609
@khoih-prog khoih-prog added bug Something isn't working enhancement New feature or request labels Nov 14, 2022
@khoih-prog
Copy link
Owner Author

Hi @jlemieux55

Did you try the new WiFiNINA_Generic v1.8.15-0 ?

If not working, it's possible that you have MKR1010 and that board actually uses WiFi101 library.

#if ( ( defined(ARDUINO_SAMD_MKR1000) || defined(ARDUINO_SAMD_MKRWIFI1010) ) && USING_WIFI101 )
#include <WiFi101.h>
#warning Using WiFi101 Library for MKR1000 and MKRWIFI1010 in WiFiNINA_Pinout_Generic.h
#else
#include "WiFi_Generic.h"
#endif

If you're willing and have time to test, I can also modify the forked-WiFi101 library, to provide the similar feature, to send large data.

The current problem for me is that I have no MKR1010 to test and verify, and don't like to buy that outdated board.

Just let me know.

@khoih-prog
Copy link
Owner Author

khoih-prog commented Nov 17, 2022

Hi @jlemieux55

Just released WiFi101_Generic v1.0.0 to try fixing the 4k issue.

Please try and report any problem.


Releases v1.0.0

  • 2022.11.17
  1. Fix severe limitation to permit sending much larger data than total 4K
  2. Use allman astyle and add utils
  3. Add Packages' Patches

Releases v0.16.1

  • 2021.05.21

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant