From 48838e21004be8099cd86c8ac7da0d998a878dea Mon Sep 17 00:00:00 2001 From: Mikhael Skvortsov Date: Sat, 25 May 2024 20:41:43 +0300 Subject: [PATCH] Work around BLE initialization failure on esp32s3 --- arch/esp32/esp32s3.ini | 4 ++++ variants/bpi_picow_esp32_s3/platformio.ini | 2 +- variants/esp32-s3-pico/platformio.ini | 2 +- variants/my_esp32s3_diy_eink/platformio.ini | 2 +- variants/my_esp32s3_diy_oled/platformio.ini | 2 +- variants/t-deck/platformio.ini | 2 +- variants/t-watch-s3/platformio.ini | 2 +- variants/tlora_t3s3_v1/platformio.ini | 2 +- variants/unphone/platformio.ini | 2 +- 9 files changed, 12 insertions(+), 8 deletions(-) diff --git a/arch/esp32/esp32s3.ini b/arch/esp32/esp32s3.ini index 6a1bdd3fd5..a18d4af5bb 100644 --- a/arch/esp32/esp32s3.ini +++ b/arch/esp32/esp32s3.ini @@ -3,3 +3,7 @@ extends = esp32_base monitor_speed = 115200 +# Work around BLE initialization failure +build_flags = + ${esp32_base.build_flags} + -DCONFIG_BT_NIMBLE_PINNED_TO_CORE=1 diff --git a/variants/bpi_picow_esp32_s3/platformio.ini b/variants/bpi_picow_esp32_s3/platformio.ini index 7e94cc97e2..83a42dd1ce 100644 --- a/variants/bpi_picow_esp32_s3/platformio.ini +++ b/variants/bpi_picow_esp32_s3/platformio.ini @@ -11,4 +11,4 @@ lib_deps = ${esp32_base.lib_deps} caveman99/ESP32 Codec2@^1.0.1 build_flags = - ${esp32_base.build_flags} -D PRIVATE_HW -I variants/bpi_picow_esp32_s3 \ No newline at end of file + ${esp32s3_base.build_flags} -D PRIVATE_HW -I variants/bpi_picow_esp32_s3 \ No newline at end of file diff --git a/variants/esp32-s3-pico/platformio.ini b/variants/esp32-s3-pico/platformio.ini index ff77c30e0e..a1e63139d2 100644 --- a/variants/esp32-s3-pico/platformio.ini +++ b/variants/esp32-s3-pico/platformio.ini @@ -11,7 +11,7 @@ board_upload.require_upload_port = yes ;upload_port = /dev/ttyACM0 -build_flags = ${esp32_base.build_flags} +build_flags = ${esp32s3_base.build_flags} -DESP32_S3_PICO ;-DPRIVATE_HW -Ivariants/esp32-s3-pico diff --git a/variants/my_esp32s3_diy_eink/platformio.ini b/variants/my_esp32s3_diy_eink/platformio.ini index e81f2c1abe..92ccdb7853 100644 --- a/variants/my_esp32s3_diy_eink/platformio.ini +++ b/variants/my_esp32s3_diy_eink/platformio.ini @@ -17,7 +17,7 @@ lib_deps = build_unflags = -DARDUINO_USB_MODE=1 build_flags = ;${esp32_base.build_flags} -D MY_ESP32S3_DIY -I variants/my_esp32s3_diy_eink - ${esp32_base.build_flags} -D PRIVATE_HW -I variants/my_esp32s3_diy_eink + ${esp32s3_base.build_flags} -D PRIVATE_HW -I variants/my_esp32s3_diy_eink -Dmy -DEINK_DISPLAY_MODEL=GxEPD2_290_T5D -DEINK_WIDTH=296 diff --git a/variants/my_esp32s3_diy_oled/platformio.ini b/variants/my_esp32s3_diy_oled/platformio.ini index 2d7a5cd910..3fb041236f 100644 --- a/variants/my_esp32s3_diy_oled/platformio.ini +++ b/variants/my_esp32s3_diy_oled/platformio.ini @@ -16,7 +16,7 @@ lib_deps = build_unflags = -DARDUINO_USB_MODE=1 build_flags = ;${esp32_base.build_flags} -D MY_ESP32S3_DIY -I variants/my_esp32s3_diy_oled - ${esp32_base.build_flags} -D PRIVATE_HW -I variants/my_esp32s3_diy_oled + ${esp32s3_base.build_flags} -D PRIVATE_HW -I variants/my_esp32s3_diy_oled -DBOARD_HAS_PSRAM -mfix-esp32-psram-cache-issue -DARDUINO_USB_MODE=0 \ No newline at end of file diff --git a/variants/t-deck/platformio.ini b/variants/t-deck/platformio.ini index a63ff57a75..6c02580cbe 100644 --- a/variants/t-deck/platformio.ini +++ b/variants/t-deck/platformio.ini @@ -6,7 +6,7 @@ board_check = true upload_protocol = esptool #upload_port = COM29 -build_flags = ${esp32_base.build_flags} +build_flags = ${esp32s3_base.build_flags} -DT_DECK -DBOARD_HAS_PSRAM -DMAX_THREADS=40 diff --git a/variants/t-watch-s3/platformio.ini b/variants/t-watch-s3/platformio.ini index 1f5fc278b3..d8ab50ca7e 100644 --- a/variants/t-watch-s3/platformio.ini +++ b/variants/t-watch-s3/platformio.ini @@ -5,7 +5,7 @@ board = t-watch-s3 board_check = true upload_protocol = esptool -build_flags = ${esp32_base.build_flags} +build_flags = ${esp32s3_base.build_flags} -DT_WATCH_S3 -Ivariants/t-watch-s3 -DPCF8563_RTC=0x51 diff --git a/variants/tlora_t3s3_v1/platformio.ini b/variants/tlora_t3s3_v1/platformio.ini index 002b2f224a..a1676175b2 100644 --- a/variants/tlora_t3s3_v1/platformio.ini +++ b/variants/tlora_t3s3_v1/platformio.ini @@ -5,5 +5,5 @@ board_check = true upload_protocol = esp-builtin build_flags = - ${esp32_base.build_flags} -D TLORA_T3S3_V1 -I variants/tlora_t3s3_v1 + ${esp32s3_base.build_flags} -D TLORA_T3S3_V1 -I variants/tlora_t3s3_v1 -DGPS_POWER_TOGGLE ; comment this line to disable triple press function on the user button to turn off gps entirely. \ No newline at end of file diff --git a/variants/unphone/platformio.ini b/variants/unphone/platformio.ini index 215978a5de..aa2acadd67 100644 --- a/variants/unphone/platformio.ini +++ b/variants/unphone/platformio.ini @@ -12,7 +12,7 @@ build_unflags = ${esp32s3_base.build_unflags} -D ARDUINO_USB_MODE -build_flags = ${esp32_base.build_flags} +build_flags = ${esp32s3_base.build_flags} ;-D BOARD_HAS_PSRAM // what's up with this - doesn't seem to be recognised at boot -D UNPHONE -I variants/unphone