2020-12-17 06:02:55 +00:00
|
|
|
/**
|
|
|
|
* @file touch_driver.h
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef TOUCH_DRIVER_H
|
|
|
|
#define TOUCH_DRIVER_H
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/*********************
|
|
|
|
* INCLUDES
|
|
|
|
*********************/
|
|
|
|
#include <stdint.h>
|
|
|
|
#include <stdbool.h>
|
2020-12-21 17:10:35 +00:00
|
|
|
#ifdef LV_LVGL_H_INCLUDE_SIMPLE
|
2020-12-17 06:02:55 +00:00
|
|
|
#include "lvgl.h"
|
|
|
|
#else
|
|
|
|
#include "lvgl/lvgl.h"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#if defined (CONFIG_LV_TOUCH_CONTROLLER_XPT2046)
|
|
|
|
#include "xpt2046.h"
|
|
|
|
#elif defined (CONFIG_LV_TOUCH_CONTROLLER_FT6X06)
|
|
|
|
#include "ft6x36.h"
|
|
|
|
#elif defined (CONFIG_LV_TOUCH_CONTROLLER_STMPE610)
|
|
|
|
#include "stmpe610.h"
|
|
|
|
#elif defined (CONFIG_LV_TOUCH_CONTROLLER_ADCRAW)
|
|
|
|
#include "adcraw.h"
|
|
|
|
#elif defined (CONFIG_LV_TOUCH_CONTROLLER_FT81X)
|
|
|
|
#include "FT81x.h"
|
|
|
|
#elif defined (CONFIG_LV_TOUCH_CONTROLLER_RA8875)
|
|
|
|
#include "ra8875_touch.h"
|
2021-06-11 03:49:56 +00:00
|
|
|
#elif defined (CONFIG_LV_TOUCH_CONTROLLER_GT911)
|
|
|
|
#include "gt911.h"
|
2022-08-06 21:31:06 +00:00
|
|
|
#elif defined (CONFIG_LV_TOUCH_CONTROLLER_CST816)
|
|
|
|
#include "CST816.h"
|
2020-12-17 06:02:55 +00:00
|
|
|
#endif
|
|
|
|
|
|
|
|
/*********************
|
|
|
|
* DEFINES
|
|
|
|
*********************/
|
|
|
|
|
|
|
|
/**********************
|
|
|
|
* GLOBAL PROTOTYPES
|
|
|
|
**********************/
|
|
|
|
void touch_driver_init(void);
|
2021-06-13 20:06:22 +00:00
|
|
|
|
|
|
|
#if LVGL_VERSION_MAJOR >= 8
|
|
|
|
void touch_driver_read(lv_indev_drv_t *drv, lv_indev_data_t *data);
|
|
|
|
#else
|
2020-12-17 06:02:55 +00:00
|
|
|
bool touch_driver_read(lv_indev_drv_t *drv, lv_indev_data_t *data);
|
2021-06-13 20:06:22 +00:00
|
|
|
#endif
|
2020-12-17 06:02:55 +00:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
} /* extern "C" */
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif /* TOUCH_DRIVER_H */
|
|
|
|
|