summaryrefslogtreecommitdiff
path: root/board/nucleo-f411re/board.c
diff options
context:
space:
mode:
authorGwendal Grignou <gwendal@chromium.org>2019-12-08 00:28:48 -0800
committerJustin TerAvest <teravest@chromium.org>2019-12-09 02:50:24 +0000
commit6f96b488deffa19f7fc0075ed586410c32f3a379 (patch)
treec5ac66a14d9e19bb9ddfea15678de192ca4e9e79 /board/nucleo-f411re/board.c
parentfb1d26a58e5511d70f747e8b943096c22dead07c (diff)
downloadchrome-ec-6f96b488deffa19f7fc0075ed586410c32f3a379.tar.gz
board: Set min/max frequency attributes
On some boards, min_/max_frequency attributes were not set, esp. for kx022 acceleometers. BUG=b:145799480 BRANCH=octopus,coral TEST=compile Change-Id: I6d32926541505f02f183539ca3ad9f70c1ae7a6b Signed-off-by: Gwendal Grignou <gwendal@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1957374 Reviewed-by: Justin TerAvest <teravest@chromium.org> Tested-by: Justin TerAvest <teravest@chromium.org>
Diffstat (limited to 'board/nucleo-f411re/board.c')
-rw-r--r--board/nucleo-f411re/board.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/board/nucleo-f411re/board.c b/board/nucleo-f411re/board.c
index adaed9e3de..d5a4a67a40 100644
--- a/board/nucleo-f411re/board.c
+++ b/board/nucleo-f411re/board.c
@@ -76,8 +76,9 @@ struct motion_sensor_t motion_sensors[] = {
.drv_data = &g_bmi160_data,
.port = I2C_PORT_ACCEL,
.i2c_spi_addr_flags = BMI160_ADDR0_FLAGS,
- .rot_standard_ref = NULL,
.default_range = 2, /* g, enough for laptop. */
+ .min_frequency = BMI160_ACCEL_MIN_FREQ,
+ .max_frequency = BMI160_ACCEL_MAX_FREQ,
.config = {
/* EC use accel for angle detection */
[SENSOR_CONFIG_EC_S0] = {
@@ -104,7 +105,8 @@ struct motion_sensor_t motion_sensors[] = {
.port = I2C_PORT_ACCEL,
.i2c_spi_addr_flags = BMI160_ADDR0_FLAGS,
.default_range = 1000, /* dps */
- .rot_standard_ref = NULL,
+ .min_frequency = BMI160_GYRO_MIN_FREQ,
+ .max_frequency = BMI160_GYRO_MAX_FREQ,
},
};
const unsigned int motion_sensor_count = ARRAY_SIZE(motion_sensors);