acid-drop

- Hacking the planet from a LilyGo T-Deck using custom firmware
git clone git://git.acid.vegas/acid-drop.git
Log | Files | Refs | Archive | README | LICENSE

Kconfig (12868B)

      1 menu "TFT_eSPI"
      2 
      3     menu "Hidden menu"
      4         visible if false
      5 
      6         config TFT_eSPI_ESPIDF
      7             bool "Enable Configuration"
      8             default y
      9     endmenu
     10         
     11     choice TFT_DRIVER
     12         prompt "Select TFT driver"
     13         default TFT_ILI9341_DRIVER
     14         help
     15             Driver for the TFT LCD screen
     16 
     17         config TFT_ILI9341_DRIVER
     18             bool "ILI9341 - 1"
     19             help
     20                 Generic driver for common displays
     21         config TFT_ILI9341_2_DRIVER
     22             bool "ILI9341 - 2"
     23             help
     24                 Alternative ILI9341 driver, see https://github.com/Bodmer/TFT_eSPI/issues/1172
     25         config TFT_ST7735_DRIVER
     26             bool "ST7735"
     27             help
     28                 Define additional parameters below for this display
     29         config TFT_ILI9163_DRIVER
     30             bool "ILI9163"
     31             help
     32                 Define additional parameters below for this display
     33         config TFT_S6D02A1_DRIVER
     34             bool "S6D02A1"
     35         config TFT_HX8357D_DRIVER
     36             bool "HX8357D"
     37         config TFT_ILI9481_DRIVER
     38             bool "ILI9481"
     39         config TFT_ILI9486_DRIVER
     40             bool "ILI9486"
     41         config TFT_ILI9488_DRIVER
     42             bool "ILI9488"
     43             help
     44                 WARNING: Do not connect ILI9488 display SDO to MISO if other devices 
     45                 share the SPI bus (TFT SDO does NOT tristate when CS is high)
     46         config TFT_ST7789_DRIVER
     47             bool "ST7789 - 1"
     48             help
     49                 Full configuration option, define additional parameters below for this display
     50         config TFT_ST7789_2_DRIVER
     51             bool "ST7789 - 2"
     52             help
     53                 Minimal configuration option, define additional parameters below for this display
     54         config TFT_R61581_DRIVER
     55             bool "R61581"
     56         config TFT_RM68140_DRIVER
     57             bool "RM68140"
     58         config TFT_ST7796_DRIVER
     59             bool "ST7796"
     60         config TFT_SSD1351_DRIVER
     61             bool "SSD1351"
     62         config TFT_SSD1963_480_DRIVER
     63             bool "SSD1963_480"
     64         config TFT_SSD1963_800_DRIVER
     65             bool "SSD1963_800"
     66         config TFT_SSD1963_800ALT_DRIVER
     67             bool "SSD1963_800ALT"
     68         config TFT_ILI9225_DRIVER
     69             bool "ILI9225"
     70         config TFT_GC9A01_DRIVER
     71             bool "GC9A01"
     72     endchoice
     73 
     74     if TFT_ST7735_DRIVER || TFT_ST7789_DRIVER || TFT_ST7789_2_DRIVER || TFT_ILI9341_DRIVER || TFT_ILI9341_2_DRIVER
     75         choice TFT_COLOR_ORDER
     76             prompt "Define the colour order"
     77             help
     78                 Define the colour order IF the blue and red are swapped on your display
     79 
     80             config TFT_RGB_ORDER
     81                 bool "RGB"
     82             config TFT_BGR_ORDER
     83                 bool "BGR"
     84         endchoice
     85     endif
     86 
     87     config TFT_M5STACK
     88         bool "M5Stack"
     89         depends on TFT_ILI9341_DRIVER || TFT_ILI9341_2_DRIVER
     90         help
     91             Enable if using M5Stack module with integrated ILI9341
     92 
     93     if TFT_ST7735_DRIVER || TFT_ST7789_DRIVER || TFT_ST7789_2_DRIVER || TFT_ILI9163_DRIVER || TFT_GC9A01_DRIVER
     94         config TFT_WIDTH
     95             int "LCD pixel width in portrait orientation"
     96             default 128
     97             range 0 1024
     98 
     99         config TFT_HEIGHT
    100             int "LCD pixel height in portrait orientation"
    101             default 240
    102             range 0 1024
    103     endif
    104 
    105     if TFT_ST7735_DRIVER
    106         choice TFT_ST7735_TYPE
    107             prompt "Define the type of display"
    108             help
    109                 Try out the different options below if the screen does not display graphics
    110                 correctly,e.g. colours wrong, mirror images, or stray pixels at the edges.
    111 
    112             config TFT_ST7735_INITB
    113                 bool "INITB"
    114             config TFT_ST7735_GREENTAB
    115                 bool "GREENTAB"
    116             config TFT_ST7735_GREENTAB2
    117                 bool "GREENTAB2"
    118             config TFT_ST7735_GREENTAB3
    119                 bool "GREENTAB3"
    120             config TFT_ST7735_GREENTAB128
    121                 bool "GREENTAB128"
    122                 help
    123                     For 128 x 128 display
    124             config TFT_ST7735_GREENTAB160x80
    125                 bool "GREENTAB160x80"
    126                 help
    127                     For 160 x 80 display (BGR, inverted, 26 offset)
    128             config TFT_ST7735_REDTAB
    129                 bool "REDTAB"
    130             config TFT_ST7735_BLACKTAB
    131                 bool "BLACKTAB"
    132             config TFT_ST7735_REDTAB160x80
    133                 bool "REDTAB160x80"
    134                 help
    135                     For 160 x 80 display with 24 pixel offset
    136         endchoice
    137     endif
    138 
    139     choice TFT_COLOR_INVERSION
    140         prompt "Color inversion correction"
    141         help 
    142             If colours are inverted (white shows as black) then try changing this option."
    143 
    144         config TFT_INVERSION_DISABLE
    145             bool "None"
    146         config TFT_INVERSION_ON
    147             bool "On"
    148         config TFT_INVERSION_OFF
    149             bool "Off"
    150             
    151     endchoice
    152 
    153     choice TFT_INTERFACE
    154         prompt "LCD Interface"
    155         default TFT_SPI
    156         help
    157             Communication interface between the microcontroller and the LCD.
    158         config TFT_SPI
    159             bool "SPI"
    160         config TFT_PARALLEL_8_BIT
    161             bool "Parallel (8 bit)"
    162     endchoice
    163     
    164     menu "Display Data pins"
    165         depends on TFT_PARALLEL_8_BIT
    166         config TFT_D0
    167             int "Data 0 pin"
    168             default -1
    169             range -1 31
    170 
    171         config TFT_D1
    172             int "Data 1 pin"
    173             default -1
    174             range -1 31
    175 
    176         config TFT_D2
    177             int "Data 2 pin"
    178             default -1
    179             range -1 31
    180         
    181         config TFT_D3
    182             int "Data 3 pin"
    183             default -1
    184             range -1 31
    185 
    186         config TFT_D4
    187             int "Data 4 pin"
    188             default -1
    189             range -1 31
    190 
    191         config TFT_D5
    192             int "Data 5 pin"
    193             default -1
    194             range -1 31
    195 
    196         config TFT_D6
    197             int "Data 6 pin"
    198             default -1
    199             range -1 31
    200 
    201         config TFT_D7
    202             int "Data 7 pin"
    203             default -1
    204             range -1 31
    205 
    206         config TFT_WR
    207             int "Write strobe pin"
    208             default -1
    209             range -1 31
    210 
    211         config TFT_RD
    212             int "Read strobe pin"
    213             default -1
    214             range -1 33
    215     endmenu
    216 
    217     menu "Display SPI config"
    218         depends on TFT_SPI
    219     
    220         choice TFT_SPI_PORT
    221             prompt "SPI port"
    222             default TFT_VSPI_PORT
    223             help
    224                 The ESP32 has 2 free SPI ports i.e. VSPI (SPI2) and HSPI (SPI3),
    225                 the VSPI is the default. If the VSPI port is in use and pins are
    226                 not accessible (e.g. TTGO T-Beam) then use the HSPI port for the
    227                 TFT display.
    228             config TFT_VSPI_PORT
    229                 bool "VSPI (SPI2)"
    230             config TFT_HSPI_PORT
    231                 bool "HSPI (SPI3)"
    232         endchoice
    233 
    234         config TFT_MISO
    235             int "TFT MISO pin"
    236             default -1
    237             range -1 32 if IDF_TARGET_ESP32
    238             range -1 45 if IDF_TARGET_ESP32S2
    239             range -1 48 if IDF_TARGET_ESP32S3
    240             help
    241                 Master In Slave Out pin.
    242                 Can be labelled as SDO in some displays
    243 
    244         config TFT_MOSI
    245             int "TFT MOSI pin"
    246             default -1
    247             range -1 32 if IDF_TARGET_ESP32
    248             range -1 45 if IDF_TARGET_ESP32S2
    249             range -1 48 if IDF_TARGET_ESP32S3
    250             help
    251                 Master Out Slave In pin.
    252                 Can be labelled as SDA or SDI in some displays
    253             
    254         config TFT_SCLK
    255             int "TFT Clock pin"
    256             default -1
    257             range -1 32 if IDF_TARGET_ESP32
    258             range -1 45 if IDF_TARGET_ESP32S2
    259             range -1 48 if IDF_TARGET_ESP32S3
    260             help
    261                 Labelled in some displays as WR
    262 
    263         config TFT_SDA_READ
    264             bool "Use SDA line for reading"
    265             default "n"
    266             help
    267                 Some displays support SPI reads via the MISO pin, other displays have a single
    268                 bi-directional SDA pin and the library will try to read this via the MOSI line
    269 
    270         config TFT_SPI_FREQUENCY
    271             int "SPI Frequency (Hz)"
    272             default 27000000
    273             range 1 80000000
    274             help
    275                 Define the SPI clock frequency, this affects the graphics rendering speed. Too
    276                 fast and the TFT driver will not keep up and display corruption appears.
    277                 With an ILI9341 display 40MHz works OK, 80MHz sometimes fails
    278                 With a ST7735 display more than 27MHz may not work (spurious pixels and lines)
    279                 With an ILI9163 display 27 MHz works OK.
    280 
    281         config TFT_SPI_READ_FREQ
    282             int "SPI Read Frequency (Hz)"
    283             default 20000000
    284             range -1 80000000
    285             help
    286                 Optional reduced SPI frequency for reading TFT.
    287                 Set to -1 to use the default frequency
    288             
    289     endmenu
    290 
    291     menu "Control Pin configuration"
    292         config TFT_CS
    293             int "TFT Chip Select pin"
    294             default -1
    295             range -1 33 if IDF_TARGET_ESP32
    296             range -1 45 if IDF_TARGET_ESP32S2
    297             range -1 48 if IDF_TARGET_ESP32S3
    298     
    299         config TFT_DC
    300             int "TFT Data/Command pin"
    301             default -1
    302             range -1 31
    303             help
    304                 Labelled as DC or RS (Register Select) in some displays
    305     
    306         config TFT_RST
    307             int "TFT Reset pin"
    308             default -1
    309             range -1 33 if IDF_TARGET_ESP32
    310             range -1 45 if IDF_TARGET_ESP32S2
    311             range -1 48 if IDF_TARGET_ESP32S3
    312 
    313         config ENABLE_BL
    314             bool "Enable backlight control"
    315             default y
    316         
    317         if ENABLE_BL
    318             config TFT_BL
    319                 int "TFT Backlight pin"
    320                 default -1
    321                 range -1 33 if IDF_TARGET_ESP32
    322                 range -1 45 if IDF_TARGET_ESP32S2
    323                 range -1 48 if IDF_TARGET_ESP32S3
    324                 help
    325                     Pin for the backlight control signal
    326         
    327             choice TFT_BACKLIGHT_ON
    328                 bool "Pin state to activate backlight"
    329                 default TFT_BACKLIGHT_ON_HIGH
    330                 help
    331                     The backlight will be turned ON when tft.begin() is called, but the library
    332                     needs to know if the LEDs are ON with the pin HIGH or LOW.
    333         
    334                 config TFT_BACKLIGHT_ON_HIGH
    335                     bool "HIGH"
    336                 config TFT_BACKLIGHT_ON_LOW
    337                     bool "LOW"            
    338             endchoice
    339         endif
    340     
    341         config TFT_BACKLIGHT_ON
    342             int
    343             default 1 if TFT_BACKLIGHT_ON_HIGH
    344             default 0 if TFT_BACKLIGHT_ON_LOW
    345     endmenu
    346 
    347     menu "Fonts"
    348         config TFT_LOAD_GLCD
    349             bool "Font 1: Original Adafruit 8 pixel font needs ~1820 bytes in FLASH"
    350             default "y"
    351 
    352         config TFT_LOAD_FONT2
    353             bool "Font 2: Small 16 pixel high font, needs ~3534 bytes in FLASH, 96 characters"
    354             default "y"
    355 
    356         config TFT_LOAD_FONT4
    357             bool "Font 4: Medium 26 pixel high font, needs ~5848 bytes in FLASH, 96 characters"
    358             default "y"
    359 
    360         config TFT_LOAD_FONT6
    361             bool "Font 6: Large 48 pixel font, needs ~2666 bytes in FLASH, only characters 1234567890:-.apm"
    362             default "y"
    363 
    364         config TFT_LOAD_FONT7
    365             bool "Font 7: 7 segment 48 pixel font, needs ~2438 bytes in FLASH, only characters 1234567890:."
    366             default "y"
    367 
    368         config TFT_LOAD_FONT8
    369             bool "Font 8: Large 75 pixel font needs ~3256 bytes in FLASH, only characters 1234567890:-."
    370             default "y"
    371 
    372         config TFT_LOAD_GFXFF
    373             bool "FreeFonts: Include access to the 48 Adafruit_GFX free fonts FF1 to FF48 and custom fonts"
    374             default "y"
    375 
    376         config TFT_SMOOTH_FONT
    377             bool "Smooth Fonts"
    378             default "y"
    379     endmenu
    380     
    381     menu "Touch screen configuration"
    382         config ENABLE_TOUCH
    383             bool "Enable Touch"
    384             default n
    385 
    386         if ENABLE_TOUCH
    387             config TOUCH_CS
    388                 int "Touch chip select pin"
    389                 default -1
    390                 range -1 33 if IDF_TARGET_ESP32
    391                 range -1 45 if IDF_TARGET_ESP32S2
    392                 range -1 48 if IDF_TARGET_ESP32S3
    393 
    394             config SPI_TOUCH_FREQUENCY
    395                 int "SPI frequency for XPT2046 chip (Hz)"
    396                 default 2500000
    397                 range 1 80000000
    398         endif
    399     endmenu
    400 
    401     menu "Other settings"
    402         config DISABLE_WARNINGS
    403             bool "Disable Library warnings"
    404             default n
    405     endmenu
    406 
    407 endmenu