10 #ifdef ENABLE_VIRTUAL_SCREEN
20 #ifdef ENABLE_VIRTUAL_SCREEN
24 #if defined(ARCH_ESP32)
28 constexpr uint8_t TFT_CS{2};
29 constexpr uint8_t TFT_RESET_PIN{4};
30 constexpr uint8_t TFT_DC_PIN{5};
31 constexpr uint8_t TOUCH_CS{15};
32 constexpr uint8_t TOUCH_IRQ_PIN{10};
33 #elif defined(ARCH_RP2040)
37 constexpr uint8_t TFT_CS{9};
38 constexpr uint8_t TFT_RESET_PIN{6};
39 constexpr uint8_t TFT_DC_PIN{5};
40 constexpr uint8_t TOUCH_CS{13};
41 constexpr uint8_t TOUCH_IRQ_PIN{10};
42 constexpr uint8_t TFT_LED_PIN{14};
43 #elif defined(ARCH_ESP8266) || defined(ARCH_HOST)
47 constexpr uint8_t TFT_CS{2};
48 constexpr uint8_t TFT_RESET_PIN{4};
49 constexpr uint8_t TFT_DC_PIN{5};
50 constexpr uint8_t TOUCH_CS{0};
51 constexpr uint8_t TOUCH_IRQ_PIN{2};
53 #error "Unsupported SOC"
63 #ifdef ENABLE_VIRTUAL_SCREEN
80 if(!tft.
begin(TFT_PINSET, TFT_CS, TFT_DC_PIN, TFT_RESET_PIN, 20000000)) {
84 touch.begin(TFT_PINSET, TOUCH_CS, TOUCH_IRQ_PIN);
Virtual display device for Host.
Definition: Virtual.h:42
bool begin(uint16_t width=240, uint16_t height=320)
Definition: VirtualTouch.h:34
Manages access to SPI hardware.
Definition: HardwareSPI/src/include/HSPI/Controller.h:52
SpiBus
Identifies bus selection.
Definition: Esp32/spi_arch.h:23
PinSet
How SPI hardware pins are connected.
Definition: Common.h:108
@ overlap
Overlapped with SPI 0.
@ normal
Standard HSPI pins.
SPI pin connections.
Definition: HardwareSPI/src/include/HSPI/Controller.h:42
uint8_t sck
Definition: HardwareSPI/src/include/HSPI/Controller.h:43