# [Solved] Problems with scanner and sane

## Luc484

Hi. I tried to ask everywhere for this error but I didn't find many help, so I try here, maybe someone had this problem before. I'm trying to use my HP PSC1310 with sane using the driver hplip. I followed the guide on the wiki pages. All ok, the scanner is recognized too:

```

cluca luca # sane-find-scanner -q

found USB scanner (vendor=0x03f0 [hp], product=0x3f11 [psc 1310 series ]) at libusb:002:003

```

the problem is at the end, trying to scan:

```

cluca luca # scanimage -L

[sanei_debug] Setting debug level of hp to 0.

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).

cluca luca # scanimage -L

[sanei_debug] Setting debug level of hp to 0.

scanimage: hp-option.c:3710: hp_optset_fix_geometry_options: Assertion `tl_x && tl_y && br_x && br_y' failed.

Aborted

```

Giving the same command I receive sometime one output and sometime the other one. Does someone have this problem too?

Thanks.Last edited by Luc484 on Sun Aug 28, 2005 4:45 pm; edited 1 time in total

----------

## shobu

I had something similar some time ago with my epson scanner: sane-find-scanner found it, but when I tried scanimage -L, it said no scanner was found. I  didn't try the debug mode, so I don't know if it is the same problem, but you can give it a try.

Place in the /etc/sane.d/hp.conf file the hexcodes of your scanner-model, so add the line:

usb 0x03f0 0x3f11

----------

## Luc484

Unfortunately I already did it. Nothing.

Thanks anyway.

----------

## kyron

 *Luc484 wrote:*   

> Hi. I tried to ask everywhere for this error but I didn't find many help, so I try here, maybe someone had this problem before. I'm trying to use my HP PSC1310 with sane using the driver hplip. I followed the guide on the wiki pages. All ok, the scanner is recognized too:
> 
> ...snip...
> 
> Giving the same command I receive sometime one output and sometime the other one. Does someone have this problem too?
> ...

 

I did, it turns out all I had to do is "reboot" the scanner. In my case, I switched from hpoj to hplip... unplug and re-plug your scanner and try hp-toolbox, you should get some resulst.

----------

## Luc484

 *kyron wrote:*   

>  *Luc484 wrote:*   Hi. I tried to ask everywhere for this error but I didn't find many help, so I try here, maybe someone had this problem before. I'm trying to use my HP PSC1310 with sane using the driver hplip. I followed the guide on the wiki pages. All ok, the scanner is recognized too:
> 
> ...snip...
> 
> Giving the same command I receive sometime one output and sometime the other one. Does someone have this problem too?
> ...

 

What do you mean by "reboot" the scanner? I already tried to unplug and re-plug the scanner, nothing changes. I'm trying with the hp-toolbox but, once opened, a message appears, and tells me no hp device has been found. It tells me that if I want to use it I should add a device first, using for example the CUPS web interface. I did it, even if a printer was already set up in the kde control center, but nothing changed, hp-toolbox keeps showing the same message. Did this happen to you?

Thanks for your help.

----------

## kyron

 *Luc484 wrote:*   

> 
> 
> ...snip
> 
> What do you mean by "reboot" the scanner? I already tried to unplug and re-plug the scanner, nothing changes. ...snip...

 

I meant, unplug and re-plug the power to your scanner. Each time I got this was when I changed HP drivers (ie: going from hpoj to hplip...). Note that if you don't go through the proper sequence of stopping the old hpoj, cupsd and starting the new services, you might need to reboot your PC for everything to fall back in place (much quicker than scavenging for processes that might still be running).

Maybe this wiki page I am writing up might be of some help... but make sure you read the hplip readme (/usr/share/doc/hplip-0.9.4/hplip_readme.html)! It's full of information you won't find by searching the net and forums (I made that mistake).

----------

## Luc484

Your wiki page is great man. 5 minutes and the scanning test is ok. I only have another problem  :Smile: . I can't scan the image. I mean that the test is ok, but if I try to scan the image for real, or I try to use xsane, it simply did nothing. The scanner is stuck, and xsane is closed. Nothing. Then, I have to restart coldplug and hplip to retry the test successfully. More or less the same happens as user.

Thanks anyway, I made some new steps, thanks for that great guide.

----------

## kyron

 *Luc484 wrote:*   

> Your wiki page is great man. ...

 

It's a mess in progess at the moment. Your problem is quite weird... you might have some issues with sane. Try re-emerging the following packages (take note of my use flags)

```
[ebuild   R   ] media-gfx/xsane-0.97  +gtk2 +jpeg +nls +png +tiff 3,124 kB

[ebuild   R   ] media-gfx/sane-frontends-1.0.13  +gimp 205 kB

[ebuild   R   ] media-gfx/sane-backends-1.0.15  -gphoto2 -ipv6 +usb 0 kB

[ebuild   R   ] net-print/hplip-0.9.4  +X +cups +foomaticdb +ppds +qt +scanner -snmp +usb 0 kB
```

And my CFLAGS are:

```
CFLAGS="-march=pentium4 -O2 -pipe -fomit-frame-pointer"
```

----------

## Luc484

Ok. I reemerged everything, checking the flags. I added something, and removed something else. Now, I have always the test working correctly, and the command:

```
xsane SANE_URI
```

from both user and root giving the same error as before:

```

scanimage: hp-option.c:3710: hp_optset_fix_geometry_options: Assertion `tl_x && tl_y && br_x && br_y' failed.

Aborted 

```

Is there anything else I could try?

Thanks a lot for your help.

----------

## kyron

 *Luc484 wrote:*   

> Ok. I reemerged everything, checking the flags. I added something, and removed something else. Now, I have always the test working correctly, and the command:
> 
> ```
> xsane SANE_URI
> ```
> ...

 

Well...how did you set the SANE_URI variable... and it would _have_ to be called with $SANE_URI (depending on your shell...but I take for granted it's BASH).

Try the command I put on my wiki instead. 

```
xsane `hp-makeuri -s -lnone /dev/usb/lp0 |sed -e"s/SANE URI: //"
```

And again, the only time I ever saw that error message is with the scanner needing a power cycle.

----------

## Luc484

I made another power reboot and now it seems to work very good  :Laughing:  I use the gimp to scan, and it works now without errors nor problems.

Thanks for your help and for your guide.

----------

## Luc484

After the powercyle it started to work but worked only for sometime. I solved the problem in another way suggested on the hplip forum. I gave this shell:

```
export SANE_DEBUG_DLL=128
```

this was my output:

```
cluca luca # scanimage -L

[sanei_debug] Setting debug level of dll to 128.

[dll] sane_init: SANE dll backend version 1.0.11 from sane-backends 1.0.15

[dll] sane_init: reading dll.conf

[dll] add_backend: adding backend `net'

[dll] add_backend: adding backend `abaton'

[dll] add_backend: adding backend `agfafocus'

[dll] add_backend: adding backend `apple'

[dll] add_backend: adding backend `avision'

[dll] add_backend: adding backend `artec'

[dll] add_backend: adding backend `artec_eplus48u'

[dll] add_backend: adding backend `as6e'

[dll] add_backend: adding backend `bh'

[dll] add_backend: adding backend `brother'

[dll] add_backend: adding backend `canon'

[dll] add_backend: adding backend `canon630u'

[dll] add_backend: adding backend `coolscan'

[dll] add_backend: adding backend `coolscan2'

[dll] add_backend: adding backend `dmc'

[dll] add_backend: adding backend `epson'

[dll] add_backend: adding backend `fujitsu'

[dll] add_backend: adding backend `gt68xx'

[dll] add_backend: adding backend `hp'

[dll] add_backend: adding backend `hpsj5s'

[dll] add_backend: adding backend `hp5400'

[dll] add_backend: adding backend `hpaio'

[dll] add_backend: adding backend `ibm'

[dll] add_backend: adding backend `leo'

[dll] add_backend: adding backend `ma1509'

[dll] add_backend: adding backend `matsushita'

[dll] add_backend: adding backend `microtek'

[dll] add_backend: adding backend `microtek2'

[dll] add_backend: adding backend `mustek'

[dll] add_backend: adding backend `mustek_usb'

[dll] add_backend: adding backend `nec'

[dll] add_backend: adding backend `niash'

[dll] add_backend: adding backend `pie'

[dll] add_backend: adding backend `pint'

[dll] add_backend: adding backend `plustek'

[dll] add_backend: adding backend `qcam'

[dll] add_backend: adding backend `ricoh'

[dll] add_backend: adding backend `s9036'

[dll] add_backend: adding backend `sceptre'

[dll] add_backend: adding backend `sharp'

[dll] add_backend: adding backend `sm3600'

[dll] add_backend: adding backend `snapscan'

[dll] add_backend: adding backend `sp15c'

[dll] add_backend: adding backend `tamarack'

[dll] add_backend: adding backend `teco1'

[dll] add_backend: adding backend `teco2'

[dll] add_backend: adding backend `teco3'

[dll] add_backend: adding backend `u12'

[dll] add_backend: adding backend `umax'

[dll] add_backend: adding backend `umax1220u'

[dll] add_backend: adding backend `v4l'

[dll] sane_get_devices

[dll] load: searching backend `v4l' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-v4l.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-v4l.so.1'

[dll] init: initializing backend `v4l'

[dll] init: backend `v4l' is version 1.0.4

[dll] load: searching backend `umax1220u' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-umax1220u.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-umax1220u.so.1'

[dll] init: initializing backend `umax1220u'

[dll] init: backend `umax1220u' is version 1.0.1

[dll] load: searching backend `umax' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-umax.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-umax.so.1'

[dll] init: initializing backend `umax'

[dll] init: backend `umax' is version 1.0.44

[dll] load: searching backend `u12' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-u12.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-u12.so.1'

[dll] init: initializing backend `u12'

[dll] init: backend `u12' is version 1.0.0

[dll] load: searching backend `teco3' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-teco3.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-teco3.so.1'

[dll] init: initializing backend `teco3'

[dll] init: backend `teco3' is version 1.0.1

[dll] load: searching backend `teco2' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-teco2.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-teco2.so.1'

[dll] init: initializing backend `teco2'

[dll] init: backend `teco2' is version 1.0.7

[dll] load: searching backend `teco1' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-teco1.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-teco1.so.1'

[dll] init: initializing backend `teco1'

[dll] init: backend `teco1' is version 1.0.10

[dll] load: searching backend `tamarack' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-tamarack.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-tamarack.so.1'

[dll] init: initializing backend `tamarack'

[dll] init: backend `tamarack' is version 1.0.0

[dll] load: searching backend `sp15c' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-sp15c.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-sp15c.so.1'

[dll] init: initializing backend `sp15c'

[dll] init: backend `sp15c' is version 1.0.0

[dll] load: searching backend `snapscan' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-snapscan.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-snapscan.so.1'

[dll] init: initializing backend `snapscan'

[dll] init: backend `snapscan' is version 1.4.40

[dll] load: searching backend `sm3600' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-sm3600.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-sm3600.so.1'

[dll] init: initializing backend `sm3600'

[dll] init: backend `sm3600' is version 1.0.5

[dll] load: searching backend `sharp' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-sharp.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-sharp.so.1'

[dll] init: initializing backend `sharp'

[dll] init: backend `sharp' is version 1.0.0

[dll] load: searching backend `sceptre' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-sceptre.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-sceptre.so.1'

[dll] init: initializing backend `sceptre'

[dll] init: backend `sceptre' is version 1.0.10

[dll] load: searching backend `s9036' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-s9036.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-s9036.so.1'

[dll] init: initializing backend `s9036'

[dll] init: backend `s9036' is version 1.0.0

[dll] load: searching backend `ricoh' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-ricoh.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-ricoh.so.1'

[dll] init: initializing backend `ricoh'

[dll] init: backend `ricoh' is version 1.0.0

[dll] load: searching backend `qcam' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-qcam.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-qcam.so.1'

[dll] init: initializing backend `qcam'

[dll] init: backend `qcam' is version 1.0.0

[dll] load: searching backend `plustek' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-plustek.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-plustek.so.1'

[dll] init: initializing backend `plustek'

[dll] init: backend `plustek' is version 1.0.0

[dll] load: searching backend `pint' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-pint.so.1'

[dll] load: couldn't open `/usr/lib/sane/libsane-pint.so.1' (No such file or directory)

[dll] load: couldn't find backend `pint' (No such file or directory)

[dll] load: searching backend `pie' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-pie.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-pie.so.1'

[dll] init: initializing backend `pie'

[dll] init: backend `pie' is version 1.0.9

[dll] load: searching backend `niash' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-niash.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-niash.so.1'

[dll] init: initializing backend `niash'

[dll] init: backend `niash' is version 1.0.1

[dll] load: searching backend `nec' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-nec.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-nec.so.1'

[dll] init: initializing backend `nec'

[dll] init: backend `nec' is version 1.0.0

[dll] load: searching backend `mustek_usb' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-mustek_usb.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-mustek_usb.so.1'

[dll] init: initializing backend `mustek_usb'

[dll] init: backend `mustek_usb' is version 1.0.18

[dll] load: searching backend `mustek' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-mustek.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-mustek.so.1'

[dll] init: initializing backend `mustek'

[dll] init: backend `mustek' is version 1.0.137

[dll] load: searching backend `microtek2' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-microtek2.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-microtek2.so.1'

[dll] init: initializing backend `microtek2'

[dll] init: backend `microtek2' is version 1.0.0

[dll] load: searching backend `microtek' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-microtek.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-microtek.so.1'

[dll] init: initializing backend `microtek'

[dll] init: backend `microtek' is version 1.0.0

[dll] load: searching backend `matsushita' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-matsushita.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-matsushita.so.1'

[dll] init: initializing backend `matsushita'

[dll] init: backend `matsushita' is version 1.0.7

[dll] load: searching backend `ma1509' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-ma1509.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-ma1509.so.1'

[dll] init: initializing backend `ma1509'

[dll] init: backend `ma1509' is version 1.0.3

[dll] load: searching backend `leo' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-leo.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-leo.so.1'

[dll] init: initializing backend `leo'

[dll] init: backend `leo' is version 1.0.11

[dll] load: searching backend `ibm' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-ibm.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-ibm.so.1'

[dll] init: initializing backend `ibm'

[dll] init: backend `ibm' is version 1.0.0

[dll] load: searching backend `hpaio' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-hpaio.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-hpaio.so.1'

[dll] init: initializing backend `hpaio'

[dll] init: backend `hpaio' is version 1.0.6

[dll] load: searching backend `hp5400' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-hp5400.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-hp5400.so.1'

[dll] init: initializing backend `hp5400'

[dll] init: backend `hp5400' is version 1.0.3

[dll] load: searching backend `hpsj5s' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-hpsj5s.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-hpsj5s.so.1'

[dll] init: initializing backend `hpsj5s'

[dll] init: backend `hpsj5s' is version 1.0.3

[dll] load: searching backend `hp' in `/usr/lib/sane'

[dll] load: trying to load `/usr/lib/sane/libsane-hp.so.1'

[dll] load: dlopen()ing `/usr/lib/sane/libsane-hp.so.1'

[dll] init: initializing backend `hp'

[dll] init: backend `hp' is version 1.0.8

scanimage: hp-option.c:3710: hp_optset_fix_geometry_options: Assertion `tl_x && tl_y && br_x && br_y' failed.

Aborted
```

So, the error returned was not due to hpaio, which is the driver I needed but from hp. I solved commenting the corresponding line in /etc/sane.d/dll.conf.

----------

