Display Kconfig: Fix TTGO default SPI bus and display orientation checks

This commit is contained in:
C47D 2022-01-03 20:07:02 -06:00 committed by Carlos Diaz
parent 26272b08f0
commit 1a8a610b05

View file

@ -226,15 +226,15 @@ menu "LVGL TFT Display controller"
config LV_TFT_DISPLAY_X_OFFSET config LV_TFT_DISPLAY_X_OFFSET
depends on LV_TFT_DISPLAY_OFFSETS depends on LV_TFT_DISPLAY_OFFSETS
int "X offset" int "X offset"
default 40 if LV_PREDEFINED_DISPLAY_TTGO && (LV_DISPLAY_ORIENTATION_LANDSCAPE || LV_DISPLAY_ORIENTATION_LANDSCAPE_INVERTED) default 40 if LV_PREDEFINED_DISPLAY_TTGO && (DISPLAY_ORIENTATION_LANDSCAPE || DISPLAY_ORIENTATION_LANDSCAPE_INVERTED)
default 53 if LV_PREDEFINED_DISPLAY_TTGO && (LV_DISPLAY_ORIENTATION_PORTRAIT || LV_DISPLAY_ORIENTATION_PORTRAIT_INVERTED) default 53 if LV_PREDEFINED_DISPLAY_TTGO && (DISPLAY_ORIENTATION_PORTRAIT || DISPLAY_ORIENTATION_PORTRAIT_INVERTED)
default 0 default 0
config LV_TFT_DISPLAY_Y_OFFSET config LV_TFT_DISPLAY_Y_OFFSET
depends on LV_TFT_DISPLAY_OFFSETS depends on LV_TFT_DISPLAY_OFFSETS
int "Y offset" int "Y offset"
default 53 if LV_PREDEFINED_DISPLAY_TTGO && (LV_DISPLAY_ORIENTATION_LANDSCAPE || LV_DISPLAY_ORIENTATION_LANDSCAPE_INVERTED) default 53 if LV_PREDEFINED_DISPLAY_TTGO && (DISPLAY_ORIENTATION_LANDSCAPE || DISPLAY_ORIENTATION_LANDSCAPE_INVERTED)
default 40 if LV_PREDEFINED_DISPLAY_TTGO && (LV_DISPLAY_ORIENTATION_PORTRAIT || LV_DISPLAY_ORIENTATION_PORTRAIT_INVERTED) default 40 if LV_PREDEFINED_DISPLAY_TTGO && (DISPLAY_ORIENTATION_PORTRAIT || DISPLAY_ORIENTATION_PORTRAIT_INVERTED)
default 0 default 0
@ -469,14 +469,15 @@ menu "LVGL TFT Display controller"
choice choice
prompt "TFT SPI Bus." if LV_TFT_DISPLAY_PROTOCOL_SPI prompt "TFT SPI Bus." if LV_TFT_DISPLAY_PROTOCOL_SPI
default LV_TFT_DISPLAY_SPI2_HOST default LV_TFT_DISPLAY_SPI2_HOST if LV_PREDEFINED_DISPLAY_TTGO && !IDF_TARGET_ESP32S2
help default LV_TFT_DISPLAY_SPI3_HOST if !LV_PREDEFINED_DISPLAY_TTGO && IDF_TARGET_ESP32S2
Select the SPI Bus the TFT Display is attached to.
config LV_TFT_DISPLAY_SPI2_HOST config LV_TFT_DISPLAY_SPI2_HOST
bool "SPI2_HOST" bool "SPI2_HOST"
config LV_TFT_DISPLAY_SPI3_HOST config LV_TFT_DISPLAY_SPI3_HOST
bool "SPI3_HOST" bool "SPI3_HOST"
help
Select the SPI Bus the TFT Display is attached to.
endchoice endchoice
choice choice