diff options
Diffstat (limited to 'board/kevin/board.c')
-rw-r--r-- | board/kevin/board.c | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/board/kevin/board.c b/board/kevin/board.c index a152ea94b5..dfcfc6aa97 100644 --- a/board/kevin/board.c +++ b/board/kevin/board.c @@ -448,7 +448,8 @@ struct motion_sensor_t motion_sensors[] = { * Requirement: accelerometer sensor must init before gyro sensor * DO NOT change the order of the following table. */ - {.name = "Base Accel", + [BASE_ACCEL] = { + .name = "Base Accel", .active_mask = SENSOR_ACTIVE_S0, .chip = MOTIONSENSE_CHIP_BMI160, .type = MOTIONSENSE_TYPE_ACCEL, @@ -469,7 +470,7 @@ struct motion_sensor_t motion_sensors[] = { /* EC use accel for angle detection */ [SENSOR_CONFIG_EC_S0] = { .odr = 10000 | ROUND_UP_FLAG, - .ec_rate = 100, + .ec_rate = 0, }, /* Sensor off in S3/S5 */ [SENSOR_CONFIG_EC_S3] = { @@ -483,8 +484,8 @@ struct motion_sensor_t motion_sensors[] = { }, }, }, - - {.name = "Base Gyro", + [BASE_GYRO] = { + .name = "Base Gyro", .active_mask = SENSOR_ACTIVE_S0, .chip = MOTIONSENSE_CHIP_BMI160, .type = MOTIONSENSE_TYPE_GYRO, @@ -523,9 +524,9 @@ struct motion_sensor_t motion_sensors[] = { }, }, }, - #ifdef BOARD_KEVIN - {.name = "Lid Accel", + [LID_ACCEL] = { + .name = "Lid Accel", .active_mask = SENSOR_ACTIVE_S0, .chip = MOTIONSENSE_CHIP_BMA255, .type = MOTIONSENSE_TYPE_ACCEL, @@ -540,13 +541,13 @@ struct motion_sensor_t motion_sensors[] = { .config = { /* AP: by default use EC settings */ [SENSOR_CONFIG_AP] = { - .odr = 10000 | ROUND_UP_FLAG, - .ec_rate = 100 * MSEC, + .odr = 0, + .ec_rate = 0, }, /* EC use accel for angle detection */ [SENSOR_CONFIG_EC_S0] = { .odr = 10000 | ROUND_UP_FLAG, - .ec_rate = 100 * MSEC, + .ec_rate = 0, }, /* unused */ [SENSOR_CONFIG_EC_S3] = { @@ -560,7 +561,8 @@ struct motion_sensor_t motion_sensors[] = { }, }, #else - {.name = "Lid Accel", + [LID_ACCEL] = { + .name = "Lid Accel", .active_mask = SENSOR_ACTIVE_S0, .chip = MOTIONSENSE_CHIP_KX022, .type = MOTIONSENSE_TYPE_ACCEL, @@ -575,13 +577,13 @@ struct motion_sensor_t motion_sensors[] = { .config = { /* AP: by default use EC settings */ [SENSOR_CONFIG_AP] = { - .odr = 10000 | ROUND_UP_FLAG, - .ec_rate = 100 * MSEC, + .odr = 0, + .ec_rate = 0, }, /* EC use accel for angle detection */ [SENSOR_CONFIG_EC_S0] = { .odr = 10000 | ROUND_UP_FLAG, - .ec_rate = 100 * MSEC, + .ec_rate = 0, }, /* unused */ [SENSOR_CONFIG_EC_S3] = { |