Skip to content

ESP32: Migrate to Arduino 3.x (pioarduino)#9122

Merged
thebentern merged 75 commits into
developfrom
pioarduino
May 17, 2026
Merged

ESP32: Migrate to Arduino 3.x (pioarduino)#9122
thebentern merged 75 commits into
developfrom
pioarduino

Conversation

@vidplace7

@vidplace7 vidplace7 commented Dec 30, 2025

Copy link
Copy Markdown
Member

Switch all ESP32 builds to pioarduino/platform-espressif32.

https://docs.espressif.com/projects/arduino-esp32/en/latest/migration_guides/2.x_to_3.0.html

Switching to Arduino-ESP32 3.x will be necessary in order to properly support newer Espressif MCUs (esp32h2, esp32c5, esp32c6, esp32p4, etc)

DRAFT for now, see below.

TODO:

  • Test ESP32s3
    • heltec-v3
    • t-deck-tft
  • Test ESP32 (Original)
    • tbeam
    • tlora-v2-1-1_6
    • station-g1
  • Test ESP32c3
    • heltec-ht62-esp32c3-sx1262
  • Test ESP32c6
    • tlora-c6
    • m5stack-unitc6l
  • Test ESP32p4
    • @mverch67 added preliminary support for this platform as part of this PR.
      • crowpanel p4 advanced 5"
      • crowpanel p4 advanced 9"
      • crowpanel p4 advanced 10.1"

Tasks:

Depends on:


This PR is a continuation of the work in #8952

Huge shoutout / credit to @mverch67 who's initial work this is based upon #7180 ❤️

@vidplace7 vidplace7 added enhancement New feature or request hardware-support Hardware related: new devices or modules, problems specific to hardware labels Dec 30, 2025
Comment thread variants/esp32s3/elecrow_panel/platformio.ini
@cpatulea

cpatulea commented May 4, 2026

Copy link
Copy Markdown
Contributor

Commit aef13be on Heltec v3:

DEBUG | ??:??:?? 8 Init Web Server
INFO  | ??:??:?? 8 Start Secure Web Server
INFO  | ??:??:?? 8 Start Insecure Web Server
INFO  | ??:??:?? 8 Web Servers Ready! :-)
INFO  | ??:??:?? 8 API server listen on TCP port 4403
DEBUG | ??:??:?? 8 UDP Listening on IP: 192.168.0.38
WARN  | ??:??:?? 8 [WebServer] Low heap (10548 bytes), skipping HTTPS processing
...
WARN  | 23:34:45 69 [WebServer] Low heap (4836 bytes), skipping HTTPS processing
...
WARN  | 23:35:15 99 [WebServer] Low heap (4836 bytes), skipping HTTPS processing

Symptom:

$ curl -k -v https://esp32s3-3C7BE8.ht.home
* Host esp32s3-3C7BE8.ht.home:443 was resolved.
* IPv6: (none)
* IPv4: 192.168.0.38
*   Trying 192.168.0.38:443...
* ALPN: curl offers h2,http/1.1
* TLSv1.3 (OUT), TLS handshake, Client hello (1):

(hangs)

I think we have a lot of work to do to make HTTP work (#6960)

mariotti pushed a commit to mariotti/firmware that referenced this pull request May 6, 2026
…shtastic#9875)

Fixes this build error:

  <command-line>: error: expected unqualified-id before '-' token
  /home/<snip>/.platformio/packages/framework-arduinoespressif32/variants/esp32s3/pins_arduino.h:15:22: note: in expansion of macro 'LED_BUILTIN'
     15 | static const uint8_t LED_BUILTIN = SOC_GPIO_PIN_COUNT + PIN_RGB_LED;
        |                      ^~~~~~~~~~~

More info: meshtastic#9122 (comment)

The fix is consistent with variants/esp32s3/heltec_v3/platformio.ini

This commit is intentionally on the develop branch, because it's harmless to
develop branch, and makes us more ready for pioarduino when the time comes.

Heltec v4 introduced in: meshtastic#7845

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
mariotti pushed a commit to mariotti/firmware that referenced this pull request May 6, 2026
…gs" (meshtastic#10073)

This reverts commit 391928e.

Since esp32_https_server commit e2c9f98, this is no longer necessary.

Also, the esp32-common.ini '-include mbedtls/error.h' causes a build error
under IDF v5 (meshtastic#9122 (comment)):

  <command-line>: fatal error: mbedtls/error.h: No such file or directory

so this change fixes that error.
@thebentern thebentern marked this pull request as ready for review May 13, 2026 14:14
@thebentern

Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

Resolve conflict in src/nimble/NimbleBluetooth.cpp by keeping
pioarduino's Arduino BLE API (onPassKeyNotify callback, passkey
set via pSecurity->setPassKey at setup time). Develop's changes
(variable rename + showSimpleBanner) target the old NimBLE-Arduino
API which pioarduino no longer uses.

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

Copilot AI commented May 13, 2026

Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

Merge conflicts resolved in c360815. The conflict was in src/nimble/NimbleBluetooth.cpp — kept pioarduino's Arduino BLE API (onPassKeyNotify callback with passkey set via pSecurity->setPassKey() at setup time). Develop's changes targeted the old NimBLE-Arduino API which pioarduino replaced.

Copilot AI requested a review from thebentern May 13, 2026 16:29
@thebentern thebentern merged commit a541957 into develop May 17, 2026
80 checks passed
@caveman99 caveman99 deleted the pioarduino branch June 7, 2026 20:55
jeek pushed a commit to jeek/Meshtastic-Exploiteers-Hacker-Pager that referenced this pull request Jun 30, 2026
…shtastic#9875)

Fixes this build error:

  <command-line>: error: expected unqualified-id before '-' token
  /home/<snip>/.platformio/packages/framework-arduinoespressif32/variants/esp32s3/pins_arduino.h:15:22: note: in expansion of macro 'LED_BUILTIN'
     15 | static const uint8_t LED_BUILTIN = SOC_GPIO_PIN_COUNT + PIN_RGB_LED;
        |                      ^~~~~~~~~~~

More info: meshtastic#9122 (comment)

The fix is consistent with variants/esp32s3/heltec_v3/platformio.ini

This commit is intentionally on the develop branch, because it's harmless to
develop branch, and makes us more ready for pioarduino when the time comes.

Heltec v4 introduced in: meshtastic#7845

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

2.8 enhancement New feature or request hardware-support Hardware related: new devices or modules, problems specific to hardware

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants