• Skip to main content
  • Skip to primary sidebar

RNTLab.com

The Ultimate Shortcut to Learn Electronics and Programming with Open Source Hardware and Software

  • Courses
  • Forum
    • Forum
    • Ask Question
  • Shop
  • Account
  • Blog
  • Login

long compile time for ESP32 on arduino ide

Q&A Forum › long compile time for ESP32 on arduino ide
0 Vote Up Vote Down
Jim Roberts asked 5 years ago

When I first compile a sketch it takes 5-10minutes. I have to sit through this as I need to press the boot button to load the sketch when compiling is finished. (The sketches I’m compiling are simple ie blink etc.)

It takes slightly less time on future compiles but is still 2-3minutes.

On my Arduino Mega sketches are compiled in well under a minute.

Is this several minutes normal?

6 Answers
0 Vote Up Vote Down
Steve Mercer answered 5 years ago

It’s somewhat dependent on the speed of your computer but this is my experience too. From what I see it compiles all the libraries (Including ESP32 Core) every time. I believe with the ESP32 having things like WiFi, Bluetooth, SD Card etc that it just takes longer than other Arduino’s that don’t have those. Also, I think the Arduino IDE only uses one core of your processor.

You may like to try PlatformIO. It caches whatever it has already compiled so subsequent compiles are very snappy. It also appears to make use of all cores available so is faster on initial compile too.

These are my observations. I don’t know whether it’s all actually correct.

 

Also you may like to get yourself a board that does not require pushing a button. Two of my boards (Heltec WiFi Kit 32 and Arducam IOTAI) will upload and run without the button push.

1 Vote Up Vote Down
Sara Santos Staff answered 5 years ago

Hi Jim.
It is normal for the ESP32 to take a little more time to compile than the Arduino.
However, 5 to 10 minutes is a lot of time. As Steve mentioned it may be related to the speed of your computer.
You may also try Steve’s suggestion and see if using PlatformIO is faster than Arduino IDE.
Here’s a tutorial on how to get started: https://randomnerdtutorials.com/vs-code-platformio-ide-esp32-esp8266-arduino/
Regards,
Sara

0 Vote Up Vote Down
Sara Santos Staff answered 5 years ago

As for the boot button, you may take a look at this “solution”: https://randomnerdtutorials.com/solved-failed-to-connect-to-esp32-timed-out-waiting-for-packet-header/
Regards,
Sara

0 Vote Up Vote Down
Jim Roberts answered 5 years ago

Thanks for that.
I’ve done a bit of messing around today and found, through my Task Manager, that there is an IBM Trusteer Rapport program (which is required by online banking) that uses lots of resources during the compile (no idea why). If I shut this down the compile time drops to <25% of what it was.
Still not brilliant but I can live with this.
Even more liveable with if I use one of the boards you suggest which don’t need the boot button pressing,

0 Vote Up Vote Down
Sara Santos Staff answered 5 years ago

Hi Jim.
I also think that some antivirus slow down the compilation time. But, I’m not sure if that’s your case.
Regards,
Sara

0 Vote Up Vote Down
Jim Roberts answered 5 years ago

Thanks for answers Sara, lots to look into here.

Primary Sidebar

Login to Ask or Answer Questions

This Forum is private and it’s only available for members enrolled in our Courses.

Login »

Latest Course Updates

  • [New Edition] Build ESP32-CAM Projects eBook – 2nd Edition April 16, 2025
  • [eBook Updated] Learn ESP32 with Arduino IDE eBook – Version 3.2 April 16, 2025

You must be logged in to view this content.

Contact Support - Refunds - Privacy - Terms - MakerAdvisor.com - Member Login

Copyright © 2013-2025 · RandomNerdTutorials.com · All Rights Reserved

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.