Linux.com

Improve the AVG calc

Posted by: Administrator on February 17, 2007 12:22 PM
awk "/remaining/ {a=\"`awk '/last full/ {print $4}'<nobr> <wbr></nobr>/proc/acpi/battery/C171/info`\"; avg=\$3*100/a; print avg}"<nobr> <wbr></nobr>/proc/acpi/battery/C171/state

This makes the calculation of the AVG fater with less commands involved.

#

Return to Improved ways to suspend and hibernate a laptop under Linux