• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1on boot
2    wait /sys/class/leds/vibrator/device
3
4    mkdir /mnt/vendor/persist/haptics 0770 system system
5    chmod 770 /mnt/vendor/persist/haptics
6    chmod 440 /mnt/vendor/persist/haptics/cs40l25a.cal
7    chown system system /mnt/vendor/persist/haptics
8    chown system system /mnt/vendor/persist/haptics/cs40l25a.cal
9
10    chown system system /sys/class/leds/vibrator/activate
11    chown system system /sys/class/leds/vibrator/brightness
12    chown system system /sys/class/leds/vibrator/duration
13    chown system system /sys/class/leds/vibrator/state
14
15    chown system system /sys/class/leds/vibrator/device/asp_enable
16    chown system system /sys/class/leds/vibrator/device/available_pwle_segments
17    chown system system /sys/class/leds/vibrator/device/clab_enable
18    chown system system /sys/class/leds/vibrator/device/comp_enable
19    chown system system /sys/class/leds/vibrator/device/cp_dig_scale
20    chown system system /sys/class/leds/vibrator/device/cp_trigger_duration
21    chown system system /sys/class/leds/vibrator/device/cp_trigger_index
22    chown system system /sys/class/leds/vibrator/device/cp_trigger_q_sub
23    chown system system /sys/class/leds/vibrator/device/cp_trigger_queue
24    chown system system /sys/class/leds/vibrator/device/dig_scale
25    chown system system /sys/class/leds/vibrator/device/exc_enable
26    chown system system /sys/class/leds/vibrator/device/f0_stored
27    chown system system /sys/class/leds/vibrator/device/f0_offset
28    chown system system /sys/class/leds/vibrator/device/fw_rev
29    chown system system /sys/class/leds/vibrator/device/gpio1_fall_dig_scale
30    chown system system /sys/class/leds/vibrator/device/gpio1_fall_index
31    chown system system /sys/class/leds/vibrator/device/gpio1_rise_dig_scale
32    chown system system /sys/class/leds/vibrator/device/gpio1_rise_index
33    chown system system /sys/class/leds/vibrator/device/heartbeat
34    chown system system /sys/class/leds/vibrator/device/hw_reset
35    chown system system /sys/class/leds/vibrator/device/num_waves
36    chown system system /sys/class/leds/vibrator/device/pwle
37    chown system system /sys/class/leds/vibrator/device/pwle_ramp_down
38    chown system system /sys/class/leds/vibrator/device/q_stored
39    chown system system /sys/class/leds/vibrator/device/redc_comp_enable
40    chown system system /sys/class/leds/vibrator/device/redc_stored
41    chown system system /sys/class/leds/vibrator/device/standby_timeout
42    chown system system /sys/class/leds/vibrator/device/vbatt_max
43    chown system system /sys/class/leds/vibrator/device/vbatt_min
44    chown system system /sys/class/leds/vibrator/device/vibe_state
45
46    enable vendor.vibrator.cs40l25
47
48service vendor.vibrator.cs40l25 /vendor/bin/hw/android.hardware.vibrator-service.cs40l25
49    class hal
50    user system
51    group system
52
53    setenv PROPERTY_PREFIX ro.vendor.vibrator.hal.
54    setenv CALIBRATION_FILEPATH /mnt/vendor/persist/haptics/cs40l25a.cal
55
56    setenv HWAPI_PATH_PREFIX /sys/class/leds/vibrator/
57    setenv HWAPI_DEBUG_PATHS "
58        device/asp_enable
59        device/available_pwle_segments
60        device/clab_enable
61        device/f0_stored
62        device/f0_offset
63        device/fw_rev
64        device/gpio1_fall_dig_scale
65        device/gpio1_fall_index
66        device/gpio1_rise_dig_scale
67        device/gpio1_rise_index
68        device/heartbeat
69        device/num_waves
70        device/pwle
71        device/pwle_ramp_down
72        device/q_stored
73        device/redc_stored
74        device/vibe_state
75        state
76        "
77
78    setenv STATS_INSTANCE default
79
80    disabled
81