rowan: enable Lid Accel but not Gyro readings in S0

Allow EC to take Lid Accelerometer readings in S0 to support rotation,
but disable taking Gyro readings unless requested by AP.

Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>

BRANCH=none
BUG=b:36668539
TEST=in ec console: accelinfo on
  => confirm Lid Accel values are non-zero
  => confirm Gyro values are zero

Change-Id: Ie0bf466a5877cf8d20fb3d5cd223696fbdc9c271
Reviewed-on: https://chromium-review.googlesource.com/484140
Commit-Ready: Daniel Kurtz <djkurtz@chromium.org>
Tested-by: Daniel Kurtz <djkurtz@chromium.org>
Reviewed-by: Gwendal Grignou <gwendal@chromium.org>
This commit is contained in:
Daniel Kurtz
2017-04-21 17:41:27 +08:00
committed by chrome-bot
parent 18f92fe55f
commit 64d79d609b

View File

@@ -527,10 +527,10 @@ struct motion_sensor_t motion_sensors[] = {
.odr = 0,
.ec_rate = 0,
},
/* EC: angle detection is not used */
/* Sensor on in S0 for Chrome screen orientation */
[SENSOR_CONFIG_EC_S0] = {
.odr = 0,
.ec_rate = 0,
.odr = 10000 | ROUND_UP_FLAG,
.ec_rate = 100 * MSEC,
},
/* Sensor off in S3/S5 */
[SENSOR_CONFIG_EC_S3] = {
@@ -563,10 +563,10 @@ struct motion_sensor_t motion_sensors[] = {
.odr = 0,
.ec_rate = 0,
},
/* Enable gyro in S0 */
/* Sensor off in S0 by default */
[SENSOR_CONFIG_EC_S0] = {
.odr = 10000 | ROUND_UP_FLAG,
.ec_rate = 100 * MSEC,
.odr = 0,
.ec_rate = 0,
},
/* Sensor off in S3/S5 */
[SENSOR_CONFIG_EC_S3] = {