ESP32 - How to increase the maximum number of sockets

Still didn't found an ESP32 with a decent delivery price so today I've tested the environment provided by EspressIf looking on the maximum number of sockets. On ESP8266 I've managed to have more then 20 sockets opened and carrying MQTT packets ( see

I've noticed that the maximum number of sockets that you can setup from make menuconfig is 16. 

All the values that you are setting from make menuconfig are ending in a file named sdkconfig in the root of you app directory. This sdkconfig file will be converted to sdkconfig.h located in app/build/include/sdkconfig.h.

Even you are modifying a value direct in the sdkconfig on the compile time you will be invited to enter a value 1..16 for maximum number of sockets.

Solution #1. (Safest one)

Change the sdkconfig.h file overwrite the desired value and recompile


Solution #2. (not recommended but possible )

Modify directly the file:


If you modified values in make menuconfig and you don't know what was before don't worry just do a diff between the app/sdkconfig and app/sdkconfig.old file.

Obs: this post can be found also on this link.

0 Response to "ESP32 - How to increase the maximum number of sockets"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel