-
-
Notifications
You must be signed in to change notification settings - Fork 125
Open
Description
When I try to download large size contents using WiFiClient( 20kb ), some bytes are missed. I read some issues #15 here but it was closed and it didn't work for me. The missing bytes are middle part of the contents. The end of contents are correct.
my code is here
unsigned char ch;
while ( cnt < bodyLen ) {
if( client.available() ) {
ch = client.read();
sprintf(hexbuf, "%02X", ch);
Serial.print(hexbuf);
cnt++;
if( cnt % 2 == 0 )
Serial.print(' ');
if( cnt % 16 == 0 ) {
sprintf(hexbuf, "%d, %ld / %ld\n", line++, cnt, bodyLen);
Serial.print(hexbuf);
}
} // end of available
else {
for(j=0;j<512;j++);
}
} // end of while
Metadata
Metadata
Assignees
Labels
No labels