HP 2400c not recognized by xsane

5 respuestas [Último envío]
Cyberhawk

I am a translator!

Desconectado/a
se unió: 07/27/2010

Hello everyone,

I've installed Trisquel today because I wanted to try and see if I can survive
on free software alone. Since flash is somewhat working already and my
graphicscard got working open source drivers, I believe chances are good I
won't be really in need of non-free software anymore.

My problem is, the scanner (the HP 2400c) doesn't want to work. I know for a
fact, that the genesys backend supports it, because it did so when I had
Fedora 12. So I downloaded it, compiled and installed it, but xsane refuses to
see the scanner. It only sees my webcam as a possible choice. When I start
xsane as root, it does however see the scanner, but scanning itself fails
(error message: invalid argument).

The output of lsusb gives me this:


Bus 002 Device 004: ID 093a:2463 Pixart Imaging, Inc.
Bus 002 Device 003: ID 03f0:0a01 Hewlett-Packard ScanJet 2400c
Bus 002 Device 002: ID 045e:0039 Microsoft Corp. IntelliMouse Optical
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

What do I have to do to set the permissions right and make the scanner usable
again? As I said, in Fedora 12 it worked (for b/w scanning at least, which is
all I need anyway).

ivaylo
Desconectado/a
se unió: 07/26/2010

On 27.07.2010 20:15, name at domain wrote:
> Hello everyone,
>
Hello!

> My problem is, the scanner (the HP 2400c) doesn't want to work. I know
> for a
> fact, that the genesys backend supports it [...]

I have a 2300c, so this might not be relevant. It is supported by the
same backend. I have read once that 2300c and 2400c are similar.

> So I downloaded it, compiled and installed it, but xsane refuses to
> see the scanner.

Why are you compiling it from source? I have these packages installed:

$ aptitude search sane |grep ^i
i A libsane - API library for scanners
i sane-utils - API library for scanners -- utilities
i xsane - featureful graphical frontend for
SANE (Sc
i A xsane-common - featureful graphical frontend for
SANE (Sc

Mine works, but I am using the development version (Taranis) of Trisquel.
In the configuration file of the backend in my system, your model is
listed.

Any chance this backend has binary-blobs and is properly cleaned in the
stable version? Anyone?
Can you see any messages about the scanner in dmesg output?

> When I start xsane as root, it does however see the scanner, but
> scanning itself fails
> (error message: invalid argument).
Since you compiled sane from source, there might be some compatibility
issues with other libraries.

> What do I have to do to set the permissions right and make the scanner
> usable
> again?
I am in the default groups made by the installation.

So, my advice is to remove the compiled version, install the packages
and try again.

Cyberhawk

I am a translator!

Desconectado/a
se unió: 07/27/2010

I did not compile sane from source completely, just the genesys backend found here: http://alioth.debian.org/frs/?group_id=30186 From using Fedora I was used to the fact that it was exactly genesys what brought my scanner to work and since an aptitude search genesys gave me no results, I compiled it. Sane also did not recognize my scanner right out of the box, so I didn't think it was possible, that it supports it without genesys. Atm it actually works, not sure why. I tried compiling also the frontend of sane, which gave me the error "no gtk found, no user interface will be available" but after installing that, everything works, but only as root. I wouldn't have compiled so much if it would have worked right away, but I'll try removing and installing everything from repositories and see if it will work.

Cyberhawk

I am a translator!

Desconectado/a
se unió: 07/27/2010

Argh, now I don't know how to delete my compiled stuff. And when I try aptitude reinstall for every sane related package I have, it turns out aptitude wants to remove 3 other packages that seem completely unrelated, libmikmod2{u} libsdl-mixer1.2{u} libsmpeg0{u}.

I may have messed up a little bit, but there has to be a way to change the permissions for the scanner, becasue if I start xsane as root it actually works and I can scan. Scanimage -L cannot find a thing, however sudo scanimage -L does. It all seems to be a permission thing.

ivaylo
Desconectado/a
se unió: 07/26/2010

On 28.07.2010 12:47, name at domain wrote:
> Argh, now I don't know how to delete my compiled stuff.
On 27.07.2010 23:30, name at domain wrote:
> I did not compile sane from source completely, just the genesys
> backend found here: http://alioth.debian.org/frs/?group_id=30186

If you used "make install", the way to remove it is to type "(sudo) make
uninstall" in the source directory.

> And when I try aptitude reinstall for every sane related package I
> have, it turns out aptitude wants to remove 3 other packages that seem
> completely unrelated, libmikmod2{u} libsdl-mixer1.2{u} libsmpeg0{u}.

The "u" means they are going to be upgraded. They might have newer
versions and this is just a coincidence. If aptitude is inconvenient for
you, you can use the graphical package manager synaptic.

On 27.07.2010 23:30, name at domain wrote:
> From using Fedora I was used to the fact that it was exactly genesys
> what brought my scanner to work and since an aptitude search genesys
> gave me no results,

The package libsane should bring genesys support:

$ dpkg -L libsane |grep genesys
/usr/share/man/man5/sane-genesys.5.gz
/usr/lib/sane/libsane-genesys.so.1.0.20
/usr/lib/sane/libsane-genesys.la
/etc/sane.d/genesys.conf
/usr/lib/sane/libsane-genesys.so.1

> I may have messed up a little bit, but there has to be a way to change
> the permissions for the scanner, becasue if I start xsane as root it
> actually works and I can scan. Scanimage -L cannot find a thing,
> however sudo scanimage -L does. It all seems to be a permission thing.

I just read "/usr/share/doc/libsane/README.Debian.gz" provided by the
libsane package. It is said that for USB scanners the permissions are
managed by udev. It is also said that rules should be placed in
"/lib/udev/rules.d/60-libsane.rules", but in my system it is
"/lib/udev/rules.d/40-libsane.rules". Your model is missing in the udev
rules file, so this might be the solution. This is the rule for model 2300c:
# Hewlett-Packard ScanJet 2300C
ATTRS{idVendor}=="03f0", ATTRS{idProduct}=="0901",
ENV{libsane_matched}="yes"

Adding the following lines in the rules file, could make it work with
regular user:
# Hewlett-Packard ScanJet 2400C
ATTRS{idVendor}=="03f0", ATTRS{idProduct}=="0a01",
ENV{libsane_matched}="yes"

I don't know is it OK to mess around with this file. When libsane is
upgraded to a newer version, you might experience problems if you edit it.

Cyberhawk

I am a translator!

Desconectado/a
se unió: 07/27/2010

Ah, finally! It wasn't possible to do things the right way and uninstall my compiled package, because the folder from where I did the install is deleted now. On the bright side, now I know better.I edited the .rules file (backed up the original of course) and now everything works, I can start xsane and it finds my scanner without root rights.Thank you for the help ivaylo!