diff --git a/src/helpers/TBeamBoard.h b/src/helpers/TBeamBoard.h index fc0d3b73..6c6367fa 100644 --- a/src/helpers/TBeamBoard.h +++ b/src/helpers/TBeamBoard.h @@ -37,6 +37,8 @@ public: power.setALDO2Voltage(3300); power.enableALDO2(); + pinMode(38,INPUT_PULLUP); + esp_reset_reason_t reason = esp_reset_reason(); if (reason == ESP_RST_DEEPSLEEP) { long wakeup_source = esp_sleep_get_ext1_wakeup_status(); diff --git a/variants/lilygo_tbeam/platformio.ini b/variants/lilygo_tbeam/platformio.ini index fdf833b1..f754896f 100644 --- a/variants/lilygo_tbeam/platformio.ini +++ b/variants/lilygo_tbeam/platformio.ini @@ -9,15 +9,23 @@ build_flags = -D WRAPPER_CLASS=CustomSX1276Wrapper -D LORA_TX_POWER=20 -D P_LORA_TX_LED=4 + -D PIN_BOARD_SDA=21 + -D PIN_BOARD_SCL=22 + -D PIN_USER_BTN=38 build_src_filter = ${esp32_base.build_src_filter} +<../variants/lilygo_tbeam> board_build.partitions = min_spiffs.csv ; get around 4mb flash limit +lib_deps = + ${esp32_base.lib_deps} + lewisxhe/XPowersLib@^0.2.7 + adafruit/Adafruit SSD1306 @ ^2.5.13 [env:Tbeam_companion_radio_ble] extends = LilyGo_TBeam board_build.upload.maximum_ram_size=2000000 build_flags = ${LilyGo_TBeam.build_flags} + -D DISPLAY_CLASS=SSD1306Display -D MAX_CONTACTS=100 -D MAX_GROUP_CHANNELS=1 -D BLE_PIN_CODE=123456 @@ -31,8 +39,8 @@ build_flags = ; -D MESH_DEBUG=1 build_src_filter = ${LilyGo_TBeam.build_src_filter} + - +<../examples/companion_radio/main.cpp> + + + +<../examples/companion_radio> lib_deps = ${LilyGo_TBeam.lib_deps} - densaugeo/base64 @ ~1.4.0 - lewisxhe/XPowersLib@^0.2.7 + densaugeo/base64 @ ~1.4.0 \ No newline at end of file