mirror of
https://github.com/MarekZegare4/MeshCore-Solo.git
synced 2026-08-07 20:56:11 +00:00
fix(heltec_v3): carry V4's confirmed CardKB/joystick pins over to V3
V3 and V4 are pin-compatible per Heltec's docs, and V3's own PIN_GPS_RX/TX/EN defines are dead code here (ENV_INCLUDE_GPS is never set to 1 in this file), so there's no reason to keep the blind-guess pins from before. Reuses the exact CardKB (SDA 3/SCL 4) and joystick (UP 23/DOWN 6/LEFT 47/RIGHT 48/BACK 33) assignment already confirmed working on real V4 hardware. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -196,7 +196,6 @@ lib_deps =
|
||||
; boot, so a build with these set still runs fine with nothing plugged in.
|
||||
; Pair it with Settings > Keyboard > Ext. KB = Compact, which is designed to
|
||||
; need no joystick at all. The same bus is scanned for environment sensors.
|
||||
; Defaults below: SDA 41, SCL 42.
|
||||
;
|
||||
; * Wired joystick: four direction pins plus a separate Back button -- the UI
|
||||
; uses Back unconditionally once UI_HAS_JOYSTICK is set, so it isn't optional.
|
||||
@@ -211,13 +210,13 @@ lib_deps =
|
||||
; costs nothing here -- that fallback only feeds KEY_NEXT/KEY_PREV, which the
|
||||
; solo screens don't act on.
|
||||
;
|
||||
; Pins already taken on this board: 8/9/10/11/13/14 (LoRa), 17/18 (OLED I2C),
|
||||
; 21 (OLED reset), 0 (PRG), 35 (TX LED), 36 (VEXT), 37 (ADC ctrl), 1 (battery
|
||||
; ADC), 26/47/48 (GPS). On top of that the ESP32-S3 reserves 19/20 (USB), 26-32
|
||||
; (flash) and 43/44 (UART0), and 0/3/45/46 are strapping pins. That leaves
|
||||
; 2, 4-7, 33/34 and 38-42, which is where the defaults below come from -- verify
|
||||
; against your own module before soldering. The GPS defines above already look
|
||||
; optimistic: on a quad-flash S3, GPIO26 is a flash line.
|
||||
; V3 and V4 are pin-compatible per Heltec's own docs, so the defaults below are
|
||||
; carried over from the heltec_v4_companion_solo_dual env, where this exact
|
||||
; CardKB + joystick combination is confirmed working on real hardware -- still
|
||||
; worth checking against your own V3 module before soldering, but not a blind
|
||||
; guess like the earlier SDA 41/SCL 42 default was. PIN_GPS_RX=47/TX=48/EN=26
|
||||
; above are dead defines on V3 (ENV_INCLUDE_GPS is never set to 1 in this file),
|
||||
; so they don't conflict with reusing 47/48 here despite the name.
|
||||
[env:Heltec_v3_companion_solo_dual]
|
||||
extends = Heltec_lora32_v3
|
||||
build_flags =
|
||||
@@ -234,16 +233,16 @@ build_flags =
|
||||
-D UI_SENSORS_PAGE=1
|
||||
-D OLED_MISC_FIXED_FONT=1 ; full Latin/Greek/Cyrillic 6x9 font, ~14 KB flash
|
||||
; CardKB on the second I2C bus. Harmless with nothing plugged in.
|
||||
-D ENV_PIN_SDA=41
|
||||
-D ENV_PIN_SCL=42
|
||||
-D ENV_PIN_SDA=3
|
||||
-D ENV_PIN_SCL=4
|
||||
; Wired joystick — comment the block out for a CardKB-only build.
|
||||
-D UI_HAS_JOYSTICK=1
|
||||
-D UI_HAS_JOYSTICK_UPDOWN=1
|
||||
-D JOYSTICK_UP=4
|
||||
-D JOYSTICK_DOWN=5
|
||||
-D JOYSTICK_LEFT=6
|
||||
-D JOYSTICK_RIGHT=7
|
||||
-D PIN_BACK_BTN=2
|
||||
-D JOYSTICK_UP=23
|
||||
-D JOYSTICK_DOWN=6
|
||||
-D JOYSTICK_LEFT=47
|
||||
-D JOYSTICK_RIGHT=48
|
||||
-D PIN_BACK_BTN=33
|
||||
; -D PIN_BUZZER=<gpio>
|
||||
build_src_filter = ${Heltec_lora32_v3.build_src_filter}
|
||||
+<helpers/ui/SSD1306Display.cpp>
|
||||
|
||||
Reference in New Issue
Block a user