How To Configure ACC

Download as txt, pdf, or txt
Download as txt, pdf, or txt
You are on page 1of 6

configVerCode=202010270

capacity=(0 60 70 75 false)
temperature=(40 60 90 65)
cooldownRatio=( )
cooldownCurrent=
cooldownCustom=()
resetBattStats=(false false)
chargingSwitch=()
applyOnBoot=()
applyOnPlug=()
maxChargingCurrent=()
maxChargingVoltage=()
language=en
runCmdOnPause=()
ampFactor=
voltFactor=
loopCmd=()
prioritizeBattIdleMode=false

# WARNINGS

# Do not edit this in Windows Notepad, ever!


# It replaces LF (Linux/Unix) with CRLF (Windows) line endings.

# As seen above, whatever is null can be null.


# Nullifying values that should not be null causes nasty errors.
# However, doing so with "--set var=" restores the default value of "var".
# In other words, for regular users, "--set" is safer than modifying the config
file directly.

# Do not feel like you must configure everything!


# Do not change what you don't understand.
# Help is always available, from multiple sources - besides, I don't charge a penny
for it.

# NOTES

# The daemon does not have to be restarted after making changes to this file -
unless one of the changes is charging_switch.

# If charging_switch is changed with --set (e.g., -ss, -s s="...", --set


charging_switch="..."), accd is restarted automatically, as needed.

# BASICS

# capacity=(shutdown_capacity cooldown_capacity resume_capacity pause_capacity


capacity_freeze2)

# temperature=(cooldown_temp max_temp max_temp_pause shutdown_temp)

# cooldownRatio=(cooldown_charge cooldown_pause)

# cooldownCustom=cooldown_custom=(file raw_value charge_seconds pause_seconds)

# cooldownCurrent=cooldown_current=[milliamps]
# resetBattStats=(reset_batt_stats_on_pause reset_batt_stats_on_unplug)

# chargingSwitch=charging_switch=(ctrl_file1 on off ctrl_file2 on off --)

# chargingSwitch=charging_switch=(milliamps)

# applyOnBoot=apply_on_boot=(ctrl_file1::value1::default1
ctrl_file2::value2::default2 ... --exit)

# applyOnPlug=apply_on_plug=(ctrl_file1::value1::default1
ctrl_file2::value2::default2 ...)

# maxChargingCurrent=max_charging_current=([value] ctrl_file1::value::default1
ctrl_file2::value::default2 ...)

# maxChargingVoltage=max_charging_voltage=([value] ctrl_file1::value::default1
ctrl_file2::value::default2 ...) --exit)

# language=lang=language_code

# runCmdOnPause=run_cmd_on_pause=(. script)

# ampFactor=amp_factor=[multiplier]

# voltFactor=volt_factor=[multiplier]

# loopCmd=loop_cmd=(. script)

# prioritizeBattIdleMode=prioritize_batt_idle_mode=boolean

# VARIABLE ALIASES/SORTCUTS

# cc cooldown_capacity
# rc resume_capacity
# pc pause_capacity
# cft capacity_freeze2

# sc shutdown_capacity
# ct cooldown_temp
# cch cooldown_charge
# cp cooldown_pause

# mt max_temp
# mtp max_temp_pause

# st shutdown_temp

# ccu cooldown_custom
# cdc cooldown_current

# rbsp reset_batt_stats_on_pause
# rbsu reset_batt_stats_on_unplug

# s charging_switch

# ab apply_on_boot
# ap apply_on_plug
# mcc max_charging_current
# mcv max_charging_voltage

# l lang
# rcp run_cmd_on_pause

# af amp_factor
# vf volt_factor

# lc loop_cmd
# pbim prioritize_batt_idle_mode

# COMMAND EXAMPLES

# acc 85 80
# acc -s pc=85 rc=80
# acc --set pause_capacity=85 resume_capacity=80

# acc -s "s=battery/charging_enabled 1 0"


# acc --set "charging_switch=/proc/mtk_battery_cmd/current_cmd 0::0 0::1
/proc/mtk_battery_cmd/en_power_path 1 0" ("::" = " ")

# acc -s -v 3920 (millivolts)


# acc -s -c 500 (milliamps)

# custom config path


# acc /data/acc-night-config.txt 45 43
# acc /data/acc-night-config.txt -s c 500
# accd /data/acc-night-config.txt

# acc -s "ccu=battery/current_now 1450000 100 20"


# acc -s "cooldown_custom=battery/current_now 1450000 100 20"
# acc -s ccu="/sys/devices/virtual/thermal/thermal_zone1/temp 55 50 10"

# acc -s amp_factor=1000
# acc -s volt_factor=1000000

# acc -s mcc=500 mcv="3920 --exit"

# acc -s loop_cmd="echo 0 \\> battery/input_suspend"

# acc -s cooldown_current=500

# acc -s st=60

# FINE, BUT WHAT DOES EACH OF THESE VARIABLES ACTUALLY MEAN?

# configVerCode #
# This is checked during updates to determine whether config should be patched. Do
NOT modify.

# shutdown_capacity (sc) #
# When the battery is discharging and its capacity <= sc and phone has been running
for 15 minutes or more, acc daemon turns the phone off to reduce the discharge rate
and protect the battery from potential damage induced by voltage below the
operating range.
# cooldown_capacity (cc) #
# Capacity at which the cooldown cycle starts.
# Cooldown reduces battery stress induced by prolonged exposure to high temperature
and high charging voltage.
# It does so through periodically pausing charging for a few seconds (more details
below).

# resume_capacity (rc) #
# Capacity at which charging should resume.

# pause_capacity (pc) #
# Capacity at which charging should pause.

# capacity_freeze2 (cft) #
# This prevents Android from getting capacity readings below 2%.
# It's useful on systems that shutdown before the battery is actually empty.

# cooldown_temp (ct) #
# Temperature (°C) at which the cooldown cycle starts.
# Cooldown reduces the battery degradation rate by lowering the device's
temperature.
# Refer back to cooldown_capacity for more details.

# max_temp (mt) #
# mtp or max_temp_pause #
# These two work together and are NOT tied to the cooldown cycle.
# On max_temp (°C), charging is paused for max_temp_pause (seconds).
# Unlike the cooldown cycle, which aims at reducing BOTH high temperature and high
voltage induced stress - this is ONLY meant specifically for reducing high
temperature induced stress.
# Even though both are separate features, this complements the cooldown cycle when
environmental temperatures are off the charts.

# shutdown_temp (st) #
# Shutdown the system if battery temperature >= this value.

# cooldown_charge (cch) #
# cooldown_pause (cp) #
# These two dictate the cooldown cycle intervals (seconds).
# When not set, the cycle is disabled.
# Suggested values are cch=50 and cp=10.
# If charging gets a bit slower than desired, try cch=50 and cp=5.
# Note that cooldown_capacity and cooldown_temp can be disabled individually by
assigning them values that would never be reached under normal circumstances.

# cooldown_custom (ccu) #
# When cooldown_capacity and/or cooldown_temp don't suit your needs, this comes to
the rescue.
# It takes precedence over the regular cooldown settings.
# Refer back the command examples.

# cooldown_current (cdc) #
# Instead of pausing charging periodically during the cooldown phase, limit the max
charging current (e.g., to 500 mA)

# reset_batt_stats_on_pause (rbsp) #
# Reset battery stats after pausing charging.

# reset_batt_stats_on_unplug (rbsu) #
# Reset battery stats if the charger has been unplugged for 10 seconds.

# charging_switch (s) #
# If unset, acc cycles through its database and sets the first working switch/group
that disables charging.
# If the set switch/group doesn't work, acc unsets chargingSwitch and repeats the
above.
# If all switches fail to disable charging, chargingSwitch is unset and acc/d exit
with error code 7.
# This automated process can be disabled by appending "--" to
"charging_switch=...".
# e.g., acc -s s="battery/charge_enabled 1 0 --"
# charging_switch=milliamps (e.g., 0, 250 or 500) enables current-based charging
control.
# For details, refer to the readme's tips section.
# Unlike the original variant, this kind of switch is never unset automatically.
# Appending " --" to it leads to invalid syntax.

# apply_on_boot (ab) #
# Settings to apply on boot or daemon start/restart.
# The --exit flag (refer back to applyOnBoot=...) tells the daemon to stop after
applying settings.
# If the --exit flag is not included, default values are restored when the daemon
stops.

# apply_on_plug (ap) #
# Settings to apply on plug
# This exists because some /sys files (e.g., current_max) are reset on charger re-
plug.
# Default values are restored on unplug and when the daemon stops.

# max_charging_current (mcc) #
# max_charging_voltage (mcv) #
# Only the current/voltage value is to be supplied.
# Control files are automatically selected.
# Refer back to the command examples.

# lang (l) #
# acc language, managed with "acc --set --lang" (acc -s l).

# run_cmd_on_pause (rcp) #
# Run commands* after pausing charging.
# * Usually a script ("sh some_file" or ". some_file")

# amp_factor (af) #
# volt_factor (vf) #
# Unit multiplier for conversion (e.g., 1V = 1000000 Microvolts)
# ACC can automatically determine the units, but the mechanism is not 100%
foolproof.
# e.g., if the input current is too low, the unit is miscalculated.
# This issue is rare, though.
# Leave these properties alone if everything is running fine.

# loop_cmd (lc) #
# This is meant for extending accd's functionality.
# It is periodically executed by is_charging() - which is called regularly, within
the main accd loop.
# The boolean isCharging is available.
# Refer back to COMMAND EXAMPLES.
# prioritize_batt_idle_mode (pbim) #
# If enabled charging switches that support battery idle mode take precedence.
# This is disabled by default due to issues on Samsung (store_mode) and other
devices.

You might also like