pmaports/main/postmarketos-base/rootfs-lib-udev-rules.d-95-rt5033-battery-refresh.rules
Jakob Hauser bd85700dea
main/postmarketos-base: udev tm2-touchkey and rt5033-battery (MR 2330)
The udev file "20-tm2-touchkey-leds.rules" disables the leds of
tm2-touchkey by default because they are in an unconfigured state.

The udev file "95-rt5033-battery-refresh.rules" triggers a refresh
of the rt5033-battery information within UPower 5 secs after
initialization. This avoids a wrong battery icon after boot.

The udev file "50-firmware.rules" was moved from /etc/udev/rules.d
to /lib/udev/rules.d.

Related: https://wiki.postmarketos.org/wiki/Packaging#Device_specific_quirks
2021-07-11 14:10:03 +02:00

5 lines
326 B
Text

# refresh rt5033-battery information in UPower 5 secs after initialization
ACTION=="add", KERNEL=="rt5033-battery", RUN+="/bin/sh -c 'sleep 5 && \
dbus-send --print-reply --system --dest=org.freedesktop.UPower \
/org/freedesktop/UPower/devices/battery_rt5033_battery \
org.freedesktop.UPower.Device.Refresh > /dev/null 2>&1'"