From 39b3526710f3a2afedda4df9202f867207d30629 Mon Sep 17 00:00:00 2001 From: cdy Date: Mon, 4 Feb 2013 09:56:01 +0800 Subject: [PATCH] l3g4200d filte wave avoid wobble --- drivers/input/sensors/gyro/l3g4200d.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/sensors/gyro/l3g4200d.c b/drivers/input/sensors/gyro/l3g4200d.c index 6d08849fa17d..e1075854e5b8 100755 --- a/drivers/input/sensors/gyro/l3g4200d.c +++ b/drivers/input/sensors/gyro/l3g4200d.c @@ -192,7 +192,7 @@ static int sensor_report_value(struct i2c_client *client) } //filter gyro data - if((abs(axis.x) > pdata->x_min)||(abs(axis.y) > pdata->y_min)||(abs(axis.z) > pdata->z_min)) + if( ((abs(axis.x) > pdata->x_min) & (abs(axis.x) < 240))||(abs(axis.x) > 260) || ((abs(axis.y) > pdata->y_min)& (abs(axis.y) < 240))||(abs(axis.y) > 260)|| ((abs(axis.z) > pdata->z_min) & (abs(axis.z) < 250)) || (abs(axis.z) > 260) ) { gyro_report_value(client, &axis); -- 2.34.1