Skip to content

Instantly share code, notes, and snippets.

@nemith
Created January 13, 2012 02:26
Show Gist options
  • Save nemith/1604286 to your computer and use it in GitHub Desktop.
Save nemith/1604286 to your computer and use it in GitHub Desktop.
diff --git a/arch/arm/mach-omap2/board-acclaim-peripherals.c b/arch/arm/mach-omap2/board-acclaim-peripherals.c
index 15523ad..9914cf4 100644
--- a/arch/arm/mach-omap2/board-acclaim-peripherals.c
+++ b/arch/arm/mach-omap2/board-acclaim-peripherals.c
@@ -205,13 +205,13 @@ static void ft5x06_platform_resume(void)
}
static struct ft5x06_platform_data ft5x06_platform_data = {
- .maxx = 600,
- .maxy = 1024,
- .flags = 0,
+ .maxx = 1024,
+ .maxy = 600,
+ .flags = FLIP_DATA_FLAG | REVERSE_Y_FLAG | REVERSE_X_FLAG,
.reset_gpio = OMAP_FT5x06_RESET_GPIO,
.use_st = FT_USE_ST,
.use_mt = FT_USE_MT,
- .use_trk_id = FT_USE_TRACKING_ID,
+ .use_trk_id = 1, //FT_USE_TRACKING_ID,
.use_sleep = FT_USE_SLEEP,
.use_gestures = 1,
.platform_suspend = ft5x06_platform_suspend,
diff --git a/drivers/input/touchscreen/ft5x06-i2c.c b/drivers/input/touchscreen/ft5x06-i2c.c
index 0566e5c..e1376dc 100755
--- a/drivers/input/touchscreen/ft5x06-i2c.c
+++ b/drivers/input/touchscreen/ft5x06-i2c.c
@@ -388,8 +388,6 @@ void ft5x06_xy_worker(struct work_struct *work)
rev_y = false;
}
- rev_y = true;
-
/* process the touches */
switch (cur_tch)
{
@@ -534,6 +532,8 @@ void ft5x06_xy_worker(struct work_struct *work)
input_report_abs(ts->input, ABS_MT_POSITION_X, ts->prv_mt_pos[id][FT_XPOS]);
input_report_abs(ts->input, ABS_MT_POSITION_Y, ts->prv_mt_pos[id][FT_YPOS]);
+ input_report_key(ts->input, BTN_TOUCH, 0);
+
FT_MT_SYNC(ts->input);
ts->act_trk[id] = FT_NTCH;
@@ -553,6 +553,8 @@ void ft5x06_xy_worker(struct work_struct *work)
input_report_abs(ts->input, ABS_MT_POSITION_X, cur_mt_pos[id][FT_XPOS]);
input_report_abs(ts->input, ABS_MT_POSITION_Y, cur_mt_pos[id][FT_YPOS]);
+ input_report_key(ts->input, BTN_TOUCH, 1);
+
FT_MT_SYNC(ts->input);
ts->act_trk[id] = FT_TCH;
@@ -622,6 +624,8 @@ void ft5x06_xy_worker(struct work_struct *work)
input_report_abs(ts->input, ABS_MT_POSITION_X, cur_mt_pos[snd_trk[id]][FT_XPOS]);
input_report_abs(ts->input, ABS_MT_POSITION_Y, cur_mt_pos[snd_trk[id]][FT_YPOS]);
+ input_report_key(ts->input, BTN_TOUCH, 1);
+
FT_MT_SYNC(ts->input);
}
else if (ts->prv_mt_tch[id] < FT_NUM_TRK_ID)
@@ -632,6 +636,8 @@ void ft5x06_xy_worker(struct work_struct *work)
input_report_abs(ts->input, ABS_MT_POSITION_X, ts->prv_mt_pos[ts->prv_mt_tch[id]][FT_XPOS]);
input_report_abs(ts->input, ABS_MT_POSITION_Y, ts->prv_mt_pos[ts->prv_mt_tch[id]][FT_YPOS]);
+ input_report_key(ts->input, BTN_TOUCH, 0);
+
FT_MT_SYNC(ts->input);
/* ACCLPLAT-821 Do not report the duplicated release events */
ts->prv_mt_pos[ts->prv_mt_tch[id]][FT_XPOS] = 0;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment