Find the answer to your Linux question:
Results 1 to 6 of 6
Hello I am using Red hat on my laptop and normally playing in the console. As I only plug in the battery supply when the battery is down and going ...
  1. #1
    Linux User vickey_20's Avatar
    Join Date
    Mar 2009
    Location
    Mumbai, India
    Posts
    493

    checking the battery from console

    Hello
    I am using Red hat on my laptop and normally playing in the console. As I only plug in the battery supply when the battery is down and going form console to GUI just to check the battery status is quite cumbersome , So was wondering if the status can be checked form the console itself.

  2. #2
    Linux User vickey_20's Avatar
    Join Date
    Mar 2009
    Location
    Mumbai, India
    Posts
    493

    apm

    hey guys fond this link but this command is not present in my OS(red hat 5).

  3. #3
    Just Joined!
    Join Date
    May 2009
    Posts
    6
    I tried apm but it says no apm support in kernel !

  4. #4
    Linux Guru
    Join Date
    Nov 2004
    Posts
    6,110
    apm was replaced by acpi a few years back. apm was the older power management protocol/standard but this is now handled by acpi. Try
    Code:
    acpi -b
    acpi --help

  5. #5
    Linux Engineer Freston's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    1,047
    So much interesting stuff in /proc

    Code:
    freston@lappy$ cat /proc/acpi/battery/BAT1/state
    present:                 yes
    capacity state:          ok
    charging state:          discharging
    present rate:            0 mA
    remaining capacity:      7128 mAh
    present voltage:         11100 mV
    Can't tell an OS by it's GUI

  6. #6
    Linux User vickey_20's Avatar
    Join Date
    Mar 2009
    Location
    Mumbai, India
    Posts
    493

    file in BAT0 in /proc/acpi/

    Hey i have come across this file called state in /proc/acpi/BAT0
    It contains a file called state which represents the current state of the battery. There is no command like acpi but there is a command called acpid. Whenever i give it on the console I get this message
    Code:
    acpid: can't open /proc/acpi/event : Device or resource busy
    Only if I could understand the man pages
    Registered Linux user #492640
    OS: RHEL4,5 ,RH 9,Ubuntu

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
...