escputil/0040755000076500007650000000000007637703426011414 5ustar philphilescputil/images/0040755000076500007650000000000007637357560012665 5ustar philphilescputil/images/icon.gif0100755000076500007650000000051207636660563014301 0ustar philphilGIF89a00̙fff!,000I8}_Ȍ@V&*j '7[ ң^d1c PbJm2yժ9zK4xqErc.{Pw~x>}H0tj7OdU IafwĊ0@ȧxΌ0вݝߠ87q/<#D@v+)x lb5 Iɓ;escputil/images/inkscale.jpg0100644000076500007650000000413007637357551015153 0ustar philphilJFIFHHC    $.' ",#(7),01444'9=82<.342 /!"1#25u7AQ3BR?1c1c1c1c1c1c1c1c1f?.jԳLT2n2DHaՇpA͕(%њ^ !!^>n@?k,bxX!T1NyarA&V+XWYU81pAۏytKIQ~T%VK؆ =Az4_m%bzശ*)YZUQ Onq1iFuA,E`ITGشn8 o@rݞ_zIj4v%;@xG zA偤1sW$HЪRHC#9[ĩkV2_mRCh=2,]v37~~ȨaZ$Gr,xvc}Ά%IkOc)53 ǀpjj[bŹ\ٴ# bh.9Ic0cYS `@eFEy!y =!:]l5m5ܧB=b-j'A =-&1_s{[ӞH7sn?s>a}/KW]nTX5A P,dQk= c{kh\ԫj'dGd`CGɹHIO*VWSAjB8<ZI˻3798ٌc0ZCV#vz*,:QL"+}!˶nc"RC~ T뱪ҍmoar$ofЌ7 /xy$1c'{,V?1d婔1eouÔ1OWK1=+Ur2~MU c2a cO'ƿ% c?*Ac?s*jeescputil/module.info0100644000076500007650000000007207636660460013551 0ustar philphilname=escputil desc=Epson Inkjet Utility category=hardware escputil/lang/0040755000076500007650000000000007637657253012343 5ustar philphilescputil/lang/en0100644000076500007650000000306407637657253012670 0ustar philphiltitle=Epson Inkjet Printer Utility parallel=Parallel usb=USB options=The following options are available: level_check=Check Ink Levels clean=Clean Print Heads nozzle_check=Nozzle Check id_check=Check Printer Identity no_config=Configuration not read successfully. Please select either USB or Parallel, and select your printer model. interface=What type of printer port do you have? port_ques=Which port is your printer connected to? Select "First" if you only have one port. first=First second=Second third=Third fourth=Fourth update_instructions=Once you've updated your settings by clicking on the "Update Settings" button below, click the "Check Printer Identity" option. If this returns the correct printer then your settings are correct. update_button=Update Settings levels=Ink Levels as follows: Black=Black Cyan=Cyan Magenta=Magenta Yellow=Yellow cleaning=Print heads Cleaning. Please let it finish before choosing any other options. nozzle_message=Printer is printing a set of lines. If any of the lines are broken then please clean the print heads. identity=Printer returned the following identity. no_binary=escputil binary cannot be found. Please ensure that it is installed, and that "Module Config" (above) contains the correct path. wrong_binary1=escputil binary found at wrong_binary2=while your config file states it is at wrong_binary3=Please fix this either in Module Config (above) or by placing escputil in the correct place. error=escputil returned the following error conf_check=Please check that your printer is attached and that Module Config (above) is correct. escputil/index.cgi0100755000076500007650000000706507637702547013222 0ustar philphil#!/usr/bin/perl # index.cgi # Escputil Frontend do '../web-lib.pl' &init_config(); &header($text{'title'},"", undef, 1, 1); my $errorFree=1; exec_feature(); if ($errorFree) {feature_table()}; &footer("", "module_index"); sub exec_feature { #For some weird reason QUERY_STRING turns up a blank. So I reckoned #grabbing the data following the ? from REQUEST_URI would do the biz. #If anyone finds out why QUERY_STRING is blank then please send me a patch. $_ = $ENV{'REQUEST_URI'}; split /\?/; my $feature=$_[1]; if($feature eq "ilevel") { get_levels(); } elsif($feature eq "clean") { clean_heads(); } elsif($feature eq "nozzle") { nozzle_check(); } elsif($feature eq "identify") { check_id(); } else { check_conf(); } } sub check_conf { my $executable = `ls $config{'binary'}`; if ($executable eq "") { my $altBin = `which escputil`; if ($altBin eq "") { print "$text{'no_binary'}
\n"; $errorFree = 0; } else { print "$text{'wrong_binary1'} $altBin $text{'wrong_binary2'} $config{'binary'}
\n"; print "$text{'wrong_binary3'}
\n"; $errorFree = 0; } } } sub get_levels { my %colours=('Black',"000000",'Cyan',"00FFFF",'Magenta',"FF00FF",'Yellow',"FFFF00"); my $usb=""; my $usbflag=""; if ($config{'interface'} eq "USB") {$usb="/usb"; $usbflag=" -u";} my @output=`$config{'binary'} -q$usbflag -r /dev$usb/lp$config{'port'} -i 2>&1`; if ($output[0] !~ /Ink/) { report_error(@output); return; } print "

$text{'levels'}\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "
\n"; foreach $_ (@output) { if ($_ !~ /Ink/) { split; my $width= $_[1] * 5; my $textcolour="000000"; if ($colours{$_[0]} eq $textcolour) {$textcolour="FFFFFF";} print "\n"; print "\n"; print "\n"; print "\n"; print "\n"; print "
$text{$_[0]}$_[1]%
\n"; } print "

\n"; } } sub clean_heads { print "$text{'cleaning'}

\n"; my $usb=""; my $usbflag=""; if ($config{'interface'} eq "USB") {$usb="/usb"; $usbflag=" -u";} my @output=`$config{'binary'} -q$usbflag -r /dev$usb/lp$config{'port'} -c`; } sub nozzle_check { print "$text{'nozzle_message'}

\n"; my $usb=""; my $usbflag=""; if ($config{'interface'} eq "USB") {$usb="/usb"; $usbflag=" -u";} my @output=`$config{'binary'} -q$usbflag -r /dev$usb/lp$config{'port'} -n`; } sub check_id { my $usb=""; my $usbflag=""; if ($config{'interface'} eq "USB") {$usb="/usb"; $usbflag=" -u";} my @output=`$config{'binary'} -q$usbflag -r /dev$usb/lp$config{'port'} -d 2>&1`; if ($output[0] =~ /dev/) { report_error(@output); return; } print "$text{'identity'}

\n"; foreach $_ (@output) { print "$_
\n"; } print "
\n"; } sub feature_table { print "

$text{'options'}
"; print "

\n"; print "\n"; print "\n"; print "
$text{'level_check'}$text{'clean'}$text{'nozzle_check'}$text{'id_check'}
\n"; print "


\n"; } sub report_error { print "$text{'error'}
\n"; print "@_
\n"; print "$text{'conf_check'}
\n"; } escputil/postinstall.pl0100755000076500007650000000041507637703313014320 0ustar philphil#!/usr/bin/perl require '../web-lib.pl' sub module_install { system("mkdir $module_config_directory"); system("touch $module_config_directory/admin.acl"); system("echo \"interface=Parallel\nport=0\nbinary=/usr/bin/escputil\" > $module_config_directory/config"); } escputil/config.info0100644000076500007650000000024607637140632013527 0ustar philphilline2=Printer configuration,11 interface=Printer Interface,1,Parallel-Parallel,USB-USB port=Port Number,1,0-First,1-Second,2-Third,3-Fourth binary=Path to escputil,0 escputil/uninstall.pl0100755000076500007650000000015707637703424013763 0ustar philphil#!/usr/bin/perl require '../web-lib.pl' sub module_uninstall { system("rm -rf $module_config_directory"); }