Dummy service named differently from the stock one to avoid conflicts.
This can be used on devices that do not include CPU ricing, but still
require the service to register for camera and prebuilt audio stack to
actually work.
Change-Id: I41087aefe9af57e7a1161a3a71ab3b9e849925f2
Pineapple SOC uses PMIC that has haptics module can support external
control. Add support for it.
Change-Id: I471561a91be8fd054d34dc83860b5b53b8026706
Signed-off-by: madmax7896 <madmax78968@gmail.com>
The previous declaration was resulting in non-working vibrator effects
on vitamin due to the perms being set too late and the service running
too soon at the same time.
This match vitamin's vendor.oplus.hardware.vibrator-service declaration.
Change-Id: Iec7bf9c070da280b9b4920b4d85a22abea3aad67
Not necessarily needed and prevents builds to start on 32-bit-only
targets with this repository also present.
Change-Id: Ic9838753240a25883d591b4be385691f2e070a07
* This is required for devices using a target-level that actually
has these HALs in their compatibility matrix
Change-Id: I29cba455ab92e7708ece405bb29ea1c46e46cf41
The code to support offload was never fully imported when the aidl
vibrator HAL was first added and rebranded to oplus, so remove this
non-working code.
Change-Id: Ifd2e38b362d5fa6a83ecc045401c8e97a34bb1db
Kalama SOC uses PMIC which has haptics module that can support
external control. Add the entry for it.
Change-Id: I49e714837062840f180a4b9e0ed89125cb71c781
* These effects from realme GT2 works well across all devices that use
pm8350b_haptic. The vmax-mv and lra-period-us must be matched with
realme GT2 configuration ie 9100 and 5882 respectively in the device
tree for the effects to work well.
* TICK effects are used for CLICK effect because the stock click effect
feels subjectively weak and are hardly used in stock.
* THUD effects are used for HEAVY_CLICK effects since stock has empty
HEAVY_CLICK effect
Change-Id: I7e15681693777176c19f70ced807c4cabb95c7a1
For aw8697_haptic, OOS 12 never really properly implemented any effect
other than CLICK and HEAVY_CLICK. Let's implement our own TEXTURE_TICK,
TICK, CLICK, and HEAVY_CLICK so that the user can actually feel a
noticeable difference between each haptic effect.
As a quick summary:
- CLICK: same as oplus CLICK, but with vmax set to 2500.
- DOUBLE_CLICK: replaced with our CLICK played twice in a row, w/ a
100ms delay
- TICK: same as oplus CLICK, but with vmax set to 1400.
- HEAVY_CLICK: same as oplus CLICK, but with vmax set to 2500 and
waveform_index set to 4.
- TEXTURE_TICK: same as oplus CLICK, but with vmax set to 60 and
waveform_index set to 2.
In addition, modify LedVibratorDevice's on() to better reflect the
timeout duration actually being passed in to the function. The original
tried to change waveforms instead for various durations at 102 ms or
lower, which didn't really work out in practice for our vibrator.
Change-Id: Ifb769bc2292774afa4977026787a7882430c09d0
It seems that the DOUBLE_CLICK and HEAVY_CLICK effects assume that
`waveform_index` is always set to 1 and `vmax` is set to 1600, because
if the last played effect is TICK, then all the other effects (aside
from CLICK) end up feeling different, presumably because
`waveform_index` is left as set to 2 and `vmax` is left as set to 1600.
Fix this by having DOUBLE_CLICK and HEAVY_CLICK set `waveform_index`
back to 1 and `vmax` back to 1600.
Change-Id: Ic116f45894cf4af25bcd25b66764eeb472631af5
The ndk_platform backend will soon be deprecated because the ndk backend
can serve the same purpose. This is to eliminate the confusion about
having two variants (ndk and ndk_platform) for the same ndk backend.
Bug: 161456198
Test: m
Merged-In: I14a1c57bd06f1f2aa52491f779c7030d4de03547
Change-Id: I7b9055909b901843631314b9577a9e578a739d00
The AOSP TICK effect generated from the following test app:
- https://github.com/luk1337/VibeTest
was used as the starting point. It is more or less the same as oplus
CLICK, except waveform_index is set to 2.
The vibration effect from this TICK was stronger than oplus CLICK, which
is not really desirable, so adjustments were made to vmax in an
unscientific manner until it felt and sounded just right.
Change-Id: I472db022c2b0182e9a0d544c9d439bc3e47e4d82
No of bytes returned by uevent_kernel_multicast_recv() can be 0 or
equal to 1025 bytes. Add change to remove '=' check in Slate SSR
monitor thread to fix the issue of thread not processing UEVENTs
because of wrong check.
Change-Id: I6d8c35a758371b853b545e3eece2fd7788a1424e
* This is a partial revert of 5fba81168e8446448da68a5e546c2aa77b8dd148.
* CAF adds the kernel headers dep to fetch one single value that is
removed in that commit. Easier to just carry it here, especially
considering most devices won't have this in generated_kernel_headers,
even.
Change-Id: I5b7daab2731e4b6b529cdb1ccf0fe173f677f8fd