-->
Page 7 of 10

Re: ESP8266WebServer to send larger amounts of data

PostPosted: Tue Sep 08, 2015 9:14 am
by GregryCM
martinayotte wrote:For ESP crashes, maybe it is related to bug https://github.com/esp8266/Arduino/issues/596.

Are you using ESP8266WebServer ?

I've done some fixes on that yesterday, I've submit a PR to IGRR, waiting for merge.
https://github.com/esp8266/Arduino/pull/753/
(But you can grab the fixes and manually patch your environment)


I looked at your fixes, and it should address the issues that I am seeing. I'll try tonight.

I am not familiar with the under workings of the ESP8266, but depending on the length of the binary data being sent, does the watchdog need to be kicked in the loop?

Thanks,
GregryCM

Re: ESP8266WebServer to send larger amounts of data

PostPosted: Tue Sep 08, 2015 3:24 pm
by martinayotte
GregryCM wrote:but depending on the length of the binary data being sent, does the watchdog need to be kicked in the loop?

I presume the _client.write() is already handling that with a yield() while a packets are sent.

Re: ESP8266WebServer to send larger amounts of data

PostPosted: Tue Sep 08, 2015 9:31 pm
by GregryCM
I replaced 3 files in my environment, built, and get the following errors:
ESP8266WebServer.cpp
ESP8266WebServer.h
WiFiClient.cpp

Maybe you have a newer WiFiClient.h?

Arduino: 1.6.5 (Windows 7), Board: "Generic ESP8266 Module, Serial, 80 MHz, 40MHz, DIO, 115200, 512K (64K SPIFFS)"

C:\Users\Greg\AppData\Roaming\Arduino15\packages\esp8266\hardware\esp8266\1.6.5-947-g39819f0\libraries\ESP8266WiFi\src\WiFiClient.cpp:180:50: error: no 'size_t WiFiClient::write_P(const char*, size_t)' member function declared in class 'WiFiClient'
size_t WiFiClient::write_P(PGM_P buf, size_t size)
^
C:\Users\Greg\AppData\Roaming\Arduino15\packages\esp8266\hardware\esp8266\1.6.5-947-g39819f0\libraries\ESP8266WiFi\src\WiFiClient.cpp:293:31: error: no 'IPAddress WiFiClient::localIP()' member function declared in class 'WiFiClient'
IPAddress WiFiClient::localIP()
^
C:\Users\Greg\AppData\Roaming\Arduino15\packages\esp8266\hardware\esp8266\1.6.5-947-g39819f0\libraries\ESP8266WiFi\src\WiFiClient.cpp:301:32: error: no 'uint16_t WiFiClient::localPort()' member function declared in class 'WiFiClient'
uint16_t WiFiClient::localPort()
^
C:\Users\Greg\AppData\Roaming\Arduino15\packages\esp8266\hardware\esp8266\1.6.5-947-g39819f0\libraries\ESP8266WiFi\src\WiFiClient.cpp:332:48: error: no 'void WiFiClient::stopAllExcept(WiFiClient*)' member function declared in class 'WiFiClient'
void WiFiClient::stopAllExcept(WiFiClient * exC) {
^
Error compiling.

Re: ESP8266WebServer to send larger amounts of data

PostPosted: Tue Sep 08, 2015 10:34 pm
by martinayotte
GregryCM wrote:Maybe you have a newer WiFiClient.h?


This was one of my contribution that was been merged in the main tree 3 weeks ago.
See commit : https://github.com/esp8266/Arduino/comm ... f5adcc4e6f

If you install staging, you will get it. Otherwise, you will need manual merge there too.