SUBSYSTEM=="power_supply", ATTR{status}=="Discharging", RUN+="/bin/sh -c 'echo 0 > /sys/class/leds/logo\:green\:bottom/brightness; echo 100 > /sys/class/leds/logo\:red\:bottom/brightness; echo 0 > /sys/class/leds/logo\:blue\:bottom/brightness'"
SUBSYSTEM=="power_supply", ATTR{status}=="Charging", RUN+="/bin/sh -c 'echo 100 > /sys/class/leds/logo\:green\:bottom/brightness; echo 100 > /sys/class/leds/logo\:red\:bottom/brightness; echo 0 > /sys/class/leds/logo\:blue\:bottom/brightness'"
SUBSYSTEM=="power_supply", ATTR{status}=="Discharging", ATTR{capacity}=="[5-9][0-9]", RUN+="/bin/sh -c 'echo $attr{capacity} > /sys/class/leds/logo\:green\:top/brightness; echo 0 > /sys/class/leds/logo\:red\:top/brightness; echo 0 > /sys/class/leds/logo\:blue\:top/brightness'"
SUBSYSTEM=="power_supply", ATTR{status}=="Discharging", ATTR{capacity}=="[2-4][0-9]", RUN+="/bin/sh -c 'echo $(($attr{capacity} + 50)) > /sys/class/leds/logo\:green\:top/brightness; echo $(($attr{capacity} + 50))> /sys/class/leds/logo\:red\:top/brightness; echo 0 > /sys/class/leds/logo\:blue\:top/brightness'"
SUBSYSTEM=="power_supply", ATTR{status}=="Discharging", ATTR{capacity}=="[01]?[0-9]", RUN+="/bin/sh -c 'echo 0 > /sys/class/leds/logo\:green\:top/brightness; echo $(($att{capacity} + 100)) > /sys/class/leds/logo\:red\:top/brightness; echo 0 > /sys/class/leds/logo\:blue\:top/brightness'"
SUBSYSTEM=="power_supply", ATTR{status}=="Charging", ATTR{capacity}=="[0-4][0-9]", RUN+="/bin/sh -c 'echo 0 > /sys/class/leds/logo\:green\:top/brightness; echo $(($attr{capacity} + 50)) > /sys/class/leds/logo\:red\:top/brightness; echo 0 > /sys/class/leds/logo\:blue\:top/brightness'"
SUBSYSTEM=="power_supply", ATTR{status}=="Charging", ATTR{capacity}=="[5-7][0-9]", RUN+="/bin/sh -c 'echo $(($attr{capacity} + 50)) > /sys/class/leds/logo\:green\:top/brightness; echo $(($attr{capacity} + 50)) > /sys/class/leds/logo\:red\:top/brightness; echo 0 > /sys/class/leds/logo\:blue\:top/brightness'"
SUBSYSTEM=="power_supply", ATTR{status}=="Charging", ATTR{capacity}=="[8-9][0-9]", RUN+="/bin/sh -c 'echo $attr{capacity} > /sys/class/leds/logo\:green\:top/brightness; echo 0 > /sys/class/leds/logo\:red\:top/brightness; echo 0 > /sys/class/leds/logo\:blue\:top/brightness'"