diff options
author | Elmo_Lan <elmo_lan@compal.corp-partner.google.com> | 2018-03-26 16:55:57 +0800 |
---|---|---|
committer | ChromeOS Commit Bot <chromeos-commit-bot@chromium.org> | 2018-03-27 18:22:55 +0000 |
commit | 8aed131e2043f8c3d036badb44cf1fee8f60b409 (patch) | |
tree | 29d7b29413c1244a015bf56f35b6cfb1e77d61c0 | |
parent | eb822beb97468a73f3c5dc459ea1bc2f040ce327 (diff) | |
download | chrome-ec-8aed131e2043f8c3d036badb44cf1fee8f60b409.tar.gz |
Nami: initial x,y,z-axis direction of lid and base g-sensor
Modify standard reference frame to fit Nami shell design.
(base_standard_ref and lid_standard_ref)
BUG=b:76392750
BRANCH=none
TEST=Use "watch -n 1 ectool motionsense" to check x,y,z-axis.
1. When x-axis face up, get x value of sensor0 and sensor1 more than 10000.
2. When y-axis face up, get y value of sensor0 and sensor1 more than 10000.
3. When z-axis face up, get z value of sensor0 and sensor1 more than 10000.
Change-Id: I8df24f6a48d2759938d17f8ec92b7b4536d71aaa
Signed-off-by: Elmo_Lan <elmo_lan@compal.corp-partner.google.com>
Reviewed-on: https://chromium-review.googlesource.com/980012
Commit-Ready: Raymond Chou <raymond_chou@compal.corp-partner.google.com>
Tested-by: Elmo Lan <elmo_lan@compal.corp-partner.google.com>
Reviewed-by: Raymond Chou <raymond_chou@compal.corp-partner.google.com>
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Reviewed-by: Kaiyen Chang <kaiyen.chang@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/981712
Reviewed-by: Furquan Shaikh <furquan@chromium.org>
Commit-Queue: Furquan Shaikh <furquan@chromium.org>
Tested-by: Furquan Shaikh <furquan@chromium.org>
Trybot-Ready: Furquan Shaikh <furquan@chromium.org>
-rw-r--r-- | board/nami/board.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/board/nami/board.c b/board/nami/board.c index a4a834d582..29ee69147a 100644 --- a/board/nami/board.c +++ b/board/nami/board.c @@ -542,15 +542,15 @@ static struct opt3001_drv_data_t g_opt3001_data = { }; /* Matrix to rotate accelrator into standard reference frame */ const matrix_3x3_t base_standard_ref = { - { FLOAT_TO_FP(-1), 0, 0}, - { 0, FLOAT_TO_FP(1), 0}, - { 0, 0, FLOAT_TO_FP(-1)} + { 0, FLOAT_TO_FP(-1), 0}, + { FLOAT_TO_FP(1), 0, 0}, + { 0, 0, FLOAT_TO_FP(1)} }; const matrix_3x3_t lid_standard_ref = { - { FLOAT_TO_FP(-1), 0, 0}, - { 0, FLOAT_TO_FP(-1), 0}, - { 0, 0, FLOAT_TO_FP(1)} + { FLOAT_TO_FP(1), 0, 0}, + { 0, FLOAT_TO_FP(-1), 0}, + { 0, 0, FLOAT_TO_FP(-1)} }; struct motion_sensor_t motion_sensors[] = { |