diff options
author | Kevin | 2014-11-15 10:00:36 +0800 |
---|---|---|
committer | Kevin | 2014-11-15 10:00:36 +0800 |
commit | 9d40ac5867b9aefe0722bc1f110b965ff294d30d (patch) | |
tree | de942df665fac4bac0d9cb7ae86910fe937b0c1a /ANDROID_3.4.5/drivers/input/touchscreen/lw86x0_ts/lw86x0_ts.h | |
parent | 392e8802486cb573b916e746010e141a75f507e6 (diff) | |
download | FOSSEE-netbook-kernel-source-9d40ac5867b9aefe0722bc1f110b965ff294d30d.tar.gz FOSSEE-netbook-kernel-source-9d40ac5867b9aefe0722bc1f110b965ff294d30d.tar.bz2 FOSSEE-netbook-kernel-source-9d40ac5867b9aefe0722bc1f110b965ff294d30d.zip |
add via modify part source code for wm8880 4.4 kitkat
Diffstat (limited to 'ANDROID_3.4.5/drivers/input/touchscreen/lw86x0_ts/lw86x0_ts.h')
-rwxr-xr-x | ANDROID_3.4.5/drivers/input/touchscreen/lw86x0_ts/lw86x0_ts.h | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/ANDROID_3.4.5/drivers/input/touchscreen/lw86x0_ts/lw86x0_ts.h b/ANDROID_3.4.5/drivers/input/touchscreen/lw86x0_ts/lw86x0_ts.h new file mode 100755 index 00000000..cc2d9e26 --- /dev/null +++ b/ANDROID_3.4.5/drivers/input/touchscreen/lw86x0_ts/lw86x0_ts.h @@ -0,0 +1,53 @@ +#ifndef _LW86X0_TS_H_ +#define _LW86X0_TS_H_ + +//#include "wmt_custom_lw86x0.h" + +// define byte swap of a WORD +#define swap16(a) ((((a)&0xff)<<8)|(((a)>>8)&0xff)) + +//struct _reg_word for ioctl read or write register +#define LW86X0_NAME "touch_lw86x0" + +#define SUPPORT_FW_UPGRADE +#define TS_KEY_NUM 4 +#define COL_NUM_MAX 28 +#define ROW_NUM_MAX 16 +#define SUPPORT_POINT_NUM_MAX 10 +#define MULTI_DATA_MAX_SIZE 49 + +typedef struct _reg_word +{ + u16 uOffset; + u16 uValue; + u16 multi_data[MULTI_DATA_MAX_SIZE]; + int data_size; +}reg_word; + +//struct _flash_op for ioctl write or read frimware +#define FLASH_XFER_PKT_SIZE 256 +typedef struct _flash_op +{ + u16 startaddr; //=0 if the first pkt + u16 lastpkt; // =1 if last pkt; =0, otherwise + u16 pktlen; //data length in this pkt + char data[FLASH_XFER_PKT_SIZE]; +}flash_op; + +//struct _raw_data for ioctl read cdc/amb/diff data +typedef struct _raw_data +{ + u8 row; + u8 col; + u16 data[COL_NUM_MAX*ROW_NUM_MAX]; +}rawdata; + +extern void wmt_ts_set_keylen(int keylen); +extern void wmt_ts_set_baseaxis(int axis); +extern void wmt_ts_set_keypos(int index, int min,int max); +extern int lw86x0_write_reg(u16 addr, u16 value); +extern int lw86x0_read_reg(u16 addr, u16 *pdata, int regcnt); +extern void getversion(void); +extern void lw86x0_stop_timer(int flags); + +#endif |