This patch moves the device playback mode configuration from off() to
on() to avoid the unnecessarily switching from rtp to waveform mode for
consecutive waveform playbacks.
Bug: 62507430
Test: vts, haptic stresss test
Change-Id: I0f7c1f6263dcb4da59695c1619aade47f7381541
Signed-off-by: David Lin <dtwlin@google.com>
Obtain tick/click effect duration from system property and implement the
new perform 1.1 function for supporting tick effect.
Bug: 62176703
Test: VtsHalVibratorV1_1TargetTest
Change-Id: Icbd50c2e7d05fd520aeda4511ba95151dde2a5ed
Signed-off-by: David Lin <dtwlin@google.com>
When outputting uint8_t / char to sysfs using ofstream it gets to
stringified to a character instead of string. For example, writing 127
would get converted to "\x7F\0a" in text while sysfs generally only
accept input in dec "127" or "0x7f" in hex format. This patch changes
the rtp_input type to uint32_t instead.
Bug: 36097386
Test done: VtsHalVibratorV1_0TargetTest all passed
Change-Id: Ie98e42584fd32843dec46edde7af54f9cdcbc4cc
Signed-off-by: David Lin <dtwlin@google.com>
This patch updates the click waveform to use 6 ms full amplitude as well
as switching to open-loop mode for any duration that's less than 20 ms.
The medium and strong now shares the same strength to provide a stronger
default feedback.
Bug: 37952639
Test: keyboard and home key taps
Change-Id: I00086e47e41d97ce8363ba4032eeab320ad1b765
Signed-off-by: David Lin <dtwlin@google.com>
This adds the vibrator HAL that implements the new setAmplitude and
perform(Effect) API.
Test done: vibrator_hidl_hal_test
Bug: 36782452
Change-Id: If9988434277790becb469d4dd928e75f7e6af41a
Signed-off-by: David Lin <dtwlin@google.com>