42 void XPTSetPoint(uint16_t x1,uint16_t y1,uint16_t x2,uint16_t y2,uint16_t
id);
62 static constexpr uint32_t
DTMAX = 800000;
Class to interface hardware of Touch point IC XPT2046.
Definition XPT2046_TS_TFT_LCD_RDL.hpp:23
int16_t _max_xc
Definition XPT2046_TS_TFT_LCD_RDL.hpp:86
static constexpr uint8_t XPT_DEF
Definition XPT2046_TS_TFT_LCD_RDL.hpp:71
static constexpr uint8_t XPT_XPOS
Definition XPT2046_TS_TFT_LCD_RDL.hpp:67
uint8_t _RESET_PIN
Definition XPT2046_TS_TFT_LCD_RDL.hpp:99
int _spiFlags
Definition XPT2046_TS_TFT_LCD_RDL.hpp:94
int16_t _min_yc
Definition XPT2046_TS_TFT_LCD_RDL.hpp:85
int _DeviceNumGpioChip
Definition XPT2046_TS_TFT_LCD_RDL.hpp:97
rdlib::Return_Codes_e XPTSPIInit(int device, int channel, int speed, int flags, int gpioDev, uint8_t IRQPin, int8_t resPin)
Initialise the SPI interface.
Definition XPT2046_TS_TFT_LCD_RDL.cpp:32
int _spiHandle
Definition XPT2046_TS_TFT_LCD_RDL.hpp:95
bool XPTIRQIsPressed()
Poll the IRQ pin.
Definition XPT2046_TS_TFT_LCD_RDL.cpp:152
static constexpr uint8_t XPT_YPOS
Definition XPT2046_TS_TFT_LCD_RDL.hpp:68
void XPTSetPoint(uint16_t x1, uint16_t y1, uint16_t x2, uint16_t y2, uint16_t id)
Sets the touch points for the XPT_2046 touch controller.
Definition XPT2046_TS_TFT_LCD_RDL.cpp:245
static constexpr uint8_t XPT_START
Definition XPT2046_TS_TFT_LCD_RDL.hpp:66
int16_t _min_xc
Definition XPT2046_TS_TFT_LCD_RDL.hpp:84
time_t lsec
Definition XPT2046_TS_TFT_LCD_RDL.hpp:75
int XPTReadSensor(int command)
Read the touch screen sensor Data.
Definition XPT2046_TS_TFT_LCD_RDL.cpp:173
static constexpr uint8_t MAX_LEN_BUFFER
Definition XPT2046_TS_TFT_LCD_RDL.hpp:61
int _spiDev
Definition XPT2046_TS_TFT_LCD_RDL.hpp:91
int16_t _min_xp
Definition XPT2046_TS_TFT_LCD_RDL.hpp:80
static constexpr uint32_t DTMAX
Definition XPT2046_TS_TFT_LCD_RDL.hpp:62
int _GpioHandle
Definition XPT2046_TS_TFT_LCD_RDL.hpp:98
int16_t _min_yp
Definition XPT2046_TS_TFT_LCD_RDL.hpp:81
void XPTPrintValues()
print the touch point values if debug enabled
Definition XPT2046_TS_TFT_LCD_RDL.cpp:218
suseconds_t lusec
Definition XPT2046_TS_TFT_LCD_RDL.hpp:76
Touch_Point_t tps[MaxTouchPoints]
Definition XPT2046_TS_TFT_LCD_RDL.hpp:77
XPT_2046_RDL()
Constructor for class XPT2046_RDL.
Definition XPT2046_TS_TFT_LCD_RDL.cpp:13
int _spiBaud
Definition XPT2046_TS_TFT_LCD_RDL.hpp:93
int16_t _max_xp
Definition XPT2046_TS_TFT_LCD_RDL.hpp:82
static constexpr uint8_t XPT_8BIT
Definition XPT2046_TS_TFT_LCD_RDL.hpp:69
int _spiChan
Definition XPT2046_TS_TFT_LCD_RDL.hpp:92
rdlib::Return_Codes_e XPTSPIend(void)
Stop the SPI interface.
Definition XPT2046_TS_TFT_LCD_RDL.cpp:93
uint16_t tpx
Definition XPT2046_TS_TFT_LCD_RDL.hpp:74
void XPTReadXY(int *xp, int *yp)
Get the X Y position data.
Definition XPT2046_TS_TFT_LCD_RDL.cpp:199
static constexpr uint8_t XPT_SER
Definition XPT2046_TS_TFT_LCD_RDL.hpp:70
int16_t _max_yp
Definition XPT2046_TS_TFT_LCD_RDL.hpp:83
void XPTInitValues()
init values
Definition XPT2046_TS_TFT_LCD_RDL.cpp:208
bool _calibration
Definition XPT2046_TS_TFT_LCD_RDL.hpp:78
static constexpr auto MaxTouchPoints
Definition XPT2046_TS_TFT_LCD_RDL.hpp:60
int16_t _max_yc
Definition XPT2046_TS_TFT_LCD_RDL.hpp:87
uint8_t _IRQ_PIN
Definition XPT2046_TS_TFT_LCD_RDL.hpp:100
uint16_t tpc
Definition XPT2046_TS_TFT_LCD_RDL.hpp:73
bool _resetXPTPinOn
Definition XPT2046_TS_TFT_LCD_RDL.hpp:101
int XPTGetPoint()
Gets the touch point ID based on the current touch coordinates.
Definition XPT2046_TS_TFT_LCD_RDL.cpp:277
file to hold common data and functions used by many Displays Project Name: Display_Lib_RPI
Return_Codes_e
Definition common_data_RDL.hpp:22
Structure representing a touch point on the screen. This structure is used to define a touch area on ...
Definition XPT2046_TS_TFT_LCD_RDL.hpp:52
uint32_t y2
Definition XPT2046_TS_TFT_LCD_RDL.hpp:56
uint32_t x1
Definition XPT2046_TS_TFT_LCD_RDL.hpp:53
uint32_t x2
Definition XPT2046_TS_TFT_LCD_RDL.hpp:54
uint32_t y1
Definition XPT2046_TS_TFT_LCD_RDL.hpp:55
uint32_t id
Definition XPT2046_TS_TFT_LCD_RDL.hpp:57