Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[HOWTO] HP LaserJet 10xx
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
alo-alo
n00b
n00b


Joined: 05 Oct 2003
Posts: 74

PostPosted: Sat Feb 25, 2006 10:28 am    Post subject: [HOWTO] HP LaserJet 10xx Reply with quote

I finally found the solution for the foo2zjs driver (with cups).

Solution: you must use cups (+foo2zjs driver) with hplip's hp backend.

I had problems with my HP LJ 1020 using foo2zjs with cups' usb backend. I got messages like:

Code:
drivers/usb/class/usblp.c: usblp0: failed reading printer status

Code:
drivers/usb/class/usblp.c: usblp0: error -110 reading printer status


After I printed a few pages I have had to turn off the printer to print a new "session", sometimes even to reboot the computer, beacuse the printer ignored to print.

My printer: HP Laserjet 1020 (this howto should work with hp lj 1000 and 1005)

emerge cups:[/code]

Code:
USE="samba" emerge cups


emerge hplip:

Code:
USE="foomaticdb cups usb ppds" emerge hplip


emerge foo2zjs:

Code:
USE="cups ppds foomaticdb usb" ACCEPT_KEYWORDS=~x86 emerge foo2zjs


Remember: foomatic-db must be emerged with the cups and ppds; foomatic-filters with cups. You must reemerge them if they don't have the mentioned USE flags.
Turn on your printer. Start cups and hplip:
Code:
/etc/init.d/cupsd start
/etc/init.d/hplip start

Now comes the most important: configuring cups. Go to the cups administration:
in your browser enter:
Code:
localhost:631

Click on Manager printer -> Add printer. Give name to your printer and click Continue. Now under Device select:
Code:
hp:/usb/HP_LaserJet_<your_printer_model>?device=/dev/usb/lp0 (HP HP_LaserJet_<your printer model>)

With this action you selected the hplip's hp backend (located in /usr/lib/cups/backend/hp)
Click Continue.

Under Model/Driver (Make:) select:
Code:
Hewlett-Packard

Click Continue.
Under Model select your printer. In my case:
Code:
HP LaserJet 1020 Foomatic/foo2zjs (recommended) (en)

Clik Continue and your configuration is done.

With this backend I don't get any error messages in /var/log/messages (see above). The printer works now w/o any problems.
Back to top
View user's profile Send private message
syndr0me
n00b
n00b


Joined: 20 Feb 2006
Posts: 2
Location: Russia, Moscow

PostPosted: Sun Feb 26, 2006 11:50 am    Post subject: Reply with quote

Finally got it working (need to reemerge all printing stuff with "samba" flag). Thanks for this guide.

Basic funtionality is fine, but still missing software paper-out support, implementation for 1200x1200 dpi and printed pages counter. However, this is not so important.
Back to top
View user's profile Send private message
melbaum
n00b
n00b


Joined: 01 Jul 2004
Posts: 35

PostPosted: Fri Mar 03, 2006 9:39 pm    Post subject: lj1020 vs. hald, and trouble with long jobs Reply with quote

I have the same printer and got it working a couple weeks ago. When it works it's really nice. BUT... I have to plug it in with hald stopped! Otherwise I get the error -110 business. There's a little command that comes with foo2zjs called usb_printerid. You do usb_printerid /dev/usb/lp0 and if it answers:
GET_DEVICE_ID string:
MFG:Hewlett-Packard;MDL:HP LaserJet 1020;CMD:ACL;CLS:PRINTER;DES:HP LaserJet 1020;FWVER:20041129;
then you're in business. The annoying catch is to start hald by hand to plug in a disk or something.

Next, you may discover that it drops dead in the middle of long print jobs. This is discussed somewhere on the net already. I suspect that ghostscript hiccups a little and the printer freezes. After that the only solution I found (personally and web-ly) is to turn the power off and on again, to reload the firmware. Aha: provided, of course, that hald is stopped! Has anyone found a way to get around this? It means the printer is only useful if you're sitting right next to it. Even resetting the usb device from the terminal would be a help. Is that possible?

Btw, I'm using kernel 2.6.12-gentoo-r9, udev 058, and hald 0.4.7-r2. Could try updating those if it works better for someone who did. For foo2zjs I had to install the latest ~x86 version, -20060118. Otherwise portage didn't find some of the files.
Back to top
View user's profile Send private message
alo-alo
n00b
n00b


Joined: 05 Oct 2003
Posts: 74

PostPosted: Sat Mar 04, 2006 10:38 am    Post subject: Reply with quote

Ok, you are right, my howto isn't working as it should. I have the same problems like you (long printing-stops, power off is needed etc). You mean with hald you can't even print?

I updated foo2zjs today. Unmerged foo2zjs and downloaded the newest foo2zjs tarball from http://foo2zjs.rkkda.com/ and followed the instructions on the foo2zjs' web page. The situation is the same. I'm using hald 0.5.5.1-r3, kernel 2.6.14-ck7, udev 085.
Back to top
View user's profile Send private message
melbaum
n00b
n00b


Joined: 01 Jul 2004
Posts: 35

PostPosted: Sat Mar 04, 2006 10:45 am    Post subject: Reply with quote

with hald started I get an endless string of error -110 from usblp0 in /var/log/messages. usb_printerid reports device or resource busy. I've been trying to catch it with fuser or lsof when it crashes, but so far no luck killing a process to restore the printer's operation.
Back to top
View user's profile Send private message
alo-alo
n00b
n00b


Joined: 05 Oct 2003
Posts: 74

PostPosted: Sat Mar 04, 2006 11:01 am    Post subject: Reply with quote

I updated the firmware to 20050318 now. Will check now if it makes any differences. I'm running hald all the time and get the error message after printing 15-20+ pages.
Back to top
View user's profile Send private message
alo-alo
n00b
n00b


Joined: 05 Oct 2003
Posts: 74

PostPosted: Sat Mar 04, 2006 11:32 am    Post subject: Reply with quote

OK, with the 20050318 firmware my printer plays crazy :).
Back to top
View user's profile Send private message
melbaum
n00b
n00b


Joined: 01 Jul 2004
Posts: 35

PostPosted: Thu Mar 16, 2006 12:13 pm    Post subject: Reply with quote

any luck? I found that I wasn't following your advice, and still used the cups backend. I changed that to hplip and the printer works differently. not better though. I get different errors. Lately I unmerged foo2zjs and installed it directly as you suggested, with the hotplug script instead of udev rules. still no good. The 2005 firmware doesn't work at all, just freezes on the first job. The old FW still crashes after a few pages. For what it's worth I upgraded ghostscript-esp to 8.15.1 and udev to 079.

here's what I see in /var/log/messages at power-on:

Mar 16 13:02:38 nununu usb 1-4: new high speed USB device using ehci_hcd and address 6
Mar 16 13:02:38 nununu drivers/usb/class/usblp.c: usblp0: USB Bidirectional printer dev 6 if 0 alt 0 proto 2 vid 0x03F0 pid 0x2B17
Mar 16 13:02:39 nununu /etc/hotplug/usb/hplj1020: loading HP LaserJet 1020 firmware /usr/share/foo2zjs/firmware/sihp1020.dl to /dev/usb/lp0 ...
Mar 16 13:02:39 nununu /etc/hotplug/usb/hplj1020: ... download successful.

if hald was running I get this:

Mar 16 13:03:51 nununu python: hpssd [ERROR] Not found
Mar 16 13:03:51 nununu lp0: invalid ModelQueryResult: msg=modelqueryresult result-code=48 prnt/hpijs/hplip_api.c 396
Mar 16 13:03:51 nununu python: hpssd [ERROR] Not found
Mar 16 13:03:51 nununu python: hpssd [ERROR] Unsupported model: HP_LaserJet_1020
Mar 16 13:03:51 nununu foo2zjs-wrapper: foo2zjs-wrapper -P -z1 -r600x600 -p9 -s7 -m1 -n1
Mar 16 13:03:56 nununu hpiod: unable to read uri:hp:/usb/HP_LaserJet_1020?device=/dev/usb/lp0 Device::DeviceID: Input/output error
Mar 16 13:03:56 nununu lp0: INFO: open device failed; will retry in 30 seconds...

I lprm the failed job, stop hald, turn off the printer, and restart hplip:

Mar 16 13:06:43 nununu usb 1-4: new high speed USB device using ehci_hcd and address 7
Mar 16 13:06:43 nununu drivers/usb/class/usblp.c: usblp0: USB Bidirectional printer dev 7 if 0 alt 0 proto 2 vid 0x03F 0 pid 0x2B17
Mar 16 13:06:44 nununu /etc/hotplug/usb/hplj1020: loading HP LaserJet 1020 firmware /usr/share/foo2zjs/firmware/sihp10 20.dl to /dev/usb/lp0 ...
Mar 16 13:06:44 nununu /etc/hotplug/usb/hplj1020: ... download successful.
Mar 16 13:06:56 nununu hpiod: 0.9.7 accepting connections at 32776...

when I print successfully it looks like this, but notice the complaint from hpssd, whatever that is:

Mar 16 13:10:00 nununu python: hpssd [ERROR] Not found
Mar 16 13:10:00 nununu python: hpssd [ERROR] Unsupported model: HP_LaserJet_1020
Mar 16 13:10:05 nununu foo2zjs-wrapper: gs -sPAPERSIZE=a4 -g4960x7016 -r600x600 -sDEVICE=pbmraw
Mar 16 13:10:05 nununu foo2zjs-wrapper: foo2zjs -r600x600 -g4960x7016 -p9 -m1 -n1 -d1 -s7 -z1 -u 96x96 -l 96x96 -P

when it dies I see:

Mar 16 13:19:08 nununu python: hpssd [ERROR] Not found
Mar 16 13:19:08 nununu lp0: invalid ModelQueryResult: msg=modelqueryresult result-code=48 prnt/hpijs/hplip_api.c 396
Mar 16 13:19:08 nununu foo2zjs-wrapper: foo2zjs-wrapper -P -z1 -r600x600 -p9 -s7 -m1 -n1
Mar 16 13:19:22 nununu drivers/usb/class/usblp.c: usblp0: error -110 reading printer status
Mar 16 13:19:32 nununu drivers/usb/class/usblp.c: usblp0: error -110 reading printer status
Mar 16 13:19:42 nununu drivers/usb/class/usblp.c: usblp0: error -110 reading printer status
Mar 16 13:19:52 nununu drivers/usb/class/usblp.c: usblp0: error -110 reading printer status
etc etc etc...

in the new configuration it seems able, sometimes, to go on printing for a while. the funny thing is that even if it manages to finish the job, it doesn't clear it from lpq. I have to do that by hand, and then power-off.

Suspecting hpssd, I found that hp-check and a few other of the hp-* scripts require sip and PyQt. Those should really be dependencies in the foo2zjs ebuild. sip emerges alright, but PyQt requires qscintilla, whose ebuild crashes on an insecure runpath (bugs #81745 and 122343).
Back to top
View user's profile Send private message
alo-alo
n00b
n00b


Joined: 05 Oct 2003
Posts: 74

PostPosted: Sun Mar 19, 2006 7:10 pm    Post subject: Reply with quote

The same here, no luck, the same problems. Yes, the 2005 firmware sucks. I tried the printer on SUSE 10.0, no luck. I'm thinking of getting a new printer, maybe samsung ml-2010. Did you perhaps contact the author of foo2zjs? Does he own hp lj 1020?
Back to top
View user's profile Send private message
melbaum
n00b
n00b


Joined: 01 Jul 2004
Posts: 35

PostPosted: Sun Mar 19, 2006 7:30 pm    Post subject: Reply with quote

no, I didn't contact anyone else. We could send this thread to the author. The printer is really nice so it's a shame it doesn't quite work. Last thought might be to run it in windows under qemu and then network it back to linux. That's really beyond the call of duty, I think!
Back to top
View user's profile Send private message
alo-alo
n00b
n00b


Joined: 05 Oct 2003
Posts: 74

PostPosted: Mon Mar 20, 2006 8:07 am    Post subject: Reply with quote

Ok, I wrote to the author and let's see what will he answer.
Back to top
View user's profile Send private message
alo-alo
n00b
n00b


Joined: 05 Oct 2003
Posts: 74

PostPosted: Wed Apr 05, 2006 11:43 am    Post subject: Reply with quote

melbaum, which motherboard do you have? Could be that the kernel's support for usb 2.0 sucks? The author didn't respond.
Back to top
View user's profile Send private message
fiolek
n00b
n00b


Joined: 08 Apr 2006
Posts: 1

PostPosted: Sat Apr 08, 2006 4:27 pm    Post subject: Reply with quote

This is my e-mails with driver author:

e-mail:1
Hi
firmware is uploaded with no problem on Gentoo when I use to
"make install-hotplug"
I have
"kernel: drivers/usb/class/usblp.c: usblp0: error -110 reading printer status"
problem when I use 2004 firmware

e-mail:2
Thanks for the report, though the message is normal as it is cups that
checks for printer status via an ioctl call which the printer does not
support. Beside this the printer should work.
Alessandro

e-mail:3
I have one more question about printing. On the original foo2zjs my printer
hangs down when I print more than 30 copies how is it with this drivers ?
Did you have any bug report of that behaviour on yours drivers ?

e-mail:4
yep. The solution is uploading the driver twice.
One should be done automatically. then print 1 page and upload it again with
cat /usr/share/foo2zjs/firmware/sihp1020.dl > /dev/usb/lp0
Then the printer should not hang anymore.
Hope this helps.
Alessandro

e-mail:5
Any chance to resolv this problem in the future ?
This printer is not bad but whit linux sometimes make me mad.
Thx for help
Maciek

e-mail:6
New firmware upload should solve the problem, though uploading it like
we do causes problems. Still have to check.
Alessandro
Back to top
View user's profile Send private message
alo-alo
n00b
n00b


Joined: 05 Oct 2003
Posts: 74

PostPosted: Sun Apr 09, 2006 10:53 am    Post subject: Reply with quote

Hm, it does not work for me. I printed a 34 page document. Printed page 1, then uploaded the firmware and could print 27 pages, it stopped at page 29 (it couldn't finish the whole page).
Back to top
View user's profile Send private message
melbaum
n00b
n00b


Joined: 01 Jul 2004
Posts: 35

PostPosted: Sat Apr 15, 2006 10:30 pm    Post subject: Reply with quote

sorry. I stopped getting the reminders and lost track of the thread. I have the printer working under windows in qemu-0.8 with the hp driver. Unfortunately I can't get the network to work so I can see into the windows. (The user-mode network to see out to the internet is fine. just works. but doesn't help.) I managed the networking in qemu-0.7.2 with vde, but that version has no usb support!

I have an IBM T42 laptop. I'd really still prefer an all-linux solution...
Back to top
View user's profile Send private message
alo-alo
n00b
n00b


Joined: 05 Oct 2003
Posts: 74

PostPosted: Sun Apr 30, 2006 5:13 pm    Post subject: Reply with quote

Hi! I installed Fedora 5 and followed http://www.fedoraforum.org/forum/archive/index.php/t-105048.html. And it works. Printed 80 pages without any problems.
Back to top
View user's profile Send private message
genstef
Retired Dev
Retired Dev


Joined: 13 Jun 2004
Posts: 668
Location: M/Bay/Germany

PostPosted: Wed May 03, 2006 11:53 am    Post subject: Reply with quote

I have added a new version of the ebuild. I hope it works better for you guys!
Back to top
View user's profile Send private message
Koxta
Retired Dev
Retired Dev


Joined: 19 Mar 2004
Posts: 204
Location: Warszawa

PostPosted: Wed May 03, 2006 7:54 pm    Post subject: Reply with quote

Hi!

I cannot build the newest version:

Code:
>>> Test phase [not enabled]: net-print/foo2zjs-20060501

>>> Install foo2zjs-20060501 into /var/tmp/portage/foo2zjs-20060501/image/ category net-print
cd icc2ps; make all
make[1]: Entering directory `/var/tmp/portage/foo2zjs-20060501/work/foo2zjs/icc2ps'
make[1]: Nie nic do roboty w `all'.
make[1]: Leaving directory `/var/tmp/portage/foo2zjs-20060501/work/foo2zjs/icc2ps'
#
# Installation Dependencies...
#
        ***
        *** Error: foomatic-rip is not installed!
        ***
make: *** [install-test] B³±d 1


However, all foomatic-related stuff is present:

Code:
hell ~ # eix foomatic
* net-print/foomatic
     Available versions:  3.0.2
     Installed:           3.0.2
     Homepage:            http://www.linuxprinting.org/foomatic.html
     Description:         The Foomatic printing meta package

* net-print/foomatic-db
     Available versions:  20041220 20050606 20050910
     Installed:           20050910
     Homepage:            http://www.linuxprinting.org/foomatic.html
     Description:         Foomatic printer database

* net-print/foomatic-db-engine
     Available versions:  3.0.2
     Installed:           3.0.2
     Homepage:            http://www.linuxprinting.org/foomatic.html
     Description:         Foomatic printer database engine

* net-print/foomatic-filters
     Available versions:  3.0.2
     Installed:           3.0.2
     Homepage:            http://www.linuxprinting.org/foomatic.html
     Description:         Foomatic wrapper scripts

* net-print/foomatic-gui
     Available versions:  ~0.6.7 ~0.7.4.16
     Installed:           none
     Homepage:            http://freshmeat.net/projects/foomatic-gui/
     Description:         GNOME interface for configuring the Foomatic printer filter system


Any ideas?

Best regards,
Jurek 'Koxta' Bartuszek
_________________
Willst du dich von etwas trennen
Dann musst du es verbrennen
Willst du es nie wiedersehen
Lass es schwimmen in Benzin!


Last edited by Koxta on Sat Jan 27, 2007 1:11 pm; edited 1 time in total
Back to top
View user's profile Send private message
genstef
Retired Dev
Retired Dev


Joined: 13 Jun 2004
Posts: 668
Location: M/Bay/Germany

PostPosted: Wed May 03, 2006 11:08 pm    Post subject: Reply with quote

foomatic-rip is part of foomatic-filters.

$ qfile foomatic-rip
net-print/foomatic-filters (/usr/bin/foomatic-rip)


Please remerge that.
Back to top
View user's profile Send private message
Koxta
Retired Dev
Retired Dev


Joined: 19 Mar 2004
Posts: 204
Location: Warszawa

PostPosted: Thu May 04, 2006 12:49 am    Post subject: Reply with quote

Thanks, that worked :)
_________________
Willst du dich von etwas trennen
Dann musst du es verbrennen
Willst du es nie wiedersehen
Lass es schwimmen in Benzin!
Back to top
View user's profile Send private message
gasparov
Tux's lil' helper
Tux's lil' helper


Joined: 13 Apr 2006
Posts: 105

PostPosted: Mon Jun 05, 2006 7:22 pm    Post subject: Reply with quote

I have problems with this printer

emerging foo2zjs
Code:
Connecting to foo2hp.rkkda.com|82.165.129.11|:80... connected.
HTTP request sent, awaiting response... 416 Requested Range Not Satisfiable

    The file is already fully retrieved; nothing to do.

!!! Couldn't download hpclj2600n.tar.gz. Aborting.


Compiling foo2zjs from source leads to no joy,cups is unable to find any printer,usb_printerid and foo2zjs-loadfw give i/o errors,not considering that the author use commands that gentoo doesn't understand (ex--->ed)

BTW:an howto should lead to some kind of positive results,IMO the problem was already present in april and the hplip thing was just a way to walkaround it,as every hack it is not reliable..

Right now I managed to print by installing foo2zjs by hand without the "make install-hotplug" part and doing "cat /usr/share/foo2zjs/firmware/sihp1020.dl >>/dev/usb/lp0",stopping hald doesn't solve the "drivers/usb/class/usblp.c: usblp0: failed reading printer status".
In my opinion this printer is garbage for linux,when i bought i was stupid and tought that by the way it was an hp it had to be linux compatible,it is not.
Back to top
View user's profile Send private message
genstef
Retired Dev
Retired Dev


Joined: 13 Jun 2004
Posts: 668
Location: M/Bay/Germany

PostPosted: Tue Jun 06, 2006 1:50 am    Post subject: Reply with quote

The driver download problem should be fixed already, this printer works very good for me, but it is probably better to use some other printer that does not need a firmware.
Back to top
View user's profile Send private message
slycordinator
Advocate
Advocate


Joined: 31 Jan 2004
Posts: 3065
Location: Korea

PostPosted: Tue Jun 06, 2006 3:57 am    Post subject: Reply with quote

For this guide you should really be using the files /etc/portage/package.use and /etc/portage/package.keywords for specifying per-package USE flags and keywording. As your guide is, if a new version of any of those came out it wouldn't use the USE flags you used. And if you ever tried to update your system it would also try to install an earlier version of foo2zjs.

So, to fix this put these entries:

/etc/portage/package.keywords
Code:
net-print/foo2zjs


/etc/portage/package.use
Code:
net-print/foo2zjs cups ppds foomaticdb usb
net-print/hplip cups ppds foomaticdb usb
net-print/cups samba
Back to top
View user's profile Send private message
genstef
Retired Dev
Retired Dev


Joined: 13 Jun 2004
Posts: 668
Location: M/Bay/Germany

PostPosted: Tue Jun 06, 2006 7:49 am    Post subject: Reply with quote

You do not have to enable any use flag. Rather disable foomaticdb in make.conf. The others are needed but default useflags, so you usually should not need to change anything there.
Back to top
View user's profile Send private message
baigsabeeh
Guru
Guru


Joined: 28 Sep 2005
Posts: 520
Location: North Brunswick, NJ

PostPosted: Sun Jul 30, 2006 10:54 pm    Post subject: Reply with quote

Code:
USE="cups ppds foomaticdb usb" ACCEPT_KEYWORDS=~x86 emerge foo2zjs
Calculating dependencies... done!
>>> Emerging (1 of 1) net-print/foo2zjs-20060607 to /
>>> Downloading ftp://ftp.minolta-qms.com/pub/crc/out_going/win2000/m22dlicc.exe
--18:40:38--  ftp://ftp.minolta-qms.com/pub/crc/out_going/win2000/m22dlicc.exe
           => `/usr/portage/distfiles/m22dlicc.exe'
Resolving ftp.minolta-qms.com... 161.33.3.3
Connecting to ftp.minolta-qms.com|161.33.3.3|:21... failed: Connection timed out.
Retrying.

--18:41:39--  ftp://ftp.minolta-qms.com/pub/crc/out_going/win2000/m22dlicc.exe
  (try: 2) => `/usr/portage/distfiles/m22dlicc.exe'
Connecting to ftp.minolta-qms.com|161.33.3.3|:21... failed: Connection timed out.
Retrying.

--18:42:41--  ftp://ftp.minolta-qms.com/pub/crc/out_going/win2000/m22dlicc.exe
  (try: 3) => `/usr/portage/distfiles/m22dlicc.exe'
Connecting to ftp.minolta-qms.com|161.33.3.3|:21... failed: Connection timed out.
Retrying.

--18:43:44--  ftp://ftp.minolta-qms.com/pub/crc/out_going/win2000/m22dlicc.exe
  (try: 4) => `/usr/portage/distfiles/m22dlicc.exe'
Connecting to ftp.minolta-qms.com|161.33.3.3|:21... failed: Connection timed out.
Retrying.

--18:44:48--  ftp://ftp.minolta-qms.com/pub/crc/out_going/win2000/m22dlicc.exe
  (try: 5) => `/usr/portage/distfiles/m22dlicc.exe'
Connecting to ftp.minolta-qms.com|161.33.3.3|:21... failed: Connection timed out.
Giving up.

!!! Couldn't download m22dlicc.exe. Aborting.


I've tried so many times, but this just won't work. What can I do? I can't find this file either.

Also, for 64-Bit I would use "ACCEPT_KEYWORDS=amd64" right
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum