资源简介
FT6336 I2C触屏驱动程序 有很好的参考价值,需要的收藏下载。
代码片段和文件信息
/*
* This software is licensed under the terms of the GNU General Public
* License version 2 as published by the Free Software Foundation and
* may be copied distributed and modified under those terms.
* This program is distributed in the hope that it will be useful
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
* * VERSION DATE AUTHOR Note
* 1.0 2013-7-16 Focaltech initial based on MTK platform
*
*/
#include “tpd.h“
//#include “tpd_custom_ft5206.h“
#include “tpd_custom_fts.h“
#include “focaltech_ex_fun.h“
#include
#ifdef FTS_CTL_IIC
#include “focaltech_ctl.h“
/*create sysfs for debug*/
extern int fts_create_sysfs(struct i2c_client * client);
extern void fts_release_sysfs(struct i2c_client * client);
extern int ft5x0x_create_apk_debug_channel(struct i2c_client *client);
extern void ft5x0x_release_apk_debug_channel(void);
#endif
#ifdef TPD_PROXIMITY
#include
#include
#include
#endif
#ifdef VELOCITY_CUSTOM
extern int tpd_v_magnify_x;
extern int tpd_v_magnify_y;
#endif
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
u8 *I2CDMABuf_va = NULL;
dma_addr_t I2CDMABuf_pa = 0;
#ifdef TPD_PROXIMITY
#define APS_ERR(fmtarg...) printk(“<> “fmt“\n“##arg)
#define TPD_PROXIMITY_DEBUG(fmtarg...) printk(“<> “fmt“\n“##arg)
#define TPD_PROXIMITY_DMESG(fmtarg...) printk(“<> “fmt“\n“##arg)
static u8 tpd_proximity_flag = 0;
static u8 tpd_proximity_flag_one = 0; //add for tpd_proximity by wangdongfang
static u8 tpd_proximity_detect = 1;//0-->close ; 1--> far away
#endif
extern struct tpd_device *tpd;
struct i2c_client *i2c_client = NULL;
struct task_struct *thread = NULL;
#ifdef VELOCITY_CUSTOM
extern int tpd_v_magnify_x;
extern int tpd_v_magnify_y;
#endif
static DECLARE_WAIT_QUEUE_HEAD(waiter);
static DEFINE_MUTEX(i2c_access);
static void tpd_eint_interrupt_handler(void);
static int tpd_probe(struct i2c_client *client const struct i2c_device_id *id);
static int tpd_detect (struct i2c_client *client struct i2c_board_info *info);
static int tpd_remove(struct i2c_client *client);
static int touch_event_handler(void *unused);
static int tpd_flag = 0;
static int tpd_halt = 0;
#define TPD_OK 0
#define TPD_RESET_ISSUE_WORKAROUND
#define TPD_MAX_RESET_COUNT 3
//extern int tpd_mstar_status ; // compatible mstar and ft6306 chenzhecong
#ifdef TPD_HAVE_BUTTON
static int tpd_keys_local[TPD_KEY_COUNT] = TPD_KEYS;
static int tpd_keys_
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 21038 2016-07-22 10:34 focaltech_driver.c
文件 29732 2016-07-22 10:34 focaltech_ex_fun.c
文件 1610 2016-07-22 10:34 focaltech_ex_fun.h
文件 5749 2016-07-22 10:34 tpd_custom_fts.h
文件 5739 2016-07-22 10:34 tpd_custom_fts.h~
- 上一篇:dcraw源代码
- 下一篇:Labview 虚拟示波器VI
评论
共有 条评论