ports/127810: hplip 2.8.2 can't talk to my usnb printer (HP PS8250)

Torfinn Ingolfsen torfinn.ingolfsen at broadpark.no
Fri Oct 3 07:50:02 UTC 2008


>Number:         127810
>Category:       ports
>Synopsis:       hplip 2.8.2 can't talk to my usnb printer (HP PS8250)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Oct 03 07:50:01 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     Torfinn Ingolfsen
>Release:        FreeBSD 7.0-STABLE i386
>Organization:
LNSF 
>Environment:


System: FreeBSD 7.0-STABLE #1: Mon Sep 22 23:02:46 CEST 2008
    root at kg-work2.kg4.no:/usr/obj/usr/src/sys/SX270



>Description:


History: my HP PS 8250 printer (usb) have been working with hplip since teh days of the port to FreeBSD.

Recently I moved the printer to a new workstation. I installed hplip from ports, but hp-setup would not detect the printer. Further investigation revealed that hp-probe thinks the serial number is zero:
  Device URI                               Model                    
  ---------------------------------------  -------------------------
  hp:/usb/Photosmart_8200_series?serial=0  HP Photosmart 8200 series
and that is wrong, because on my old workstation, it got the serial number right.

I found a patch by searchin the net (see Fix section), and that got me as afr as hp-probe working correctly.
hp-setup still doesn't work, ending with this error message:
Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed

I used the cups web interface to set up my printer.


>How-To-Repeat:


- install HPLIP from ports
- attach HP PS 8250 printer via usb
- try to use hp-setup or hp-probe to find the printer


>Fix:


A bit of searching found this thread[1] and this patch[2] by Isaac Mushinsky. His patch is backwards (it need to be added with the -R flag), but that was easily fixed, see attached patch.
--- patch-io_hpmud_musb.c begins here ---

$FreeBSD$

--- io/hpmud/musb.c.orig
+++ io/hpmud/musb.c
@@ -121,10 +121,12 @@
    {
       ret = usb_control_msg(dev, USB_ENDPOINT_IN, USB_REQ_GET_DESCRIPTOR, (USB_DT_STRING << 8) + index, 
                0x409, tbuf, sizeof(tbuf), LIBUSB_CONTROL_REQ_TIMEOUT);
-      if (ret==0)
+      if (ret <=0 )
       {
-         /* This retry is necessary for lj1000 and lj1005. des 12/12/07 */
-         BUG("get_string_descriptor zero result, retrying...");
+         /* This retry is necessary for lj1000 and lj1005. des 12/12/07
+	  Also HP Photosmart 42xx seems to suffer transient errors with serial id */
+	 BUG("get_string_descriptor error result %d, retrying in 2 secs...", ret);
+	 sleep(2);
          continue;
       }
       break;
--- patch-io_hpmud_musb.c ends here ---

With this patch hp-probe reports the serial number correctly:
  Device URI                                            Model                    
  ----------------------------------------------------  -------------------------
  hp:/usb/Photosmart_8200_series?serial=MY61B3X1NC04KJ  HP Photosmart 8200 series

References:
1) http://lists.freebsd.org/pipermail/freebsd-questions/2008-March/171994.html
2) http://lists.freebsd.org/pipermail/freebsd-questions/2008-March/172250.html


>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list