summaryrefslogtreecommitdiff
path: root/board/eve/board.h
diff options
context:
space:
mode:
authorScott Collyer <scollyer@google.com>2017-05-23 16:35:44 -0700
committerchrome-bot <chrome-bot@chromium.org>2017-06-01 00:51:37 -0700
commit440146ca1170ef4fa11d7dbab28bd81d0d833310 (patch)
tree205463f8c8cb49a29394d8c5b91d28fd39128675 /board/eve/board.h
parent2992ee177196283ec814fc22bdb17ddfa0c997e4 (diff)
downloadchrome-ec-440146ca1170ef4fa11d7dbab28bd81d0d833310.tar.gz
eve: Enable double tap gesture
The LED spec requires a double tap gesture. This CL adds the appropriate CONFIG options to enable double tap gesture for Eve and enables the interrupt for the bmi160. The board specific function in this CL is just a placeholder. BUG=b:35584895 BRANCH=none TEST=Manual Verifed double tap is detected by seeing the console print that's generated each time a double tap event occurs. Change-Id: If3506cf1fbcfc2b380ac36c9d3039e0a8823eba1 Signed-off-by: Scott Collyer <scollyer@google.com> Reviewed-on: https://chromium-review.googlesource.com/516547 Commit-Ready: Scott Collyer <scollyer@chromium.org> Tested-by: Scott Collyer <scollyer@chromium.org> Reviewed-by: Gwendal Grignou <gwendal@chromium.org> Reviewed-by: Duncan Laurie <dlaurie@google.com>
Diffstat (limited to 'board/eve/board.h')
-rw-r--r--board/eve/board.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/board/eve/board.h b/board/eve/board.h
index a018e9f96c..29967c07ef 100644
--- a/board/eve/board.h
+++ b/board/eve/board.h
@@ -140,6 +140,17 @@
/* Depends on how fast the AP boots and typical ODRs */
#define CONFIG_ACCEL_FIFO_THRES (CONFIG_ACCEL_FIFO / 3)
+/* Enable double tap detection */
+#define CONFIG_GESTURE_DETECTION
+#define CONFIG_GESTURE_HOST_DETECTION
+#define CONFIG_GESTURE_SENSOR_BATTERY_TAP 1
+#define CONFIG_GESTURE_SAMPLING_INTERVAL_MS 5
+#define CONFIG_GESTURE_TAP_THRES_MG 100
+#define CONFIG_GESTURE_TAP_MAX_INTERSTICE_T 500
+#define CONFIG_GESTURE_DETECTION_MASK \
+ (1 << CONFIG_GESTURE_SENSOR_BATTERY_TAP)
+#define CONFIG_GESTURE_TAP_EVENT TASK_EVENT_CUSTOM(1024)
+
/* USB */
#define CONFIG_USB_CHARGER
#define CONFIG_USB_PD_ALT_MODE