Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.Sign up
Sketch too big. BLEDevice::init() consumes 713 352 bytes of program storage #441
causes the program storage size of my sketch to increase by 713 352 bytes (and dynamic memory to jump by 51 272 bytes).
This is with ESP32_BLE_Arduino version 0.4.7
That doesn't leave much room for any other libraries.
I checked a compilation of an ESP-IDF application outside of the Arduino environment and then ran "make size-components" and obtained the following list:
Two lines are of particular interest to me:
With just a finger in the wind, these seem to be showing me that using Bluetooth is not "cheap" from a resource perspective. 500K of executable/ro-data and 50K of RAM seems to be on the right order.
I think from an ESP32 perspective, when we start to use ESP32 ... the cost "is what it is" and there is little that this library (which is a wrapper around the base ESP32 BLE libraries) can do.
referenced this issue
Mar 17, 2018
This saved me in a fast test 12kb of Flash (depents on your use of BLEUtils functions.)
Other things I check is to find and fix memory lecks or use the idf direct.
So I tried changing the partition sizes by modifying /expressif/esp32/tools/partitions/default.csv to
Which should have given the 2 app partititions 1,638,400 bytes, which is more than enough for the app including BT. But when compiling in Arduino IDE I still get
So it doesn't look like the partititions are being respected.
I then tried also altering
but get the same result.
Am I missing something trying to modifying the partitition size?
referenced this issue
Apr 21, 2018
I have a sketch that is using both various lib (wifi, ble, mdns etc..) and adjusting the partition size seems to be not enough (misses a few kb).
Is the new limit you proposed for the partition size a hard maximum ? or can it be increased further ? what would be the possible drawbacks of doing so ?
@hdavid try the partition layout mentioned in this link: https://desire.giesecke.tk/index.php/2018/01/30/change-partition-size/