RobertoBenjami/stm32_graphics_display_drivers

Touch XPT2046

Crocccodillo opened this issue · 1 comments

Hello Roberto,

First of all, thank you for your work.
You really did a GREAT job with these graphical drivers.
I'm however facing a little problem.
I'm using a 3.5 touch panel, sporting ILI9488 and XPT2046.
I interfaced it with a NUCLEO-F411RE development board (STM32F411RE in LQPF64 package).
The panel shows the usual ILI9488 SDO problem, in which the line is never released and never goes tri-state.
So I decide to use two different SPI lines, one for the LCD (ILI9488), the other for the touchscreen (XPT2046).
I used the "stm32f4xx/cd_io_spi.x" driver, which works just fine (with the "LcdSpeedTest" app).
When I try to add the touchscreen support, however, I get errors.
I imported the "ts_xpt2046.x" files into the project.
Unfortunately, the compiler keep complaining that a "ts_drv" reference is missing, since it is not declared nor referenced in any place.
I think we need something like the "lcd_drv" defined in "ili9488" driver.
I know we need to write a xpt2046 driver, I will try to write it, but before, do you have something already done?
Thank you!

In ili9488.h:
#define ILI9488_TOUCH 1
This value is 1 ?