Boot TX power was left at a conservative 10dBm (Heltec V4's pattern) with no way to raise it, unlike the T-Deck which boots straight at the chip's real 22dBm ceiling. On hardware this was silently degrading outbound range: adverts/DMs sent from the pager were unreliable while inbound reception was fine, since the far node's own TX power was unaffected. 22dBm is confirmed as this chip's actual sub-GHz HP-PA ceiling via RadioLib's LR1120::checkOutputPower() (LR1121 inherits it) and matches trail-mate's own working config for this board. Also widen the three RX-boosted-gain gates in MyMesh.cpp/DataStore.cpp that only checked USE_SX1262/USE_SX1268 to include USE_LR1121 -- CustomLR1121Wrapper already implements setRxBoostedGainMode/ getRxBoostedGainMode, so the setting was silently a no-op for this radio. Signed-off-by: Tesso M Costa <tesso.martins@gmail.com>
590 lines
19 KiB
INI
590 lines
19 KiB
INI
; wadamesh — Heltec V4 TFT touch firmware.
|
|
; Standalone PlatformIO project: the MeshCore core is consumed as a library
|
|
; (lib/MeshCore here; a git-tagged fork once published). This env is the flattened
|
|
; equivalent of meshcomod's heltec_v4_tft_companion_radio_usb_tcp_touch.
|
|
|
|
[platformio]
|
|
default_envs =
|
|
heltec_v4_tft_companion_radio_usb_tcp_touch
|
|
LilyGo_TDeck_companion_radio_touch
|
|
|
|
[env:heltec_v4_tft_companion_radio_usb_tcp_touch]
|
|
platform = platformio/espressif32@6.11.0
|
|
framework = arduino
|
|
board = heltec_v4
|
|
monitor_speed = 115200
|
|
board_build.partitions = partitions_tft_touch.csv
|
|
extra_scripts = pre:scripts/inject_wifi_env.py, merge-bin.py
|
|
|
|
build_flags =
|
|
-Wno-deprecated-declarations -Wno-unused-parameter -DNDEBUG -DRADIOLIB_STATIC_ONLY=1 -DRADIOLIB_GODMODE=1
|
|
-D MC_VENDORED_TOUCH_APP
|
|
; NOTE: tried -D ARDUINO_USB_MODE=1 (HW-CDC, drops unused TinyUSB MSC/DFU ≈ 12 KB internal
|
|
; DRAM) — but on the real V4 the binary companion link regressed: small per-message frames
|
|
; arrived yet the larger device-profile frame (node name + keys) dropped bytes over HW-CDC's
|
|
; smaller TX FIFO. Reverted to the board JSON's TinyUSB CDC. Revisit only with an HW-CDC TX
|
|
; buffer/DTR-wait fix verified on hardware. (T-Deck ships MODE=1 and is fine — board-specific.)
|
|
-D LORA_FREQ=869.618
|
|
-D LORA_BW=62.5
|
|
-D LORA_SF=8
|
|
-D ENABLE_PRIVATE_KEY_IMPORT=1
|
|
-D ENABLE_PRIVATE_KEY_EXPORT=1
|
|
-D RADIOLIB_EXCLUDE_CC1101=1
|
|
-D RADIOLIB_EXCLUDE_RF69=1
|
|
-D RADIOLIB_EXCLUDE_SX1231=1
|
|
-D RADIOLIB_EXCLUDE_SI443X=1
|
|
-D RADIOLIB_EXCLUDE_RFM2X=1
|
|
-D RADIOLIB_EXCLUDE_SX128X=1
|
|
-D RADIOLIB_EXCLUDE_AFSK=1
|
|
-D RADIOLIB_EXCLUDE_AX25=1
|
|
-D RADIOLIB_EXCLUDE_HELLSCHREIBER=1
|
|
-D RADIOLIB_EXCLUDE_MORSE=1
|
|
-D RADIOLIB_EXCLUDE_APRS=1
|
|
-D RADIOLIB_EXCLUDE_BELL=1
|
|
-D RADIOLIB_EXCLUDE_RTTY=1
|
|
-D RADIOLIB_EXCLUDE_SSTV=1
|
|
-D ESP32_PLATFORM
|
|
; --- sensors ---
|
|
-D ENV_INCLUDE_GPS=1
|
|
-D ENV_INCLUDE_AHTX0=1
|
|
-D ENV_INCLUDE_BME280=1
|
|
-D ENV_INCLUDE_BMP280=1
|
|
-D ENV_INCLUDE_SHTC3=1
|
|
-D ENV_INCLUDE_SHT4X=1
|
|
-D ENV_INCLUDE_LPS22HB=1
|
|
-D ENV_INCLUDE_INA3221=1
|
|
-D ENV_INCLUDE_INA219=1
|
|
-D ENV_INCLUDE_INA226=1
|
|
-D ENV_INCLUDE_INA260=1
|
|
-D ENV_INCLUDE_MLX90614=1
|
|
-D ENV_INCLUDE_VL53L0X=1
|
|
-D ENV_INCLUDE_BME680=1
|
|
-D ENV_INCLUDE_BMP085=1
|
|
; --- Heltec LoRa32 V4 board ---
|
|
-I variants/heltec_v4
|
|
-D HELTEC_LORA_V4
|
|
-D USE_SX1262
|
|
-D ESP32_CPU_FREQ=80
|
|
-D RADIO_CLASS=CustomSX1262
|
|
-D WRAPPER_CLASS=CustomSX1262Wrapper
|
|
-D P_LORA_TX_LED=35
|
|
-D P_LORA_DIO_1=14
|
|
-D P_LORA_NSS=8
|
|
-D P_LORA_RESET=12
|
|
-D P_LORA_BUSY=13
|
|
-D P_LORA_SCLK=9
|
|
-D P_LORA_MISO=11
|
|
-D P_LORA_MOSI=10
|
|
-D P_LORA_PA_POWER=7
|
|
-D P_LORA_PA_EN=2
|
|
-D P_LORA_PA_TX_EN=46
|
|
-D P_LORA_GC1109_PA_EN=2
|
|
-D P_LORA_GC1109_PA_TX_EN=46
|
|
-D P_LORA_KCT8103L_PA_CSD=2
|
|
-D P_LORA_KCT8103L_PA_CTX=5
|
|
-D PIN_USER_BTN=0
|
|
-D PIN_VEXT_EN=36
|
|
-D PIN_VEXT_EN_ACTIVE=HIGH
|
|
-D LORA_TX_POWER=10
|
|
-D MAX_LORA_TX_POWER=22
|
|
-D SX126X_REGISTER_PATCH=1
|
|
-D SX126X_DIO2_AS_RF_SWITCH=true
|
|
-D SX126X_DIO3_TCXO_VOLTAGE=1.8
|
|
-D SX126X_CURRENT_LIMIT=140
|
|
-D SX126X_RX_BOOSTED_GAIN=1
|
|
-D PIN_GPS_RX=38
|
|
-D PIN_GPS_TX=39
|
|
-D PIN_GPS_RESET=42
|
|
-D PIN_GPS_RESET_ACTIVE=LOW
|
|
-D PIN_GPS_EN=34
|
|
-D PIN_GPS_EN_ACTIVE=LOW
|
|
-D PIN_ADC_CTRL=37
|
|
-D PIN_VBAT_READ=1
|
|
; --- TFT ---
|
|
-D HELTEC_LORA_V4_TFT
|
|
-D PIN_BOARD_SDA=4
|
|
-D PIN_BOARD_SCL=3
|
|
-D DISPLAY_ROTATION=2
|
|
-D DISPLAY_SCALE_X=1.0
|
|
-D DISPLAY_SCALE_Y=1.0
|
|
-D PIN_TFT_RST=18
|
|
-D PIN_TFT_VDD_CTL=-1
|
|
-D PIN_TFT_LEDA_CTL=21
|
|
-D PIN_TFT_LEDA_CTL_ACTIVE=HIGH
|
|
-D PIN_TFT_CS=15
|
|
-D PIN_TFT_DC=16
|
|
-D PIN_TFT_SCL=17
|
|
-D PIN_TFT_SDA=33
|
|
; --- CHSC6x cap touch ---
|
|
-D HAS_HELTEC_V4_CAP_TOUCH=1
|
|
-D PIN_TOUCH_SDA=47
|
|
-D PIN_TOUCH_SCL=48
|
|
-D PIN_TOUCH_RST=44
|
|
-D HELTEC_V4_BUZZER_PIN=6
|
|
; --- touch UI / companion stack ---
|
|
-I include
|
|
-I src
|
|
-I src/ui-touch
|
|
-D UI_LVGL=1
|
|
-D HAS_TOUCH_UI=1
|
|
; Heltec V4 Expansion Kit: local environment sensors UI (Sensors tab, Home env
|
|
; widget, Local-Sensors page). Board-gated — only this env compiles it.
|
|
-D HAS_EXPANSION_KIT=1
|
|
-D FIRMWARE_OTA_ENV='"heltec_v4_tft_companion_radio_usb_tcp_touch"'
|
|
-D ENABLE_ADVERT_ON_BOOT=0
|
|
-D LV_CONF_PATH=lv_conf.h
|
|
-D LV_CONF_INCLUDE_SIMPLE=1
|
|
; Smoother scroll: lower deceleration than LVGL's default (10) so flicks glide
|
|
; longer instead of stopping abruptly. lv_conf leaves this unset, so this -D wins.
|
|
-D LV_INDEV_DEF_SCROLL_THROW=7
|
|
-D USER_SETUP_LOADED=1
|
|
-D ST7789_DRIVER=1
|
|
-D TFT_WIDTH=240
|
|
-D TFT_HEIGHT=320
|
|
-D TFT_MOSI=33
|
|
-D TFT_SCLK=17
|
|
-D TFT_CS=15
|
|
-D TFT_DC=16
|
|
-D TFT_RST=18
|
|
-D TFT_MISO=-1
|
|
-D SPI_FREQUENCY=80000000
|
|
-D TFT_RGB_ORDER=TFT_RGB
|
|
-D TFT_INVERSION_ON=1
|
|
-D TFT_BL=21
|
|
-D TFT_BACKLIGHT_ON=1
|
|
-D MAX_CONTACTS=2000
|
|
-D MAX_GROUP_CHANNELS=40
|
|
-D DISPLAY_CLASS=ST7789LCDDisplay
|
|
-D ADMIN_PASSWORD='"password"'
|
|
-D MULTI_TRANSPORT_COMPANION=1
|
|
-D WADAMESH_FORK_BUILD=1
|
|
-D TCP_PORT=5000
|
|
-D WS_PORT=8765
|
|
-D BLE_PIN_CODE=123456
|
|
-D CONFIG_MBEDTLS_ASYMMETRIC_CONTENT_LEN=1
|
|
-D CONFIG_MBEDTLS_SSL_IN_CONTENT_LEN=16384
|
|
-D CONFIG_MBEDTLS_SSL_OUT_CONTENT_LEN=4096
|
|
|
|
build_src_filter =
|
|
+<*.cpp>
|
|
+<*.c>
|
|
+<helpers/*.cpp>
|
|
+<helpers/esp32/*.cpp>
|
|
+<helpers/input/*.cpp>
|
|
+<ui-touch/*.cpp>
|
|
+<ui-touch/*.c>
|
|
+<../variants/heltec_v4/*.cpp>
|
|
|
|
lib_deps =
|
|
; MeshCore core = the meshcomod monorepo built as a lib, pinned by tag.
|
|
; Touch-app files (TouchPrefsStore, WifiRuntimeStore, transports, ...) are
|
|
; vendored in this app's src/ and dropped from the lib via -DMC_VENDORED_TOUCH_APP.
|
|
https://github.com/ALLFATHER-BV/meshcomod.git#core-v1.16.5
|
|
SPI
|
|
Wire
|
|
jgromes/RadioLib @ ^7.6.0
|
|
rweather/Crypto @ ^0.4.0
|
|
adafruit/RTClib @ ^2.1.3
|
|
melopero/Melopero RV3028 @ ^1.1.0
|
|
electroniccats/CayenneLPP @ 1.6.1
|
|
h2zero/NimBLE-Arduino @ 1.4.3
|
|
adafruit/Adafruit INA3221 Library @ ^1.0.1
|
|
adafruit/Adafruit INA219 @ ^1.2.3
|
|
robtillaart/INA226 @ ^0.6.4
|
|
adafruit/Adafruit INA260 Library @ ^1.5.3
|
|
adafruit/Adafruit AHTX0 @ ^2.0.5
|
|
adafruit/Adafruit BME280 Library @ ^2.3.0
|
|
adafruit/Adafruit BMP280 Library @ ^2.6.8
|
|
adafruit/Adafruit SHTC3 Library @ ^1.0.1
|
|
sensirion/Sensirion I2C SHT4x @ ^1.1.2
|
|
arduino-libraries/Arduino_LPS22HB @ ^1.0.2
|
|
adafruit/Adafruit MLX90614 Library @ ^2.1.5
|
|
adafruit/Adafruit_VL53L0X @ ^1.2.4
|
|
stevemarple/MicroNMEA @ ^2.0.6
|
|
adafruit/Adafruit BME680 Library @ ^2.0.4
|
|
adafruit/Adafruit BMP085 Library @ ^1.2.4
|
|
adafruit/Adafruit ST7735 and ST7789 Library @ ^1.11.0
|
|
https://github.com/Quency-D/chsc6x/archive/5cbead829d6b432a8d621ed1aafd4eb474fd4f27.zip
|
|
ESP32Async/ESPAsyncWebServer @ 3.10.3
|
|
file://arch/esp32/AsyncElegantOTA
|
|
lvgl/lvgl @ ^8.3.11
|
|
bodmer/TFT_eSPI @ ^2.5.43
|
|
densaugeo/base64 @ ~1.4.0
|
|
knolleary/PubSubClient @ ^2.8.0
|
|
|
|
; ======================================================================
|
|
; LilyGo T-Deck / T-Deck Plus — flattened equivalent of meshcomod's
|
|
; LilyGo_TDeck_companion_radio_touch. ST7789 via Adafruit (not TFT_eSPI);
|
|
; GT911 touch + matrix keyboard + trackball; sensors off except GPS.
|
|
; ======================================================================
|
|
[env:LilyGo_TDeck_companion_radio_touch]
|
|
platform = platformio/espressif32@6.11.0
|
|
framework = arduino
|
|
board = t-deck
|
|
monitor_speed = 115200
|
|
board_build.partitions = variants/lilygo_tdeck/partitions_tdeck_touch.csv
|
|
extra_scripts = pre:scripts/inject_wifi_env.py, merge-bin.py
|
|
|
|
build_flags =
|
|
-Wno-deprecated-declarations -Wno-unused-parameter -DNDEBUG -DRADIOLIB_STATIC_ONLY=1 -DRADIOLIB_GODMODE=1
|
|
-D MC_VENDORED_TOUCH_APP
|
|
-D LORA_FREQ=869.618
|
|
-D LORA_BW=62.5
|
|
-D LORA_SF=8
|
|
-D ENABLE_PRIVATE_KEY_IMPORT=1
|
|
-D ENABLE_PRIVATE_KEY_EXPORT=1
|
|
-D RADIOLIB_EXCLUDE_CC1101=1
|
|
-D RADIOLIB_EXCLUDE_RF69=1
|
|
-D RADIOLIB_EXCLUDE_SX1231=1
|
|
-D RADIOLIB_EXCLUDE_SI443X=1
|
|
-D RADIOLIB_EXCLUDE_RFM2X=1
|
|
-D RADIOLIB_EXCLUDE_SX128X=1
|
|
-D RADIOLIB_EXCLUDE_AFSK=1
|
|
-D RADIOLIB_EXCLUDE_AX25=1
|
|
-D RADIOLIB_EXCLUDE_HELLSCHREIBER=1
|
|
-D RADIOLIB_EXCLUDE_MORSE=1
|
|
-D RADIOLIB_EXCLUDE_APRS=1
|
|
-D RADIOLIB_EXCLUDE_BELL=1
|
|
-D RADIOLIB_EXCLUDE_RTTY=1
|
|
-D RADIOLIB_EXCLUDE_SSTV=1
|
|
-D ESP32_PLATFORM
|
|
; --- T-Deck board ---
|
|
-I variants/lilygo_tdeck
|
|
-D LILYGO_TDECK
|
|
-D BOARD_HAS_PSRAM=1
|
|
; 0 = silence ARDUHAL [E] spam (benign vfs_api cache-miss "no permits for
|
|
; creation" + Preferences nvs_open NOT_FOUND on first-namespace-access) that
|
|
; also pollutes the USB-CDC companion stream. Our own Serial.printf logs stay.
|
|
-D CORE_DEBUG_LEVEL=0
|
|
-D ARDUINO_USB_CDC_ON_BOOT=1
|
|
-D PIN_USER_BTN=0
|
|
-D PIN_PERF_POWERON=10
|
|
-D USE_SX1262
|
|
-D RADIO_CLASS=CustomSX1262
|
|
-D WRAPPER_CLASS=CustomSX1262Wrapper
|
|
-D LORA_TX_POWER=22
|
|
; The T-Deck's SX1262 antenna (TX/RX) switch is driven by DIO2 — this MUST be
|
|
; true. With it false, setDio2AsRfSwitch(false) leaves the switch uncontrolled,
|
|
; so on TX the +22 dBm PA is never routed to the antenna (~16 dB loss -> ~4 mW).
|
|
; That was issue #6. (Meshtastic's T-Deck + the Heltec V4 here + every other
|
|
; MeshCore SX1262 variant use true; the T-Deck was the lone outlier.)
|
|
-D SX126X_DIO2_AS_RF_SWITCH=true
|
|
-D SX126X_CURRENT_LIMIT=140
|
|
-D SX126X_RX_BOOSTED_GAIN=1
|
|
-D SX126X_DIO3_TCXO_VOLTAGE=1.8f
|
|
-D P_LORA_DIO_1=45
|
|
-D P_LORA_NSS=9
|
|
-D P_LORA_RESET=17
|
|
-D P_LORA_BUSY=13
|
|
-D P_LORA_SCLK=40
|
|
-D P_LORA_MISO=38
|
|
-D P_LORA_MOSI=41
|
|
-D ENV_INCLUDE_GPS=1
|
|
-D ENV_SKIP_GPS_DETECT=1
|
|
-D ENV_INCLUDE_AHTX0=0
|
|
-D ENV_INCLUDE_BME280=0
|
|
-D ENV_INCLUDE_BMP280=0
|
|
-D ENV_INCLUDE_SHTC3=0
|
|
-D ENV_INCLUDE_SHT4X=0
|
|
-D ENV_INCLUDE_LPS22HB=0
|
|
-D ENV_INCLUDE_INA3221=0
|
|
-D ENV_INCLUDE_INA219=0
|
|
-D ENV_INCLUDE_INA226=0
|
|
-D ENV_INCLUDE_INA260=0
|
|
-D ENV_INCLUDE_MLX90614=0
|
|
-D ENV_INCLUDE_VL53L0X=0
|
|
-D ENV_INCLUDE_BME680=0
|
|
-D ENV_INCLUDE_BMP085=0
|
|
-D DISPLAY_SCALE_X=1.0
|
|
-D DISPLAY_SCALE_Y=1.0
|
|
-D PIN_TFT_RST=-1
|
|
-D PIN_TFT_VDD_CTL=-1
|
|
-D PIN_TFT_LEDA_CTL=42
|
|
-D PIN_TFT_CS=12
|
|
-D PIN_TFT_DC=11
|
|
-D PIN_TFT_SCL=40
|
|
-D PIN_TFT_SDA=41
|
|
-D PIN_GPS_RX=43
|
|
-D PIN_GPS_TX=44
|
|
-D GPS_BAUD_RATE=38400
|
|
; --- touch UI / companion stack ---
|
|
-I include
|
|
-I src
|
|
-I src/ui-touch
|
|
-D UI_LVGL=1
|
|
-D HAS_TOUCH_UI=1
|
|
-D FIRMWARE_OTA_ENV='"LilyGo_TDeck_companion_radio_touch"'
|
|
-D HAS_TDECK_GT911=1
|
|
-D HAS_TDECK_TRACKBALL=1
|
|
-D HAS_TDECK_KEYBOARD=1
|
|
-D ENABLE_ADVERT_ON_BOOT=0
|
|
-D PIN_TB_UP=15
|
|
-D PIN_TB_DOWN=3
|
|
-D PIN_TB_LEFT=2
|
|
-D PIN_TB_RIGHT=1
|
|
-D LV_CONF_PATH=lv_conf.h
|
|
-D LV_CONF_INCLUDE_SIMPLE=1
|
|
; Smoother scroll: lower deceleration than LVGL's default (10) so flicks glide
|
|
; longer instead of stopping abruptly. lv_conf leaves this unset, so this -D wins.
|
|
-D LV_INDEV_DEF_SCROLL_THROW=7
|
|
-D MAX_CONTACTS=2000
|
|
-D MAX_GROUP_CHANNELS=40
|
|
-D DISPLAY_CLASS=ST7789LCDDisplay
|
|
-D ADMIN_PASSWORD='"password"'
|
|
-D MULTI_TRANSPORT_COMPANION=1
|
|
-D WADAMESH_FORK_BUILD=1
|
|
-D TCP_PORT=5000
|
|
-D WS_PORT=8765
|
|
-D BLE_PIN_CODE=123456
|
|
-D CONFIG_MBEDTLS_ASYMMETRIC_CONTENT_LEN=1
|
|
-D CONFIG_MBEDTLS_SSL_IN_CONTENT_LEN=16384
|
|
-D CONFIG_MBEDTLS_SSL_OUT_CONTENT_LEN=4096
|
|
|
|
build_src_filter =
|
|
+<*.cpp>
|
|
+<*.c>
|
|
+<helpers/*.cpp>
|
|
+<helpers/esp32/*.cpp>
|
|
+<helpers/input/*.cpp>
|
|
+<ui-touch/*.cpp>
|
|
+<ui-touch/*.c>
|
|
+<../variants/lilygo_tdeck/*.cpp>
|
|
|
|
lib_deps =
|
|
https://github.com/ALLFATHER-BV/meshcomod.git#core-v1.16.5
|
|
SPI
|
|
Wire
|
|
jgromes/RadioLib @ ^7.6.0
|
|
rweather/Crypto @ ^0.4.0
|
|
adafruit/RTClib @ ^2.1.3
|
|
melopero/Melopero RV3028 @ ^1.1.0
|
|
electroniccats/CayenneLPP @ 1.6.1
|
|
h2zero/NimBLE-Arduino @ 1.4.3
|
|
adafruit/Adafruit INA3221 Library @ ^1.0.1
|
|
adafruit/Adafruit INA219 @ ^1.2.3
|
|
robtillaart/INA226 @ ^0.6.4
|
|
adafruit/Adafruit INA260 Library @ ^1.5.3
|
|
adafruit/Adafruit AHTX0 @ ^2.0.5
|
|
adafruit/Adafruit BME280 Library @ ^2.3.0
|
|
adafruit/Adafruit BMP280 Library @ ^2.6.8
|
|
adafruit/Adafruit SHTC3 Library @ ^1.0.1
|
|
sensirion/Sensirion I2C SHT4x @ ^1.1.2
|
|
arduino-libraries/Arduino_LPS22HB @ ^1.0.2
|
|
adafruit/Adafruit MLX90614 Library @ ^2.1.5
|
|
adafruit/Adafruit_VL53L0X @ ^1.2.4
|
|
stevemarple/MicroNMEA @ ^2.0.6
|
|
adafruit/Adafruit BME680 Library @ ^2.0.4
|
|
adafruit/Adafruit BMP085 Library @ ^1.2.4
|
|
adafruit/Adafruit ST7735 and ST7789 Library @ ^1.11.0
|
|
ESP32Async/ESPAsyncWebServer @ 3.10.3
|
|
file://arch/esp32/AsyncElegantOTA
|
|
lvgl/lvgl @ ^8.3.11
|
|
densaugeo/base64 @ ~1.4.0
|
|
knolleary/PubSubClient @ ^2.8.0
|
|
|
|
[env:tlora_pager_lr1121_companion_radio_touch]
|
|
platform = platformio/espressif32@6.11.0
|
|
framework = arduino
|
|
board = lilygo-t-lora-pager
|
|
monitor_speed = 115200
|
|
board_build.partitions = variants/lilygo_tlora_pager/partitions_tlora_pager_touch.csv
|
|
extra_scripts = pre:scripts/inject_wifi_env.py, merge-bin.py
|
|
|
|
build_flags =
|
|
-Wno-deprecated-declarations -Wno-unused-parameter -DNDEBUG -DRADIOLIB_STATIC_ONLY=1 -DRADIOLIB_GODMODE=1
|
|
-D MC_VENDORED_TOUCH_APP
|
|
-D LORA_FREQ=869.618
|
|
-D LORA_BW=62.5
|
|
-D LORA_SF=8
|
|
-D ENABLE_PRIVATE_KEY_IMPORT=1
|
|
-D ENABLE_PRIVATE_KEY_EXPORT=1
|
|
-D RADIOLIB_EXCLUDE_CC1101=1
|
|
-D RADIOLIB_EXCLUDE_RF69=1
|
|
-D RADIOLIB_EXCLUDE_SX1231=1
|
|
-D RADIOLIB_EXCLUDE_SI443X=1
|
|
-D RADIOLIB_EXCLUDE_RFM2X=1
|
|
-D RADIOLIB_EXCLUDE_SX128X=1
|
|
-D RADIOLIB_EXCLUDE_AFSK=1
|
|
-D RADIOLIB_EXCLUDE_AX25=1
|
|
-D RADIOLIB_EXCLUDE_HELLSCHREIBER=1
|
|
-D RADIOLIB_EXCLUDE_MORSE=1
|
|
-D RADIOLIB_EXCLUDE_APRS=1
|
|
-D RADIOLIB_EXCLUDE_BELL=1
|
|
-D RADIOLIB_EXCLUDE_RTTY=1
|
|
-D RADIOLIB_EXCLUDE_SSTV=1
|
|
; LR11X0 stays IN (that's our radio family); SX126X isn't used by this env at all.
|
|
-D RADIOLIB_EXCLUDE_SX126X=1
|
|
-D ESP32_PLATFORM
|
|
; --- T-LoRa Pager board ---
|
|
-I variants/lilygo_tlora_pager
|
|
-D TLORA_PAGER=1
|
|
-D BOARD_HAS_PSRAM=1
|
|
; 0 = silence ARDUHAL [E] spam, same rationale as the other two envs.
|
|
-D CORE_DEBUG_LEVEL=0
|
|
-D ARDUINO_USB_CDC_ON_BOOT=1
|
|
-D PIN_USER_BTN=0
|
|
-D USE_LR1121=1
|
|
-D RADIO_CLASS=CustomLR1121
|
|
-D WRAPPER_CLASS=CustomLR1121Wrapper
|
|
; Full sub-GHz HP-PA power on boot, matching the T-Deck's own LORA_TX_POWER=22
|
|
; (not Heltec V4's conservative-10-then-raise-in-Settings pattern). +22dBm is
|
|
; this chip's real ceiling for freq < 1GHz -- confirmed against RadioLib's
|
|
; pinned LR1120::checkOutputPower() (LR1121 inherits it: HP PA auto-selects
|
|
; above 14dBm, valid range -9..22) and trail-mate's own
|
|
; TRAIL_MATE_LORA_TX_POWER_MAX_DBM=22 for this exact board -- not a guess
|
|
; carried over from the sibling boards. A weak default here (10dBm, ~16x less
|
|
; power) was silently degrading outbound range on real hardware: adverts/DMs
|
|
; sent FROM the pager were unreliable while inbound reception was fine, since
|
|
; the far node's own TX was unaffected.
|
|
-D LORA_TX_POWER=22
|
|
-D P_LORA_DIO_1=14
|
|
-D P_LORA_NSS=36
|
|
-D P_LORA_RESET=47
|
|
-D P_LORA_BUSY=48
|
|
-D P_LORA_SCLK=35
|
|
-D P_LORA_MISO=33
|
|
-D P_LORA_MOSI=34
|
|
-D ENV_INCLUDE_GPS=1
|
|
-D ENV_SKIP_GPS_DETECT=1
|
|
-D ENV_INCLUDE_AHTX0=0
|
|
-D ENV_INCLUDE_BME280=0
|
|
-D ENV_INCLUDE_BMP280=0
|
|
-D ENV_INCLUDE_SHTC3=0
|
|
-D ENV_INCLUDE_SHT4X=0
|
|
-D ENV_INCLUDE_LPS22HB=0
|
|
-D ENV_INCLUDE_INA3221=0
|
|
-D ENV_INCLUDE_INA219=0
|
|
-D ENV_INCLUDE_INA226=0
|
|
-D ENV_INCLUDE_INA260=0
|
|
-D ENV_INCLUDE_MLX90614=0
|
|
-D ENV_INCLUDE_VL53L0X=0
|
|
-D ENV_INCLUDE_BME680=0
|
|
-D ENV_INCLUDE_BMP085=0
|
|
-D DISPLAY_SCALE_X=1.0
|
|
-D DISPLAY_SCALE_Y=1.0
|
|
; AW9364 backlight enable/pulse pin (ST7796LCDDisplay owns brightness -- see
|
|
; the CGRAM_OFFSET comment below for why this isn't a plain PWM pin).
|
|
-D PIN_TFT_LEDA_CTL=42
|
|
; Swapped vs. trail-mate's raw GPS_RX=4/GPS_TX=12: wadamesh's core calls
|
|
; Serial1.setPins(PIN_GPS_TX, PIN_GPS_RX), and HardwareSerial::setPins()
|
|
; takes (rxPin, txPin) -- so PIN_GPS_TX must be the ESP's own RX pin (4) and
|
|
; PIN_GPS_RX the ESP's own TX pin (12). See TLORA_PAGER_PORT.md Risk 1c.
|
|
-D PIN_GPS_RX=12
|
|
-D PIN_GPS_TX=4
|
|
-D GPS_BAUD_RATE=38400
|
|
; --- touch UI / companion stack ---
|
|
-I include
|
|
-I src
|
|
-I src/ui-touch
|
|
-D UI_LVGL=1
|
|
-D HAS_TOUCH_UI=1
|
|
-D FIRMWARE_OTA_ENV='"tlora_pager_lr1121_companion_radio_touch"'
|
|
-D HAS_PAGER_KEYBOARD=1
|
|
-D HAS_PAGER_ENCODER=1
|
|
-D KB_INT=6
|
|
-D KB_BACKLIGHT=46
|
|
-D ROTARY_A=40
|
|
-D ROTARY_B=41
|
|
-D ROTARY_C=7
|
|
-D ENABLE_ADVERT_ON_BOOT=0
|
|
-D LV_CONF_PATH=lv_conf.h
|
|
-D LV_CONF_INCLUDE_SIMPLE=1
|
|
; Smoother scroll: lower deceleration than LVGL's default (10) so flicks glide
|
|
; longer instead of stopping abruptly. lv_conf leaves this unset, so this -D wins.
|
|
-D LV_INDEV_DEF_SCROLL_THROW=7
|
|
-D MAX_CONTACTS=2000
|
|
-D MAX_GROUP_CHANNELS=40
|
|
-D DISPLAY_CLASS=ST7796LCDDisplay
|
|
-D ADMIN_PASSWORD='"password"'
|
|
-D MULTI_TRANSPORT_COMPANION=1
|
|
-D WADAMESH_FORK_BUILD=1
|
|
-D TCP_PORT=5000
|
|
-D WS_PORT=8765
|
|
-D BLE_PIN_CODE=123456
|
|
-D CONFIG_MBEDTLS_ASYMMETRIC_CONTENT_LEN=1
|
|
-D CONFIG_MBEDTLS_SSL_IN_CONTENT_LEN=16384
|
|
-D CONFIG_MBEDTLS_SSL_OUT_CONTENT_LEN=4096
|
|
; --- ST7796 display (TFT_eSPI) ---
|
|
-D USER_SETUP_LOADED=1
|
|
-D ST7796_DRIVER=1
|
|
; REQUIRED: this panel's 222px glass is narrower than the ST7796 controller's
|
|
; 320px GRAM. TFT_eSPI's ST7796_Rotation.h only applies the needed 49px
|
|
; column/row offset when this is defined (unlike ST7789, it isn't automatic
|
|
; for ST7796) -- ST7796LCDDisplay.cpp #errors at compile time without it.
|
|
-D CGRAM_OFFSET=1
|
|
; REQUIRED on ESP32-S3: TFT_eSPI_ESP32_S3.h's raw register macros (_spi_user,
|
|
; _spi_cmd, _spi_mosi_dlen -- used by begin_tft_write()/TFT_WRITE_BITS) take
|
|
; SPI_PORT and feed it straight into IDF's SPI_USER_REG(i)/REG_SPI_BASE(i),
|
|
; which only resolves to a real peripheral for i>=2 (SPI2/SPI3); i<2 returns
|
|
; base address 0. Leaving both USE_HSPI_PORT/USE_FSPI_PORT undefined makes
|
|
; that file fall back to SPI_PORT=FSPI, but FSPI is the *Arduino* enum value
|
|
; (0 on S3) rather than the raw IDF host index TFT_eSPI's own macros need --
|
|
; so _spi_user resolves to address 0x10, and the very first writecommand()
|
|
; in ST7796LCDDisplay::begin()/TFT_eSPI::init() hard-crashes with a
|
|
; StoreProhibited panic (confirmed on hardware: black screen, boot-looping
|
|
; "Guru Meditation Error" at TFT_eSPI::begin_tft_write()). USE_FSPI_PORT
|
|
; forces SPI_PORT=2 (real SPI2/"GPSPI2") consistently across both the raw
|
|
; macros and the SPIClass(FSPI) object TFT_eSPI constructs internally.
|
|
; USE_HSPI_PORT (real SPI3) is deliberately NOT used here instead: the
|
|
; radio's own `SPIClass spi` (variants/lilygo_tlora_pager/target.cpp) takes
|
|
; its default ctor arg (HSPI), which the Arduino core also maps to real
|
|
; SPI3 -- so picking HSPI for the display would put both peripherals on the
|
|
; same physical SPI host and conflict.
|
|
-D USE_FSPI_PORT=1
|
|
-D TFT_WIDTH=222
|
|
-D TFT_HEIGHT=480
|
|
-D TFT_MOSI=34
|
|
-D TFT_SCLK=35
|
|
-D TFT_CS=38
|
|
-D TFT_DC=37
|
|
-D TFT_RST=-1
|
|
-D TFT_MISO=33
|
|
-D TFT_BL=-1
|
|
; trail-mate's kPagerDisplaySpiClockMhz = 80.
|
|
-D SPI_FREQUENCY=80000000
|
|
|
|
build_src_filter =
|
|
+<*.cpp>
|
|
+<*.c>
|
|
+<helpers/*.cpp>
|
|
+<helpers/esp32/*.cpp>
|
|
+<helpers/input/*.cpp>
|
|
+<helpers/ui/*.cpp>
|
|
+<ui-touch/*.cpp>
|
|
+<ui-touch/*.c>
|
|
+<../variants/lilygo_tlora_pager/*.cpp>
|
|
|
|
lib_deps =
|
|
https://github.com/ALLFATHER-BV/meshcomod.git#core-v1.16.5
|
|
SPI
|
|
Wire
|
|
jgromes/RadioLib @ ^7.6.0
|
|
rweather/Crypto @ ^0.4.0
|
|
adafruit/RTClib @ ^2.1.3
|
|
melopero/Melopero RV3028 @ ^1.1.0
|
|
electroniccats/CayenneLPP @ 1.6.1
|
|
h2zero/NimBLE-Arduino @ 1.4.3
|
|
adafruit/Adafruit INA3221 Library @ ^1.0.1
|
|
adafruit/Adafruit INA219 @ ^1.2.3
|
|
robtillaart/INA226 @ ^0.6.4
|
|
adafruit/Adafruit INA260 Library @ ^1.5.3
|
|
adafruit/Adafruit AHTX0 @ ^2.0.5
|
|
adafruit/Adafruit BME280 Library @ ^2.3.0
|
|
adafruit/Adafruit BMP280 Library @ ^2.6.8
|
|
adafruit/Adafruit SHTC3 Library @ ^1.0.1
|
|
sensirion/Sensirion I2C SHT4x @ ^1.1.2
|
|
arduino-libraries/Arduino_LPS22HB @ ^1.0.2
|
|
adafruit/Adafruit MLX90614 Library @ ^2.1.5
|
|
adafruit/Adafruit_VL53L0X @ ^1.2.4
|
|
stevemarple/MicroNMEA @ ^2.0.6
|
|
adafruit/Adafruit BME680 Library @ ^2.0.4
|
|
adafruit/Adafruit BMP085 Library @ ^1.2.4
|
|
ESP32Async/ESPAsyncWebServer @ 3.10.3
|
|
file://arch/esp32/AsyncElegantOTA
|
|
lvgl/lvgl @ ^8.3.11
|
|
densaugeo/base64 @ ~1.4.0
|
|
knolleary/PubSubClient @ ^2.8.0
|
|
bodmer/TFT_eSPI @ ^2.5.43
|
|
adafruit/Adafruit TCA8418 @ ^1.0.2
|
|
lewisxhe/SensorLib @ 0.3.3
|