WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: CUPS without HPLIP for HP printers (SOLVED)  (Read 7931 times)

Offline xyz-worx

  • Jr. Member
  • **
  • Posts: 69
CUPS without HPLIP for HP printers (SOLVED)
« on: January 22, 2012, 12:19:27 PM »
Hi all,
the last days I installed CUPS together with hplip-2.7 and the ghostscript package to
get a HP LaserJet 5L running - and it works.
Unfortunately the hplip package is very huge due to the dependency  of python, which I do not need.
Browsing the Wikis and the forum did  show, that it must be possible to use e. g. gutenprint
and/or foomatic-rip instead of hplip. Testing several different combinations (e. g. with cups1311)
I got always the same behaviour:
After I start dbus and cups and type

Code: [Select]
sudo lpinfo -v
I get no information about my LJ5L attached to the parallel port.
If I do the same having hplip installed, one of several other messages is:

Code: [Select]
sudo lpinfo -v
...
direct hp:/par/HP_Laser_Jet5L?device=/dev/parport0
 

My questions are:
  • What does hplip contain what the others don't have?
  • Is there (for the first case) a package, which can be installed additionally to get the printer recognized?

best regards

xyz-worx
« Last Edit: January 30, 2012, 04:08:36 AM by xyz-worx »

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: CUPS without HPLIP for HP printers
« Reply #1 on: January 22, 2012, 01:14:52 PM »
You'd need to check if the kernel parallel port drivers are loaded and the libieee1284 extension might help

Offline xyz-worx

  • Jr. Member
  • **
  • Posts: 69
Re: CUPS without HPLIP for HP printers
« Reply #2 on: January 22, 2012, 01:32:17 PM »
Hi Juanito,
thank you for your reply.
I think the parallel port drivers are loaded, because dmesg reports
Code: [Select]
parport0: Printer , Hewlett-Packard  HP LaserJet 5L
ppdev: user-space parallel port driver

So I will check, if libieee1284 will work.

best regards
xyz-worx

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: CUPS without HPLIP for HP printers
« Reply #3 on: January 22, 2012, 10:40:39 PM »
What does "lsmod" show in terms of parallel port drivers?

Offline xyz-worx

  • Jr. Member
  • **
  • Posts: 69
Re: CUPS without HPLIP for HP printers
« Reply #4 on: January 23, 2012, 04:26:58 PM »
Regardless of hplip being loaded or not, lsmod gives the same output:

Code: [Select]
tc@box:~$ lsmod
Module                  Size  Used by    Tainted: G 
nfsd                  162388  8
exportfs                2096  1 nfsd
squashfs               14724  0
scsi_wait_scan           276  0
ppdev                   3732  0
parport_pc             18656  0
parport                18560  2 ppdev,parport_pc
ramzswap               10240  1
loop                    8068  0
dmfe                   11348  0

Installing libieee1284 also does not show a printer on the parallel port via lpinfo.

It's interesting, if someone could setup a non Hewlett Packard printer on the parallel port.

Is there anybody out there?


Online Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11702
Re: CUPS without HPLIP for HP printers
« Reply #5 on: January 23, 2012, 04:53:00 PM »
Hi xyz-worx
For what it is worth, I noticed that  libieee1284  includes a program called  libieee1284_test.
You could try running that and see if it reports anything interesting. You could also try
libieee1284_test  --help    to see if it offers any useful options.

Offline Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14851
Re: CUPS without HPLIP for HP printers
« Reply #6 on: January 24, 2012, 12:32:13 AM »
The required parallel port drivers seem to be loaded - what uri are you using in cups for the printer?

Offline SamK

  • Hero Member
  • *****
  • Posts: 713
Re: CUPS without HPLIP for HP printers
« Reply #7 on: January 24, 2012, 02:09:37 AM »
Hi xyz-worx

Regardless of hplip being loaded or not, lsmod gives the same output:

Code: [Select]
tc@box:~$ lsmod
Module                  Size  Used by    Tainted: G 
nfsd                  162388  8
exportfs                2096  1 nfsd
squashfs               14724  0
scsi_wait_scan           276  0
ppdev                   3732  0
parport_pc             18656  0
parport                18560  2 ppdev,parport_pc
ramzswap               10240  1
loop                    8068  0
dmfe                   11348  0
The lp module is not listed. 

You might try
Code: [Select]
sudo modprobe lpand test with
Code: [Select]
lsmod | grep lp
It should report something similar to
Code: [Select]
lp                      7454  0
parport                31046  3 parport_pc,ppdev,lp

My preference is to load the lp module before loading any of the printer related extensions.

Offline xyz-worx

  • Jr. Member
  • **
  • Posts: 69
Re: CUPS without HPLIP for HP printers
« Reply #8 on: January 24, 2012, 03:12:36 PM »
Thank you all for your support.
That's what I found out:

@Juanito:
As  described in my first post, the uri is
 hp:/par/HP_Laser_Jet5L?device=/dev/parport0

@Rich
With libieee1284 installed I get

Code: [Select]
tc@box:~$ libieee1284_test
Found 3 ports:
  0x278:
  0x378:
  0x3bc:

0x278: inaccessible
0x378: inaccessible
0x3bc: inaccessible

I don't know, what exactly this lib is doing. It reports, that no port is accessable, but on the
other hand, dmesg says
Code: [Select]
...
parport_pc 00:0a: reported by Plug and Play ACPI
parport0: PC-style at 0x378, irq 7 [PCSPP,TRISTATE,EPP]
Adding 128704k swap on /dev/ramzswap0.  Priority:-1 extents:1 across:128704k SS
parport0: Printer, Hewlett-Packard HP LaserJet 5L
ppdev: user-space parallel port driver
...
So I think there is a port at 0x378 - and it works as soon as hplip is active.

@SamK:
There is definitely no modul 'lp' present and obviously hplip does not need it.
As far as I could see, modprobe is not part of TC. So I will look, where I can find
and install it.

Thanks
xyz-worx


Online Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11702
Re: CUPS without HPLIP for HP printers
« Reply #9 on: January 24, 2012, 03:51:20 PM »
Hi xyz-worx
Quote
As far as I could see, modprobe is not part of TC.
It is part of Tinycore. If you enter  ls -l /sbin/modprobe  it should show that it is a link back to
/bin/busybox.

Offline xyz-worx

  • Jr. Member
  • **
  • Posts: 69
Re: CUPS without HPLIP for HP printers
« Reply #10 on: January 24, 2012, 05:30:41 PM »
Thank you guys!
The lp module seems to lead me to the solution!  After loading this module, lpinfo
now reports

direct parallel:/dev/lp0

and with this, cups-admin offers the HP LJ5L to install  on this port. What I have to do is
to find a place to invoke the lp module - I'll try in bootlocal.sh.
As soon as it works, I will let you know.

Thanks again!

Offline xyz-worx

  • Jr. Member
  • **
  • Posts: 69
Re: CUPS without HPLIP for HP printers (Solved)
« Reply #11 on: January 28, 2012, 09:49:25 AM »
Finally I got what I wanted.  After inserting  'modprobe lp' to bootlocal.sh the print system
works, only consisting of
CUPS
ghostscript and
ghostscript-commons

The only thing I had to fetch externally was the PPD file for my HP LJ5L.
But for this http://www.openprinting.org has all the information one needs.

By the way, with this compilation of modules - avoiding hplip - I was able to
save more than 19 (unnecessary) MB.
And this keeps my Tiny Core tiny furthermore!

thanx for your support and bye
xyz-worx