From ae23645b9a9d97dfbe9becb3047a6fcf8e703063 Mon Sep 17 00:00:00 2001 From: Chris Paulo Date: Tue, 12 Sep 2023 17:09:53 -0700 Subject: [PATCH 1/2] vibrator: Enable Adaptive Haptics Enable adaptive haptics for these devices. Bug: 284181186 Test: atest SettingsGoogleRoboTests:com.google.android.settings.accessibility.AdaptiveHapticsTogglePreferenceControllerTest Change-Id: Ib29e4785d94ba0e03d54830112b5367061655dba Signed-off-by: Chris Paulo --- device-caiman.mk | 8 +++++++- device-komodo.mk | 8 +++++++- device-tokay.mk | 8 +++++++- 3 files changed, 21 insertions(+), 3 deletions(-) diff --git a/device-caiman.mk b/device-caiman.mk index 9eb436ab..98286104 100644 --- a/device-caiman.mk +++ b/device-caiman.mk @@ -242,10 +242,16 @@ PRODUCT_DEFAULT_PROPERTY_OVERRIDES += vendor.display.preferred_mode=960x2142@120 # Vibrator HAL ACTUATOR_MODEL := luxshare_ict_081545 +ADAPTIVE_HAPTICS_FEATURE := adaptive_haptics_v1 PRODUCT_VENDOR_PROPERTIES += \ ro.vendor.vibrator.hal.chirp.enabled=1 \ ro.vendor.vibrator.hal.device.mass=0.222 \ - ro.vendor.vibrator.hal.loc.coeff=2.8 + ro.vendor.vibrator.hal.loc.coeff=2.8 \ + persist.vendor.vibrator.hal.context.enable=false \ + persist.vendor.vibrator.hal.context.scale=60 \ + persist.vendor.vibrator.hal.context.fade=true \ + persist.vendor.vibrator.hal.context.cooldowntime=1600 \ + persist.vendor.vibrator.hal.context.settlingtime=5000 # PKVM Memory Reclaim PRODUCT_VENDOR_PROPERTIES += \ diff --git a/device-komodo.mk b/device-komodo.mk index 02f0f2d6..c5a7d0b3 100644 --- a/device-komodo.mk +++ b/device-komodo.mk @@ -242,10 +242,16 @@ PRODUCT_VENDOR_PROPERTIES += \ # Vibrator HAL ACTUATOR_MODEL := luxshare_ict_081545 +ADAPTIVE_HAPTICS_FEATURE := adaptive_haptics_v1 PRODUCT_VENDOR_PROPERTIES += \ ro.vendor.vibrator.hal.chirp.enabled=1 \ ro.vendor.vibrator.hal.device.mass=0.222 \ - ro.vendor.vibrator.hal.loc.coeff=2.8 + ro.vendor.vibrator.hal.loc.coeff=2.8 \ + persist.vendor.vibrator.hal.context.enable=false \ + persist.vendor.vibrator.hal.context.scale=60 \ + persist.vendor.vibrator.hal.context.fade=true \ + persist.vendor.vibrator.hal.context.cooldowntime=1600 \ + persist.vendor.vibrator.hal.context.settlingtime=5000 # PKVM Memory Reclaim PRODUCT_VENDOR_PROPERTIES += \ diff --git a/device-tokay.mk b/device-tokay.mk index acfed444..aa5ed4d1 100644 --- a/device-tokay.mk +++ b/device-tokay.mk @@ -233,10 +233,16 @@ PRODUCT_VENDOR_PROPERTIES += \ # Vibrator HAL ACTUATOR_MODEL := luxshare_ict_081545 +ADAPTIVE_HAPTICS_FEATURE := adaptive_haptics_v1 PRODUCT_VENDOR_PROPERTIES += \ ro.vendor.vibrator.hal.chirp.enabled=1 \ ro.vendor.vibrator.hal.device.mass=0.222 \ - ro.vendor.vibrator.hal.loc.coeff=2.8 + ro.vendor.vibrator.hal.loc.coeff=2.8 \ + persist.vendor.vibrator.hal.context.enable=false \ + persist.vendor.vibrator.hal.context.scale=60 \ + persist.vendor.vibrator.hal.context.fade=true \ + persist.vendor.vibrator.hal.context.cooldowntime=1600 \ + persist.vendor.vibrator.hal.context.settlingtime=5000 # PKVM Memory Reclaim PRODUCT_VENDOR_PROPERTIES += \ From a23d6f48641b5820e77ee5ba0e262edf4b4a51c7 Mon Sep 17 00:00:00 2001 From: Chris Paulo Date: Tue, 12 Sep 2023 17:13:29 -0700 Subject: [PATCH 2/2] vibrator: Enable DBC Enable DBC feature for these devices. This will help reduce power when voltage boost is enabled for various waveform playback. Bug: 266505414 Test: atest VibratorHalCs40l26TestSuite Change-Id: I54c95d48707c017e70b691ec00a7acb6d67ec31f Signed-off-by: Chris Paulo --- device-caiman.mk | 9 ++++++++- device-komodo.mk | 9 ++++++++- device-tokay.mk | 9 ++++++++- 3 files changed, 24 insertions(+), 3 deletions(-) diff --git a/device-caiman.mk b/device-caiman.mk index 98286104..590af7c4 100644 --- a/device-caiman.mk +++ b/device-caiman.mk @@ -251,7 +251,14 @@ PRODUCT_VENDOR_PROPERTIES += \ persist.vendor.vibrator.hal.context.scale=60 \ persist.vendor.vibrator.hal.context.fade=true \ persist.vendor.vibrator.hal.context.cooldowntime=1600 \ - persist.vendor.vibrator.hal.context.settlingtime=5000 + persist.vendor.vibrator.hal.context.settlingtime=5000 \ + ro.vendor.vibrator.hal.dbc.enable=true \ + ro.vendor.vibrator.hal.dbc.envrelcoef=8353728 \ + ro.vendor.vibrator.hal.dbc.riseheadroom=1909602 \ + ro.vendor.vibrator.hal.dbc.fallheadroom=1909602 \ + ro.vendor.vibrator.hal.dbc.txlvlthreshfs=2516583 \ + ro.vendor.vibrator.hal.dbc.txlvlholdoffms=0 \ + ro.vendor.vibrator.hal.pm.activetimeout=5 # PKVM Memory Reclaim PRODUCT_VENDOR_PROPERTIES += \ diff --git a/device-komodo.mk b/device-komodo.mk index c5a7d0b3..58655113 100644 --- a/device-komodo.mk +++ b/device-komodo.mk @@ -251,7 +251,14 @@ PRODUCT_VENDOR_PROPERTIES += \ persist.vendor.vibrator.hal.context.scale=60 \ persist.vendor.vibrator.hal.context.fade=true \ persist.vendor.vibrator.hal.context.cooldowntime=1600 \ - persist.vendor.vibrator.hal.context.settlingtime=5000 + persist.vendor.vibrator.hal.context.settlingtime=5000 \ + ro.vendor.vibrator.hal.dbc.enable=true \ + ro.vendor.vibrator.hal.dbc.envrelcoef=8353728 \ + ro.vendor.vibrator.hal.dbc.riseheadroom=1909602 \ + ro.vendor.vibrator.hal.dbc.fallheadroom=1909602 \ + ro.vendor.vibrator.hal.dbc.txlvlthreshfs=2516583 \ + ro.vendor.vibrator.hal.dbc.txlvlholdoffms=0 \ + ro.vendor.vibrator.hal.pm.activetimeout=5 # PKVM Memory Reclaim PRODUCT_VENDOR_PROPERTIES += \ diff --git a/device-tokay.mk b/device-tokay.mk index aa5ed4d1..93306a3d 100644 --- a/device-tokay.mk +++ b/device-tokay.mk @@ -242,7 +242,14 @@ PRODUCT_VENDOR_PROPERTIES += \ persist.vendor.vibrator.hal.context.scale=60 \ persist.vendor.vibrator.hal.context.fade=true \ persist.vendor.vibrator.hal.context.cooldowntime=1600 \ - persist.vendor.vibrator.hal.context.settlingtime=5000 + persist.vendor.vibrator.hal.context.settlingtime=5000 \ + ro.vendor.vibrator.hal.dbc.enable=true \ + ro.vendor.vibrator.hal.dbc.envrelcoef=8353728 \ + ro.vendor.vibrator.hal.dbc.riseheadroom=1909602 \ + ro.vendor.vibrator.hal.dbc.fallheadroom=1909602 \ + ro.vendor.vibrator.hal.dbc.txlvlthreshfs=2516583 \ + ro.vendor.vibrator.hal.dbc.txlvlholdoffms=0 \ + ro.vendor.vibrator.hal.pm.activetimeout=5 # PKVM Memory Reclaim PRODUCT_VENDOR_PROPERTIES += \