From 7d40063d46aa9a8b6146355ee9be9db775af7f0d Mon Sep 17 00:00:00 2001 From: Sheng-Liang Song Date: Wed, 13 Aug 2014 14:17:07 -0700 Subject: samus: added gyro support for lsm6ds0 Changed motion_sense task to assume sensors are unpowered in G3 and re-initialize sensors every time coming out of G3. Added EC command line test utils as well. Fixed some bug during unit tests. BUG=chrome-os-partner:27313,27320 BRANCH=ToT TEST=Verified on Samus. Tested with accel EC CLIs accelread, accelrange, accelrate, accelres Tested accelcalib, a ACCEL calibration util, and it succeeded. Tested sysfs interface: cd /sys/bus/iio/devices/iio:device1 cat in_accel_*_gyro_raw Signed-off-by: Sheng-Liang Song Change-Id: I5752b00c03e1942c790ea4f28610fda83fa2dcbc Reviewed-on: https://chromium-review.googlesource.com/211484 Reviewed-by: Alec Berg --- include/math_util.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'include/math_util.h') diff --git a/include/math_util.h b/include/math_util.h index ffdbec424b..1dc92c4999 100644 --- a/include/math_util.h +++ b/include/math_util.h @@ -40,11 +40,11 @@ float cosine_of_angle_diff(const vector_3_t v1, const vector_3_t v2); * Rotate vector v by rotation matrix R. * * @param v Vector to be rotated. - * @param R Pointer to rotation matrix. - * @param res Pointer to the resultant vector. + * @param R Rotation matrix. + * @param res Resultant vector. */ -void rotate(const vector_3_t v, const matrix_3x3_t (* const R), - vector_3_t *res); +void rotate(const vector_3_t v, const matrix_3x3_t R, + vector_3_t res); #ifdef CONFIG_ACCEL_CALIBRATE -- cgit v1.2.1