diff options
author | Gwendal Grignou <gwendal@chromium.org> | 2016-10-06 10:55:38 -0700 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2016-10-08 18:34:43 -0700 |
commit | 16ab1b69c62702e052d3072c88e2cd654848d9d8 (patch) | |
tree | 0d4b4aa8cdc61e787ae6de4c0cdf1fffb224d722 /util | |
parent | 989b64b65a899b7d6033831e3b1e63589c08870a (diff) | |
download | chrome-ec-16ab1b69c62702e052d3072c88e2cd654848d9d8.tar.gz |
util: ectool: Add names for new sensors.
Match ec_commands.h, adding new type and sensors.
BUG=none
BRANCH=reef
TEST=Check on Reef that barometer sensor info is displayed properly.
Change-Id: I257f5161e5f57be562a2b3a29442b49f47f3fc89
Signed-off-by: Gwendal Grignou <gwendal@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/394749
Reviewed-by: Vincent Palatin <vpalatin@chromium.org>
Diffstat (limited to 'util')
-rw-r--r-- | util/ectool.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/util/ectool.c b/util/ectool.c index 2b7e5f2bf4..3ba5804095 100644 --- a/util/ectool.c +++ b/util/ectool.c @@ -3579,6 +3579,9 @@ static int cmd_motionsense(int argc, char **argv) case MOTIONSENSE_TYPE_ACTIVITY: printf("activity\n"); break; + case MOTIONSENSE_TYPE_BARO: + printf("barometer\n"); + break; default: printf("unknown\n"); } @@ -3612,6 +3615,15 @@ static int cmd_motionsense(int argc, char **argv) case MOTIONSENSE_CHIP_KX022: printf("kx022\n"); break; + case MOTIONSENSE_CHIP_L3GD20H: + printf("l3gd20h\n"); + break; + case MOTIONSENSE_CHIP_BMA255: + printf("bma255\n"); + break; + case MOTIONSENSE_CHIP_BMP280: + printf("bmp280\n"); + break; default: printf("unknown\n"); } @@ -3765,8 +3777,7 @@ static int cmd_motionsense(int argc, char **argv) printf("Timestamp:%" PRIx32 "\n", resp->fifo_info.timestamp); printf("Total lost: %d\n", resp->fifo_info.total_lost); for (i = 0; i < sensor_count; i++) { - int lost; - lost = resp->fifo_info.lost[i]; + int lost = resp->fifo_info.lost[i]; if (lost != 0) printf("Lost %d: %d\n", i, lost); } |