summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Wright2018-01-23 18:22:02 -0600
committerMichael Wright2018-01-24 18:53:31 -0600
commited5d92cc7cdaf07bf7e97cc7894f3147cd055b73 (patch)
treea91b6532f33887b5a845e21dfb88526d1f74c49b /vibrator/1.2/types.hal
parentb6371e782db1c82bc2b3261579c4f25c31a9c1b1 (diff)
downloadplatform-hardware-interfaces-ed5d92cc7cdaf07bf7e97cc7894f3147cd055b73.tar.gz
platform-hardware-interfaces-ed5d92cc7cdaf07bf7e97cc7894f3147cd055b73.tar.xz
platform-hardware-interfaces-ed5d92cc7cdaf07bf7e97cc7894f3147cd055b73.zip
Add new vibrator effects.
Add new effects for pop, thud and heavy click, as well as constants to play back pre-defined ringtone effects. Bug: 64185677 Bug: 64184692 Test: run vts --skip-all-system-status-check --skip-preconditions --primary-abi-only --module VtsHalVibratorV1_2TargetTest Change-Id: I4baae73e1471208f9f54bb1c03da8c27ca6b0ee1
Diffstat (limited to 'vibrator/1.2/types.hal')
-rw-r--r--vibrator/1.2/types.hal64
1 files changed, 64 insertions, 0 deletions
diff --git a/vibrator/1.2/types.hal b/vibrator/1.2/types.hal
new file mode 100644
index 00000000..7604f2ce
--- /dev/null
+++ b/vibrator/1.2/types.hal
@@ -0,0 +1,64 @@
1/*
2 * Copyright (C) 2018 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17package android.hardware.vibrator@1.2;
18
19import @1.1::Effect_1_1;
20
21// Note that while the previous type had a version suffix, this type does not. This is because the
22// versions are already present in the namespace and thus don't need to also be embedded in the
23// name of the type.
24enum Effect : @1.1::Effect_1_1 {
25 /**
26 * A thud effect.
27 *
28 * This effect should solid feeling bump, like the depression of a heavy mechanical button.
29 */
30 THUD,
31 /**
32 * A pop effect.
33 *
34 * A short, quick burst effect.
35 */
36 POP,
37
38 /**
39 * A heavy click effect.
40 *
41 * This should produce a sharp striking sensation, like a click but stronger.
42 */
43 HEAVY_CLICK,
44
45 /**
46 * Ringtone patterns. They may correspond with the device's ringtone audio, or may just be a
47 * pattern that can be played as a ringtone with any audio, depending on the device.
48 */
49 RINGTONE_1,
50 RINGTONE_2,
51 RINGTONE_3,
52 RINGTONE_4,
53 RINGTONE_5,
54 RINGTONE_6,
55 RINGTONE_7,
56 RINGTONE_8,
57 RINGTONE_9,
58 RINGTONE_10,
59 RINGTONE_11,
60 RINGTONE_12,
61 RINGTONE_13,
62 RINGTONE_14,
63 RINGTONE_15,
64};