[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#879719: libsane-hpaio: Does not recognize OfficeJet Pro 8710



On 11/23/2017 05:44 PM, Brian Potkin wrote:
> On Thu 23 Nov 2017 at 14:05:38 +0100, Gedalya wrote:
>
>> On 11/23/2017 01:37 PM, Brian Potkin wrote:
>>>> Note: In order to produce this, I need to stop cupsd. Somehow, at some
>>>> point sane started finding the scanner via CUPS, the printer being
>>>> configured there.
>>> I take this to mean you configured the printer with something like
>>> hp-setup and the device_uri for it begins with hp:/. Please post the
>>> output of
>>>
>>>  lpoptions -p <print_queue_name>
>>>
>>> as confirmation of this.
>> $ lpoptions -p HP_OfficeJet_Pro_8710
>> ColorModel=KGray copies=1 device-uri=hp:/net/HP_OfficeJet_Pro_8710?ip=192.168.9.238
> This device-uri should also be given by hp-makeuri. Would you confirm
> this and check printing takes place.

This in fact works only with the original models.dat, with the hp_ prefix:

$ hp-makeuri 192.168.9.238

HP Linux Imaging and Printing System (ver. 3.17.10)
Device URI Creation Utility ver. 5.0

Copyright (c) 2001-15 HP Development Company, LP
This software comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to distribute it
under certain conditions. See COPYING file for more details.

CUPS URI: hp:/net/HP_OfficeJet_Pro_8710?ip=192.168.9.238
SANE URI: hpaio:/net/HP_OfficeJet_Pro_8710?ip=192.168.9.238
HP Fax URI: hpfax:/net/HP_OfficeJet_Pro_8710?ip=192.168.9.238

Done.

---
with the edited file:

$ hp-makeuri 192.168.9.238

HP Linux Imaging and Printing System (ver. 3.17.10)
Device URI Creation Utility ver. 5.0

Copyright (c) 2001-15 HP Development Company, LP
This software comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to distribute it
under certain conditions. See COPYING file for more details.

error: Device not found

Printing works regardless.

>
> The uri for the scanner is formed by replacing hp:/ with hpaio:/. If
> cups is stopped, scanimage is unable to get the hpaio:/ uri and would
> report no scanners found. your observation above fits this.
>
> But you clearly show Bonjour broadcasting from the printer, so scanimage
> can get an hpaio:/ uri from that, whether cups is running or not. That
> is the way it works here.
>
> So where does scanimage get the uri from when cups is running? From the
> Bonjour broadcasts? What happens when you deactivate broadcasting on the
> printer?

I don't know how to do that.


>>>  Also post what you get for
>>>
>>>  avahi-browse -art | grep -i officejet
>>>
>>> You might have to install the avahi-utils package. 
>> $ avahi-browse -art | grep -i officejet
> [Snipping]
>> +   eth0 IPv6 HP OfficeJet Pro 8710 [XXXXXX]                _scanner._tcp        local
>> +   eth0 IPv4 HP OfficeJet Pro 8710 [XXXXXX]                _scanner._tcp        local
>> =   eth0 IPv4 HP OfficeJet Pro 8710 [XXXXXX]                _scanner._tcp        local
>>    txt = ["feeder=T" "flatbed=T" "button=T" "UUID=1c852a4d-b800-1f08-abcd-xxxxxxxxxxxx" "note=" "adminurl=http://HPxxxxxxxxxxxx.local."; "mdl=OfficeJet Pro 8710" "mfg=HP" "ty=HP OfficeJet Pro 8710" "txtvers=1"]
> This is your scanner. Looks good to me.
>
>>>> On my laptop, where this printer is not installed in CUPS, there is no
>>>> need to stop CUPS to get this error.
>>> Post
>>>
>>>  lpoptions -p <print_queue_name>
>>>
>>> for this machine too.
>> Ummm, the only printer/queue configured on my laptop is a USB printer
>> that I left behind on another continent.  What exactly should I do
>> here?
> Nothing, if there is no hplip or components of hplip on the laptop.

There is, the other printer was HP AIO too, but it's a different model.

>
>>>> With CUPS running, or with models.dat edited:
>>>>
>>>> $ scanimage -L
>>>> device `hpaio:/net/officejet_pro_8710?ip=192.168.9.238&queue=false' is a Hewlett-Packard officejet_pro_8710 all-in-one
>>> I think an explanation for the "CUPS running" can be provided.
> I've attempted that above.
>
>> strace shows it talks to /run/cups/cups.sock. If it can enumerate
>> devices there, it would be just another way of discovering the device.
>> When it does this, I do still get the errors in syslog. It seems to be
>> discovering the printer also over avahi, and then choke on the
>> mismatching string, but nevertheless proceed with what it found via
>> cups.
> As I've said, the scanner uri can come from the printer setup (which I
> think takes precedence) or over avahi. I'm begining to wonder about the
> correctness of the printer uri; but we'll see.
>
> Cheers,
>
> Brian.


Reply to: