LV_Arduino-3.0.1 esp32 add xpt2046 with a parallel screen

I had a question I have the ESP32 and have a parallel screen ssd1963 with tft esp working, but I want to add the xpt2046 to work for the example to test out. because tft esp lib can’t handle for now the spi xpt2046 together with a parallel screen. How can I add the touchscreen and how can I calibrated it ? Also I saw that ssd1963 could be use directly in lvgl with the LV_drivers package how does that work. but my main question for now is the xpt2046 can work together with the tft esp parallel screen handeling. Already thank you for the reply

I try to add this lib for xpt2046 from but during compiling I got an error in Arduino. lv_arduino-3.0.1\indev\xpt2046.c:13:30: fatal error: drv_XPT2046.h: No such file or directory

What do I miss here? I am now trying the ESP32_TFT_eSPI_slider test

I change this in the initial input device driver
indev_drv.read_cb = XPT2046_read;

@kisvegabor can maybe give me some help here?

The file from lv_drivers is just XPT2046.h, so I’m not sure where you are getting this name from.

I get it as error so I also check in the XPT2046.c but couldn’t find it. So that is why I am also asking it or maybe possible it doesn’t work with it. still unknown for me how to add the xpt2046 driver in the simple slide example.

This is what I have as error? maybe this helps?

In file included from C:\Users\XX\AppData\Local\Temp\arduino_modified_sketch_902530\ESP32_TFT_eSPI_Slider.ino:4:0:

c:\users\XX\downloads\arduino-1.8.12\arduino-1.8.12\libraries\lv_arduino-3.0.1\indev\xpt2046.c:13:30: fatal error: drv_XPT2046.h: No such file or directory

compilation terminated.

exit status 1
Error compiling for board ESP32 Dev Module.

uuuh we are some days away now. Any help? if possible? any person have some experience with how to get the xpt2046 to work?


With a working SPI writing an XPT2046 driver is quite simple.
The lv_drivers is not “Arduino ready” so instead I suggest using XPT2046.c as a reference and adding your SPI drivers in it. It’s really just some SPI byte reads/writes.

Were you able to get a solution for this? I have the same problem.

Did you find a resolution to this issue? I am having the same problem.