acpi.py 0.3.1 reviewDownload
acpi.py provides an platform-independent and uniform interface to ACPI. Installation: Linux 2.4 / 2.6 The Linux implementati
acpi.py provides an platform-independent and uniform interface to ACPI.
Linux 2.4 / 2.6
The Linux implementation reads informations from /proc/acpi/. Therefore a low level modul is not needed. Copy the file acpi.py from the acpi.py directory into your Python directory/site-packages (in most cases you must be root for that).
Be sure that the needed ACPI drivers are loaded (on laptops usually battery). You will have subdirectories in /proc/acpi/. That's all.
Note: We have not tested acpi.py elaborately on Linux 2.6.
Python >= 2.0
Linux Kernel 2.4.x (not elaborately tested with kernel 2.6)
Usage is simple. Do something like the following:
battery = acpi.Acpi()
Note that you have to call update() if you want get the current state of battery. Note furthermore that acpi raises exceptions in some cases. Please take a look into the short and well readable source file acpi.py.
What's New in This Release:
A bug in the AcpiLinux.estimated_lifetime() function has been fixed.
acpi.py 0.3.1 keywords