Go to file
Mitch Bradley 7e8993fc83
Speed up upload by a factor of 17 (#4787)
* Speed up upload by a factor of 17

Uploads are very slow because of an unnecessary "client.connected()" check in _uploadReadByte().

Here is what happens:
client.connected() is called for every byte read.  WiFiClient::connected() calls recv(fd(), &dummy, 0, MSG_DONTWAIT); which takes a relatively long time, so the optimized path of returning a buffered byte via client.read() is effectively nullified.

Removing the one line changed the upload speed for a 2 MB file (discarding the received data) from 22 KB/sec (before) to 367 KB/sec (after).

The change is safe in the face of disconnects because client.read(), when it no longer has buffered data, calls (WiFiClient)  fillBuffer(), which calls recv(), so the disconnection will be detected in due course.

* Move disconnect check into the timeout loop
2021-02-16 01:47:01 +02:00
.github Copy platformio-build.py in the release package 2021-01-14 11:17:21 +02:00
cores/esp32 Remove an unused variable 'channel' (#4725) 2021-01-21 14:31:25 +02:00
docs Add initial support for arm64 toolchain. (#4117) 2020-11-02 20:39:31 +02:00
libraries Speed up upload by a factor of 17 (#4787) 2021-02-16 01:47:01 +02:00
package Add arm64 support for mkspiffs 2021-01-21 14:42:31 +02:00
tools Idf release/v3.3 d8082b7f3 2021-02-16 01:37:37 +02:00
variants [1.0.5] Update Heltec ESP32 series boards definition (#4577) 2020-12-02 11:50:12 +02:00
.gitignore Update .gitignore 2020-12-01 22:20:06 +02:00
.gitmodules Set ESP-IDF to 3.2 (#2662) 2019-04-12 15:43:53 +02:00
.travis.yml Use Github Actions for release (#3309) 2019-10-01 10:44:04 +03:00
boards.txt [1.0.5] Update Heltec ESP32 series boards definition (#4577) 2020-12-02 11:50:12 +02:00
CMakeLists.txt Separate Provisioning library from WiFi library (#4547) 2020-11-19 00:12:16 +02:00
component.mk Fix compilation errors when used as IDF component 2019-01-26 21:37:03 +01:00
Kconfig.projbuild Add loop task stack size config to Kconfig 2020-12-02 11:56:45 +02:00
LICENSE.md Add LGPL 2.1 License 2019-04-16 03:08:50 +02:00
Makefile.projbuild Remove duplicate ota_data flashing under IDF 2018-08-16 13:34:47 +02:00
package.json Initial version of build script for @PlatformIO; CI integration for Linux, macOS and Windows (#153) 2017-01-28 14:19:56 +02:00
platform.txt Idf release/v3.3 d8082b7f3 2021-02-16 01:37:37 +02:00
programmers.txt initial import 2016-10-06 07:09:44 -06:00
README.md Update README.md 2020-11-06 17:21:12 +02:00

Arduino core for the ESP32

Build Status

Need help or have a question? Join the chat at https://gitter.im/espressif/arduino-esp32

Contents

Development Status

Latest Stable Release Release Version Release Date Downloads

Latest Development Release Release Version Release Date Downloads

Installation Instructions

Decoding exceptions

You can use EspExceptionDecoder to get meaningful call trace.

Issue/Bug report template

Before reporting an issue, make sure you've searched for similar one that was already created. Also make sure to go through all the issues labelled as for reference.

Finally, if you are sure no one else had the issue, follow the ISSUE_TEMPLATE while reporting any issue.

ESP32Dev Board PINMAP

Pin Functions

Tip

Sometimes to program ESP32 via serial you must keep GPIO0 LOW during the programming process