Manuel Gebele > IBM-ThinkPad-ACPI-Extras-0.02 > IBM::ThinkPad::ACPI::Extras

Download:
IBM-ThinkPad-ACPI-Extras-0.02.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Module Version: 0.01   Source  

NAME ^

IBM::ThinkPad::ACPI::Extras - Perl interface to the IBM ThinkPad ACPI features

SYNOPSIS ^

  use IBM::ThinkPad::ACPI::Extras;

  # Read status of the 'light' feature
  my $light_status = tp_extras_read('light', 'status');

  # Read possible commands of the 'led' feature
  my @led_commands = tp_extras_read('led', 'commands');

  # Read complete EC dump
  print tp_extras_read('ecdump');

  # For the next examples you'll need root privileges!
  # Turn LED 1 off (battery)
  tp_extras_write('led', '1 off');

  # Turn LED 1 on
  tp_extras_write('led', '1 on');

  # Turn ThinkLight on
  tp_extras_write('light', 'on');

DESCRIPTION ^

See the README file that came with the IBM::ThinkPad::ACPI::Extras package for more information.

Public methods

tp_extras_read($feature, $keyword)

The tp_extras_read method is called to read the specified $feature file and looks there for the $keyword (e.g. status).

tp_extras_write($feature, $command)

The tp_extras_write method is called to send the $command to the corresponding $feature file.

EXPORT ^

tp_extras_read tp_extras_write

AUTHOR ^

Manuel Gebele, <forensixs[at]gmx.de>

COPYRIGHT AND LICENSE ^

Copyright (C) 2009 by Manuel Gebele.

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.

syntax highlighting: