Unify optional hardware variants and add runtime R8 TFT rotation
This commit is contained in:
1 parent
3848626702
commit
9c78ccde57
61 files changed
+4853
-2518
No files matched your search
@@ -19,6 +19,18 @@ SPECS = (
|
||||
dict(flag="HELTEC_TFT_DISPLAY_AUTODETECT", board="heltec_v4_r8",
|
||||
guard="HELTEC_V4_R8_TFT", driver="ST7789LCDDisplay", controller="st7789", marker="heltec_r8",
|
||||
targets=r"heltec_v4_r8_tft_.+"),
|
||||
dict(flag="MUZI_BASE_ACCESSORY_AUTODETECT", board="muzi_base", guard="MUZI_BASE",
|
||||
driver="SH1107Display", controller="sh1107", marker="muzi_superio", platform="NRF52_PLATFORM",
|
||||
defines={"RADIO_CLASS": "CustomLR1121", "USE_LR1121": "1"},
|
||||
targets=r"muzi_base_duo_(?:superio_)?companion_radio_(?:usb|ble|full)"),
|
||||
dict(flag="MUZI_BASE_ACCESSORY_AUTODETECT", board="muzi_base", guard="MUZI_BASE",
|
||||
driver="SH1107Display", controller="sh1107", marker="muzi_superio", platform="NRF52_PLATFORM",
|
||||
defines={"RADIO_CLASS": "CustomSX1262", "USE_SX1262": "1"},
|
||||
targets=r"muzi_base_uno_(?:superio_)?companion_radio_(?:usb|ble|full)"),
|
||||
dict(flag="TECHO_LITE_DISPLAY_AUTODETECT", board="t-echo", guard="LILYGO_TECHO_LITE",
|
||||
driver="GxEPDDisplay", controller="ssd1681", marker="techo_lite", platform="NRF52_PLATFORM",
|
||||
defines={"EINK_DISPLAY_MODEL": "GxEPD2_122_T61"},
|
||||
targets=r"lilygo_t-echo-lite_(?:non_shell_)?(?:companion_radio_(?:usb|ble|full)|(?:repeater|room_server)(?:_lora_ota(?:_no_external_sensors)?)?)"),
|
||||
)
|
||||
|
||||
|
||||
@@ -31,6 +43,7 @@ def spec_for_defines(defines, board=None):
|
||||
if (defines.get(spec["flag"]) == "1"
|
||||
and defines.get(spec["guard"], "0") not in ("0", "false")
|
||||
and defines.get("DISPLAY_CLASS") == spec["driver"]
|
||||
and all(defines.get(key) == value for key, value in spec.get("defines", {}).items())
|
||||
and (board is None or board == spec["board"])):
|
||||
return spec
|
||||
return None
|
||||
@@ -43,7 +56,7 @@ def runtime_metadata(manifest, defines, release_source=None, board=None):
|
||||
return t114_metadata(manifest, defines, release_source)
|
||||
spec = spec_for_defines(defines, board)
|
||||
if (not spec or board is None or manifest.get("verified") is not True
|
||||
or manifest.get("platform") != "ESP32_PLATFORM"
|
||||
or manifest.get("platform") != spec.get("platform", "ESP32_PLATFORM")
|
||||
or not re.fullmatch(spec["targets"], str(manifest.get("target", "")).lower())
|
||||
or not any(row.get("capability") == CAPABILITY and row.get("present") is True
|
||||
and row.get("source") == "packaged application"
|
||||
|
||||
Reference in new issue
Block a user