Scanner's HP Laser MFP 137fnw

Kernels & Hardware, configuring network, installing services

Scanner's HP Laser MFP 137fnw

Postby capcla » 2020-05-19 15:46

Hi,
I've buyed this all in one, HP Laser MFP 137fnw, but I had some problems with its configuration. In particular, the OS doesn't recognize the scanner. The driver, downloaded from here https://support.hp.com/us-en/drivers/selfservice/hp-laser-mfp-130-printer-series/24494378/model/24494385, was been installated correctly but xsane doesn't recognize the scanner.
This is the output of scanner installation driver
Code: Select all
# ./install-scanner.sh
**** Esecuzione dell'installazione in corso...
**** Premere 'Invio' per continuare oppure 'q' e quindi 'Invio' per uscire. :
.
.
.
**** Accettare? [s/n]:y
**** Nel sistema è già installata la stessa versione del driver di scansione.
**** Installazione completata.

Sorry but the output is in italian. In any case, the last two rows of the output tell that "In the system is alread installed the same version of driver" (I tried many times the installation) "Installation compleated".
How can i do?
Thanks
capcla
 
Posts: 30
Joined: 2015-06-24 15:36

Re: Scanner's HP Laser MFP 137fnw

Postby eriefisher » 2020-05-20 10:38

Does the printer work as expected?
Confirm you have the needed packages installed.
Code: Select all
apt install hplip libsane-hpaio sane libsane

Then run:
Code: Select all
scanimage -L

If nothing appears
Code: Select all
sane-find-scanner

Does the scanner appear? If yes then you can use your favourite app to test.
Code: Select all
xsane <devicename or url>
simple-scan <device name or url>
____________________________________________
There's a manual?
Siduction
Debian Sid
Xfce4 4.14
User avatar
eriefisher
 
Posts: 130
Joined: 2008-06-04 03:49
Location: Ontario's South Coast

Re: Scanner's HP Laser MFP 137fnw

Postby capcla » 2020-05-21 16:12

eriefisher wrote:Does the printer work as expected?

Yes, but I used an escamotage. HPLIP didn't recognize the printer and the printer driver installation gave the same result of the scanner driver installation: it installed sucessfuly but the system didn't recognize the printer. Then, I passed the PPD file of printer in CUPS and so, the system recognized the printer. I forgotten of tell that the AIO is on the LAN

------------------------------------------------------
eriefisher wrote:Confirm you have the needed packages installed.
Code: Select all
apt install hplip libsane-hpaio sane libsane

Yes, they are all installed
Code: Select all
# apt install hplip libsane-hpaio sane libsane
Lettura elenco dei pacchetti... Fatto
Generazione albero delle dipendenze       
Lettura informazioni sullo stato... Fatto
hplip è già alla versione più recente (3.20.5+dfsg0-2).
libsane-hpaio è già alla versione più recente (3.20.5+dfsg0-2).
libsane è già alla versione più recente (1.0.27-3.2+b1).
sane è già alla versione più recente (1.0.14-15).
0 aggiornati, 0 installati, 0 da rimuovere e 0 non aggiornati.


------------------------------------------------------
eriefisher wrote:
Code: Select all
scanimage -L


Code: Select all
$ scanimage -L

No scanners were identified. If you were expecting something different,
check that the scanner is plugged in, turned on and detected by the
sane-find-scanner tool (if appropriate). Please read the documentation
which came with this software (README, FAQ, manpages).


The result is the same if i runned the command as root user

------------------------------------------------------
eriefisher wrote:If nothing appears
Code: Select all
sane-find-scanner

Code: Select all
$ sane-find-scanner

  # sane-find-scanner will now attempt to detect your scanner. If the
  # result is different from what you expected, first make sure your
  # scanner is powered up and properly connected to your computer.

  # No SCSI scanners found. If you expected something different, make sure that
  # you have loaded a kernel SCSI driver for your SCSI adapter.

could not open USB device 0x045e/0x0797 at 003:003: Access denied (insufficient permissions)
could not open USB device 0x8087/0x0024 at 003:002: Access denied (insufficient permissions)
could not open USB device 0x1d6b/0x0002 at 003:001: Access denied (insufficient permissions)
could not open USB device 0x0781/0x5590 at 004:002: Access denied (insufficient permissions)
could not open USB device 0x1d6b/0x0003 at 004:001: Access denied (insufficient permissions)
could not open USB device 0x1d6b/0x0002 at 002:001: Access denied (insufficient permissions)
could not open USB device 0x0489/0xe03c at 001:007: Access denied (insufficient permissions)
could not open USB device 0x064e/0xd20c at 001:003: Access denied (insufficient permissions)
could not open USB device 0x8087/0x0024 at 001:002: Access denied (insufficient permissions)
could not open USB device 0x1d6b/0x0002 at 001:001: Access denied (insufficient permissions)
  # No USB scanners found. If you expected something different, make sure that
  # you have loaded a kernel driver for your USB host controller and have setup
  # the USB system correctly. See man sane-usb for details.

  # Not checking for parallel port scanners.

  # Most Scanners connected to the parallel port or other proprietary ports
  # can't be detected by this program.

  # You may want to run this program as root to find all devices. Once you
  # found the scanner devices, be sure to adjust access permissions as
  # necessary


I've runned this command also root user
Code: Select all
# sane-find-scanner

  # sane-find-scanner will now attempt to detect your scanner. If the
  # result is different from what you expected, first make sure your
  # scanner is powered up and properly connected to your computer.

  # No SCSI scanners found. If you expected something different, make sure that
  # you have loaded a kernel SCSI driver for your SCSI adapter.

  # No USB scanners found. If you expected something different, make sure that
  # you have loaded a kernel driver for your USB host controller and have setup
  # the USB system correctly. See man sane-usb for details.

  # Not checking for parallel port scanners.

  # Most Scanners connected to the parallel port or other proprietary ports
capcla
 
Posts: 30
Joined: 2015-06-24 15:36

Re: Scanner's HP Laser MFP 137fnw

Postby eriefisher » 2020-05-21 16:51

I am now having trouble with my scanner as well. There was a recent update in sid. The printer was still working but I removed it and tried to reinstall but it fails. The printer will work but it runs "driverless" but no scanner.

This is the 3rd or 4th report I've seen as well as myself so I think something is broken in the hplip packages. nfortunately I have not had a lot of time to look into it and I don't use my printer scanner that much. If I locate a solution I will report back.
____________________________________________
There's a manual?
Siduction
Debian Sid
Xfce4 4.14
User avatar
eriefisher
 
Posts: 130
Joined: 2008-06-04 03:49
Location: Ontario's South Coast

Re: Scanner's HP Laser MFP 137fnw

Postby LE_746F6D617A7A69 » 2020-05-21 17:10

@ capcla

First, Your scanner is not directly supported by SANE project:
http://sane-project.org/sane-mfgs.html#Z-HEWLETT-PACKARD

But the drivers from HP are installing backend driver for SANE, and the installer is supposed to configure SANE to use that backend.

Apparently the installer script have silently failed: You need to check the SANE configuration.

EDIT:
In previous version of this post I've asked about the terminal output from the installer script - I haven't noticed that it's included in the first post .... in Italian ;)
/EDID

Regards.
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 389
Joined: 2020-05-03 14:16

Re: Scanner's HP Laser MFP 137fnw

Postby capcla » 2020-05-21 18:34

LE_746F6D617A7A69 wrote:@ capcla
Apparently the installer script have silently failed: You need to check the SANE configuration.


How?
capcla
 
Posts: 30
Joined: 2015-06-24 15:36

Re: Scanner's HP Laser MFP 137fnw

Postby LE_746F6D617A7A69 » 2020-05-21 21:40

capcla wrote:
LE_746F6D617A7A69 wrote:@ capcla
Apparently the installer script have silently failed: You need to check the SANE configuration.


How?


manpage: sane-dll(5)

Configuration file: /etc/sane.d/dll.conf

The backend name is "smfp", so the cfg file should have something like "hpsmfp" or just "smfp".
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 389
Joined: 2020-05-03 14:16

Re: Scanner's HP Laser MFP 137fnw

Postby capcla » 2020-05-21 23:44

In the last row is present the string smfp
Code: Select all
$ cat /etc/sane.d/dll.conf
# dll.conf - Configuration file for the SANE dynamic backend loader
#
# Backends can also be enabled by configuration snippets under the dll.d/
# directory -- third party backends can drop their configuration file in
# this in this directory, named after the backend.
#
# The next line enables the network backend; comment it out if you don't
# need to use a remote SANE scanner over the network -- see sane-net(5)
# and saned(8) for details.
net
abaton
agfafocus
apple
avision
artec
artec_eplus48u
as6e
bh
canon
canon630u
canon_dr
#canon_pp
cardscan
coolscan
#coolscan2
coolscan3
#dc25
#dc210
#dc240
dell1600n_net
dmc
epjitsu
#epson
epson2
epsonds
fujitsu
#gphoto2
genesys
gt68xx
hp
hp3900
hpsj5s
hp3500
hp4200
hp5400
hp5590
hpljm1005
hs2p
ibm
kodak
kodakaio
kvs1025
kvs20xx
leo
lexmark
ma1509
magicolor
matsushita
microtek
microtek2
mustek
#mustek_pp
mustek_usb
mustek_usb2
nec
niash
#p5
pie
pint
pixma
plustek
#plustek_pp
#pnm
qcam
ricoh
rts8891
s9036
sceptre
sharp
sm3600
sm3840
snapscan
sp15c
#st400
#stv680
tamarack
teco1
teco2
teco3
#test
u12
umax
#umax_pp
umax1220u
v4l
xerox_mfp
smfp
capcla
 
Posts: 30
Joined: 2015-06-24 15:36

Re: Scanner's HP Laser MFP 137fnw

Postby LE_746F6D617A7A69 » 2020-05-22 09:57

So it seems that the configuration is ok.
Let's check whether SANE is able to use smfp backend:
Code: Select all
SANE_DEBUG_DLL=5 scanimage -L 2>&1 | grep smfp

NOTE: In debug mode the scanimage is printing messages to stderr, it's necessary to redirect it to stdout.

You should see a result similar to this (example for canon630u backend)
Code: Select all
[dll] add_backend: adding backend `canon630u'
[dll] load: searching backend `canon630u' in `/usr/lib/x86_64-linux-gnu/sane:/usr/lib/sane'
[dll] load: trying to load `/usr/lib/x86_64-linux-gnu/sane/libsane-canon630u.so.1'
[dll] load: dlopen()ing `/usr/lib/x86_64-linux-gnu/sane/libsane-canon630u.so.1'
[dll] init: initializing backend `canon630u'
[dll] init: backend `canon630u' is version 1.0.1
[dll] sane_exit: calling backend `canon630u's exit function
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 389
Joined: 2020-05-03 14:16

Re: Scanner's HP Laser MFP 137fnw

Postby capcla » 2020-05-22 16:04

LE_746F6D617A7A69 wrote:So it seems that the configuration is ok.
Let's check whether SANE is able to use smfp backend:
Code: Select all
SANE_DEBUG_DLL=5 scanimage -L 2>&1 | grep smfp

NOTE: In debug mode the scanimage is printing messages to stderr, it's necessary to redirect it to stdout.


Code: Select all
$ SANE_DEBUG_DLL=5 scanimage -L 2>&1 | grep smfp > scanner.txt
$ cat scanner.txt
[dll] add_backend: adding backend `smfp'
[dll] load: searching backend `smfp' in `/usr/lib/x86_64-linux-gnu/sane:/usr/lib/sane'
[dll] load: trying to load `/usr/lib/x86_64-linux-gnu/sane/libsane-smfp.so.1'
[dll] load: dlopen()ing `/usr/lib/x86_64-linux-gnu/sane/libsane-smfp.so.1'
capcla
 
Posts: 30
Joined: 2015-06-24 15:36

Re: Scanner's HP Laser MFP 137fnw

Postby LE_746F6D617A7A69 » 2020-05-22 17:50

Your result means that SANE failed to load the backend driver.

I've downloaded the drivers from HP in 2 versions: Linux/Debian and Linux/Linux, to compare the differences - there are none.

This is the reason why SANE is unable to load the backed:
smfp driver:
Code: Select all
readelf --dyn-syms libsane-smfp.so.1.0.1 | grep sane
   472: 000000000009c6c0   125 FUNC    GLOBAL DEFAULT   10 sane_smfp_cancel
   942: 000000000009c570   157 FUNC    GLOBAL DEFAULT   10 sane_smfp_get_select_fd
  1115: 000000000009c930     5 FUNC    GLOBAL DEFAULT   10 sane_smfp_get_option_desc
  1357: 000000000009c920     5 FUNC    GLOBAL DEFAULT   10 sane_smfp_control_option
  1814: 000000000009c880   151 FUNC    GLOBAL DEFAULT   10 sane_smfp_get_parameters
  2167: 000000000009c4e0     2 FUNC    GLOBAL DEFAULT   10 sane_smfp_exit
  2568: 000000000009c940     5 FUNC    GLOBAL DEFAULT   10 sane_smfp_close
  3051: 000000000009c610   163 FUNC    GLOBAL DEFAULT   10 sane_smfp_set_io_mode
  3060: 000000000009caa0   230 FUNC    GLOBAL DEFAULT   10 sane_smfp_init  <-------------------- THIS
  3232: 000000000009c800   125 FUNC    GLOBAL DEFAULT   10 sane_smfp_start
  3386: 000000000009ca00   155 FUNC    GLOBAL DEFAULT   10 sane_smfp_get_devices
  3879: 000000000009c950   166 FUNC    GLOBAL DEFAULT   10 sane_smfp_open
  3894: 000000000009c740   189 FUNC    GLOBAL DEFAULT   10 sane_smfp_read
  4160: 000000000009c4f0   121 FUNC    GLOBAL DEFAULT   10 sane_samsung_strstatus

coolscan driver:
Code: Select all
readelf --dyn-syms 'libsane-coolscan.so.1.0.25' | grep init
    78: 0000000000000000     0 FUNC    GLOBAL DEFAULT  UND libusb_init
   108: 0000000000003f20     5 FUNC    GLOBAL DEFAULT   11 sane_init <-------------------- THIS
   112: 0000000000006c40   189 FUNC    GLOBAL DEFAULT   11 sanei_usb_init
   116: 0000000000004200   266 FUNC    GLOBAL DEFAULT   11 sanei_init_debug
   118: 0000000000010730   294 FUNC    GLOBAL DEFAULT   11 sane_coolscan_init
   136: 0000000000005ae0    61 FUNC    GLOBAL DEFAULT   11 sanei_thread_init
   145: 0000000000003980     0 FUNC    GLOBAL DEFAULT    8 _init

Additionaly I've checked the scanimage.c at GitLab - SANE backends should have sane_init function implemented, not sane_smfp_init - that's why this backend can't be used.

I have no idea why HP is distributing those drivers (EDIT) - but they can't be used with SANE.

Theoretically, one can compile modified SANE version which will call the *smfp* functions and check if it will work - but I'm guessing it's not an option for You.

You may try to contact HP support and ask them how their drivers are supposed to be used on Linux/Debian ... who knows? - maybe they know some other method.

Regards

EDIT:
Actually I have some suspictions:
The 'libsane-smfp.so.1.0.1' has all the functions needed by SANE plugin/backend driver - the only problem is that they're prefixed with: sane_smfp_ instead of just sane_
This simple fact allows to assume, that HP is internally using custom-build SANE executable, and the process of building world-wide Linux driver has been broken, because the QA inside the HP corporation is not functioning at all...

This is what I suppose to have happened:
1. HP is internally using a custom version of SANE (collaborating with samsung - i.e. HP uses Samsung scanner controller chips)
2. HP have hired some student to port their internal version of SANE backend driver to a world-wide downloadable version.
3. That student was not capable of understanding of what he/she is doing, didn't read the SANE backend plugin specification and because of this (or because he/she was lazy) the HP drivers have wrong prefixes for SANE interface.
4. That student was also incompetent in terms of writing DSOs (dynamic shared objects, known as libraries) - because the SMFP backend driver library exposes internal functions written in C++ (btw - all other SANE drivers are much smaller, exactly because they're written in C)
5. Nobody within the HP corporation have tested their "official" drivers for Linux-based systems. (Quality Assurance is not working)

Regards
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 389
Joined: 2020-05-03 14:16

Re: Scanner's HP Laser MFP 137fnw

Postby capcla » 2020-05-29 15:56

LE_746F6D617A7A69 wrote:You may try to contact HP support and ask them how their drivers are supposed to be used on Linux/Debian ... who knows? - maybe they know some other method.


I just wrote this post: https://h30434.www3.hp.com/t5/Printer-Software-and-Drivers/HP-Laser-MFP-137-fnw-and-Linux/m-p/7610499#M186471
For now, I haven't received response.

LE_746F6D617A7A69 wrote:This is what I suppose to have happened:...


Well, there is nothing I can do?
capcla
 
Posts: 30
Joined: 2015-06-24 15:36

Re: Scanner's HP Laser MFP 137fnw

Postby LE_746F6D617A7A69 » 2020-05-29 16:52

Technically there are 3 options:
1. Compile modified SANE version which will call the SMFP driver functions with non-standard prefixes (as I've mentioned earlier)
2. Reverse engineering of the SMFP driver -> convert it to a valid SANE backend format.
3. Write a "fake" SMFP driver which will expose correct functions for SANE interface, and which will redirect the calls to "true" SMFP driver.

The 1st and 3rd options are relatively easy - if You're a programmer. The 2nd option is much harder, but possible.

Regards.

EDIT: added 3rd option /EDIT

EDIT2:
In fact, the 3rd option is trivial to implement - if You whish, I can write such a "fake" SMFP driver, but:

READ THIS CAREFULLY:
I don't have the hardware to test - all I can do is to check whether SANE will be able to load the driver or not.
There's a <small> risk that misusing the SMFP driver willl cause damage to your equipment.


What's Your decision?
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 389
Joined: 2020-05-03 14:16

Re: Scanner's HP Laser MFP 137fnw

Postby brian_p » 2020-06-07 09:44

The package that capcia downloaded was ULDLINUX. ULD is Unified
Linux Driver, a Samsung product. The 137fnw does not use HPLIP for any
of its functions. Please see

https://wiki.debian.org/CUPSPrintQueues#hpuld

The issue with scanning is probably

https://wiki.debian.org/Scanner#issue

libsane-smfp.so.1.0.1 is put into /usr/lib64/sane . This is not a multiarch
directory, so it is not searched by Debian.

A full discussion of a device similar to capcia's is at

https://forums.linuxmint.com/viewtopic.php?f=51&t=314966

Having the 137fnw on the network is great - it means that sane-airscan
can be used:

https://github.com/alexpevzner/sane-airscan/blob/master/README.md

I strongly recommend the installation of sane-airscan, not least because
it is a free driver and has operated reliably for 100% of users who have put
it on their systems. It is also well-supported by its author.

Should capcia, or anyone else with a modern device, install sane-airscan, a
report giving the output from
Code: Select all
scanimage -L
would be very useful. I would also be interested in the outputs of
Code: Select all
avahi-browse -rt _ipp._tcp
and
Code: Select all
avahi-browse -rt _uscan._tcp
for my records. avahi-browse is in the avahi-utils package.
--
Brian.
brian_p
 
Posts: 99
Joined: 2015-11-05 10:32

Re: Scanner's HP Laser MFP 137fnw

Postby LE_746F6D617A7A69 » 2020-06-07 19:01

brian_p wrote:The issue with scanning is probably

https://wiki.debian.org/Scanner#issue

libsane-smfp.so.1.0.1 is put into /usr/lib64/sane . This is not a multiarch
directory, so it is not searched by Debian.


Nope, it is searched by the SANE -> see the above posts -> the libsane-smfp.so.1.0.1 is correctly installed, and SANE can find the library, but it can't load/initialize it ->because the required plugin interface functions are missing.

Nevertheless, your post is very informative - definitely the "driverless" solution might work in this case.

Regards
Bill Gates: "(...) In my case, I went to the garbage cans at the Computer Science Center and I fished out listings of their operating system."
The_full_story and Nothing_have_changed
LE_746F6D617A7A69
 
Posts: 389
Joined: 2020-05-03 14:16

Next

Return to System configuration

Who is online

Users browsing this forum: No registered users and 17 guests

fashionable