Not enough program storage space

Hey everyone! I'm not sure what happened, but I keep getting this error when I try to upload my code, even though it used to work just fine. Everything was uploading in my ESP32 WROOM-32U without any issues before, but after resetting my laptop and reinstalling the IDE, I can't upload my code anymore, and I keep encountering this error. Any ideas on what I should do?

Sketch uses 1387077 bytes (105%) of program storage space. Maximum is 1310720 bytes.
Global variables use 52220 bytes (15%) of dynamic memory, leaving 275460 bytes for local variables. Maximum is 327680 bytes.
Sketch too big; see https://support.arduino.cc/hc/en-us/articles/360013825179 for tips on reducing it.
text section exceeds available space in board

Compilation error: text section exceeds available space in board

Wrong board/board settings ?

I'm using a webserver with an ESP32 set as an access point to access the IP address 192.168.1.4, and my code includes SQLite. When I remove SQLite and set my partition scheme to default, everything works fine. However, when I add SQLite, I get an error, even though it should work perfectly since it did before. If I set the partition scheme to No OTA (2MB APP/2MB SPIFFS), the code uploads with SQLite, but the webserver stops working, and I can no longer access 192.168.1.4.

If your'e sure about your board settings and only thing different is that you reinstalled ide, then maybe you installed esp32 core 3.x and before you had 2.x?

2 Likes

I don't see that board listed. The general solution is to select the most appropriate board then goto the Tools menu and 'configure' the IDE to match the board re partition sizes etc.

try changing the Tools>Board ESP32 Partition Scheme to "Huge App", e.g.

2 Likes

It works! Thank you.

probably worth clicking the Solution button at the bottom of the reply that answered the question - this helps others with a similar problem

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.