- LICENSE AND COPYRIGHT
Printer::HP::Display - Change the default ready message on your HP laser printer
This module allows you to change the value of the ready message (usually 'Ready') on the tiny LCD display that practically all HP laser printers have. You can also retrieve the value of the currently set message. The module communicates with the printer using Printer Job Language (PJL). See: http://en.wikipedia.org/wiki/Printer_Job_Language
At the moment this module is just a fun project; somewhat on the lines of ACME::LOLCAT. For example, at Cricinfo we use it to show cricket scores on our printer screen (http://twitpic.com/26yt2d). You should be careful with what you do to the printers at your office - not all IT managers have a funny bone :-).
Here's how you'd use it in you code:
use Printer::HP::Display; my $printer_ip = "192.168.0.1"; my $printer = Printer::HP::Display->new($printer_ip); my $message = "I am ready. Are you?"; $printer->set_display($message); print $printer->get_display; #currently set message print $printer->get_status; #complete dump of PJL INFO STATUS command
Create a Printer::HP::Display object.
Set the ready message on the printer's display to something of your choice. The string must be pure ASCII - you'll get ? in place of characters that are not ASCII. At the moment set_display doesn't check the length of the string. Anything between 20-50 is a good idea but check your printer's display and tweak accordingly. Some models will truncate the string to fit the available space others will simply refuse to set it.
Get the currently set ready message.
Get a raw dump of the PJL INFO STATUS command. Returns an array with one element per line of message received from the printer.
<deepak.gulati at gmail.com>
Please report any bugs or feature requests to
bug-printer-hp-display at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Printer-HP-Display. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
You can find documentation for this module with the perldoc command.
You can also look for information at:
RT: CPAN's request tracker
AnnoCPAN: Annotated CPAN documentation
Inspired by Scott Allen's article and C# code at: http://odetocode.com/humor/68.aspx
LICENSE AND COPYRIGHT
Copyright 2010 Deepak Gulati.
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.