Compare commits

...

5 Commits

Author SHA1 Message Date
notmasteryet
d4dc41576c
Merge 291643fa3b into edb7ec58c6 2025-09-02 21:35:19 +02:00
renovate[bot]
edb7ec58c6
chore(deps): update platform-native digest to c490bcd (#7814)
Some checks are pending
CI / build-rp2040 (push) Blocked by required conditions
CI / build-rp2350 (push) Blocked by required conditions
CI / build-stm32 (push) Blocked by required conditions
CI / build-debian-src (push) Waiting to run
CI / package-pio-deps-native-tft (push) Waiting to run
CI / test-native (push) Waiting to run
CI / docker-deb-amd64 (push) Waiting to run
CI / docker-deb-amd64-tft (push) Waiting to run
CI / docker-alp-amd64 (push) Waiting to run
CI / docker-alp-amd64-tft (push) Waiting to run
CI / docker-deb-arm64 (push) Waiting to run
CI / docker-deb-armv7 (push) Waiting to run
CI / gather-artifacts (esp32) (push) Blocked by required conditions
CI / gather-artifacts (esp32c3) (push) Blocked by required conditions
CI / gather-artifacts (esp32c6) (push) Blocked by required conditions
CI / gather-artifacts (esp32s3) (push) Blocked by required conditions
CI / gather-artifacts (nrf52840) (push) Blocked by required conditions
CI / gather-artifacts (rp2040) (push) Blocked by required conditions
CI / gather-artifacts (rp2350) (push) Blocked by required conditions
CI / gather-artifacts (stm32) (push) Blocked by required conditions
CI / release-artifacts (push) Blocked by required conditions
CI / release-firmware (esp32) (push) Blocked by required conditions
CI / release-firmware (esp32c3) (push) Blocked by required conditions
CI / release-firmware (esp32c6) (push) Blocked by required conditions
CI / release-firmware (esp32s3) (push) Blocked by required conditions
CI / release-firmware (nrf52840) (push) Blocked by required conditions
CI / release-firmware (rp2040) (push) Blocked by required conditions
CI / release-firmware (rp2350) (push) Blocked by required conditions
CI / release-firmware (stm32) (push) Blocked by required conditions
CI / publish-firmware (push) Blocked by required conditions
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-02 11:58:57 -05:00
Ben Meadors
655c6b51fe
Try-fix Cardkb detection (#7825)
* Try-fix: CardKB detection regression

* Correct macro
2025-09-02 09:50:15 -05:00
Ben Meadors
291643fa3b
Merge branch 'master' into st7789 2025-08-11 21:54:55 -05:00
notmasteryet
ba7f23bb9b Add more config options for ST7789 TFT display
... in support of CYD
2025-07-02 17:37:42 -05:00
3 changed files with 41 additions and 1 deletions

View File

@ -2,7 +2,7 @@
[portduino_base]
platform =
# renovate: datasource=git-refs depName=platform-native packageName=https://github.com/meshtastic/platform-native gitBranch=develop
https://github.com/meshtastic/platform-native/archive/37d986499ce24511952d7146db72d667c6bdaff7.zip
https://github.com/meshtastic/platform-native/archive/c490bcd019e0658404088a61b96e653c9da22c45.zip
framework = arduino
build_src_filter =

View File

@ -431,6 +431,8 @@ class LGFX : public lgfx::LGFX_Device
#if HAS_TOUCHSCREEN
#if defined(T_WATCH_S3) || defined(ELECROW)
lgfx::Touch_FT5x06 _touch_instance;
#elif defined(TOUCH_CS)
lgfx::Touch_XPT2046 _touch_instance;
#else
lgfx::Touch_GT911 _touch_instance;
#endif
@ -494,8 +496,17 @@ class LGFX : public lgfx::LGFX_Device
#endif
cfg.dummy_read_bits = 1; // Number of bits for dummy read before non-pixel data read
cfg.readable = true; // Set to true if data can be read
#ifndef TFT_INVERSION_OFF
cfg.invert = true; // Set to true if the light/darkness of the panel is reversed
#else
cfg.invert = false;
#endif
#if !defined(TFT_RGB_ORDER) || (TFT_RGB_ORDER == TFT_BGR)
cfg.rgb_order = false; // Set to true if the panel's red and blue are swapped
#else
cfg.rgb_order = true;
#endif
cfg.dlen_16bit =
false; // Set to true for panels that transmit data length in 16-bit units with 16-bit parallel or SPI
cfg.bus_shared = true; // If the bus is shared with the SD card, set to true (bus control with drawJpgFile etc.)
@ -522,6 +533,7 @@ class LGFX : public lgfx::LGFX_Device
#endif
#if HAS_TOUCHSCREEN
#if !defined(TOUCH_CS)
// Configure settings for touch screen control.
{
auto cfg = _touch_instance.config();
@ -554,6 +566,30 @@ class LGFX : public lgfx::LGFX_Device
_touch_instance.config(cfg);
_panel_instance.setTouch(&_touch_instance);
}
#else // if defined(TOUCH_CS)
{
// Configure settings for touch control.
auto touch_cfg = _touch_instance.config();
touch_cfg.x_min = TFT_TOUCH_X_MIN;
touch_cfg.x_max = TFT_TOUCH_X_MAX;
touch_cfg.y_min = TFT_TOUCH_Y_MIN;
touch_cfg.y_max = TFT_TOUCH_Y_MAX;
touch_cfg.pin_int = -1;
touch_cfg.bus_shared = true;
touch_cfg.offset_rotation = TFT_TOUCH_OFFSET_ROTATION;
// SPI configuration
touch_cfg.spi_host = ST7789_SPI_HOST;
touch_cfg.freq = SPI_TOUCH_FREQUENCY;
touch_cfg.pin_sclk = ST7789_SCK;
touch_cfg.pin_mosi = ST7789_SDA;
touch_cfg.pin_miso = ST7789_MISO;
touch_cfg.pin_cs = TOUCH_CS;
_touch_instance.config(touch_cfg);
_panel_instance.setTouch(&_touch_instance);
}
#endif
#endif
setPanel(&_panel_instance); // Sets the panel to use.

View File

@ -13,7 +13,11 @@ void CardKbI2cImpl::init()
if (cardkb_found.address == 0x00) {
LOG_DEBUG("Rescan for I2C keyboard");
uint8_t i2caddr_scan[] = {CARDKB_ADDR, TDECK_KB_ADDR, BBQ10_KB_ADDR, MPR121_KB_ADDR, TCA8418_KB_ADDR};
#if defined(T_LORA_PAGER)
uint8_t i2caddr_asize = sizeof(i2caddr_scan) / sizeof(i2caddr_scan[0]);
#else
uint8_t i2caddr_asize = 5;
#endif
auto i2cScanner = std::unique_ptr<ScanI2CTwoWire>(new ScanI2CTwoWire());
#if WIRE_INTERFACES_COUNT == 2