Page 1 of 2 12 LastLast
Results 1 to 10 of 15

Thread: [SOLVED] XSane failed to open device intermittent MFC-240c brother

  1. #1
    Join Date
    Mar 2006
    Location
    Rumplestiltskin, Cal.
    Beans
    Hidden!
    Distro
    Ubuntu 16.04 Xenial Xerus

    [SOLVED] XSane failed to open device intermittent MFC-240c brother

    My Brother MFC-240c printer/scanner/copier/fax has worked with XSane/Gimp until today without intermittent problems.

    I'm not fiddling with USB devices during the scan process.

    mark@Lexington-19:~$ lsusb

    Bus 003 Device 002: ID 04f9:01ab Brother Industries, Ltd

    The printer works, so what gives?

    Full XSane error message attached as screenshot.
    Attached Images Attached Images
    AMD FX-6300, 8gig ddr3, MSI 970 Gaming, 256G WD blue SSD, GeForce GT710, HP LJ Pro M277-fdw

  2. #2
    Join Date
    May 2005
    Beans
    46

    Arrow Re: [SOLVED] XSane failed to open device intermittent MFC-240c brother

    Changing the permissions as in the linked post will help.
    First of all you should find out which bus your usb scanner resides on, this is easily done with the lsusb command.


    user@somelinuxbox:~$ lsusb
    Bus 003 Device 002: ID 046d:c016 Logitech, Inc. M-UV69a Optical Wheel Mouse
    Bus 003 Device 001: ID 0000:0000
    Bus 002 Device 002: ID 05d8:4002 Ultima Electronics Corp. Artec Ultima 2000 (GT6801 based)/Lifetec LT9385 Scanner
    Bus 002 Device 001: ID 0000:0000
    Bus 004 Device 001: ID 0000:0000
    Bus 005 Device 002: ID 0a12:0001 Cambridge Silicon Radio, Ltd Bluetooth Dongle (HCI mode)
    Bus 005 Device 001: ID 0000:0000
    Bus 001 Device 001: ID 0000:0000


    as you can see the scanner resides on Bus 002 as the second (002) device in my case. The syntax for changing permissions of the scanner device is


    user@somelinuxbox:~$ sudo chmod a+w /dev/bus/usb/$BUS/$DEVICE


    remember to change the $BUS and $DEVICE variables according to the lsusb output as described above. to change permissions to my scanner device i would enter:


    user@somelinuxbox:~$ sudo chmod a+w /dev/bus/usb/002/002

  3. #3
    Join Date
    Oct 2008
    Beans
    37

    Re: [SOLVED] XSane failed to open device intermittent MFC-240c brother

    awesome solution. thanks

  4. #4
    Join Date
    Oct 2009
    Location
    Montrose, CO
    Beans
    3

    Re: [SOLVED] XSane failed to open device intermittent MFC-240c brother

    Worked for me as well! Thanks!!!

  5. #5
    Join Date
    Jun 2010
    Beans
    1

    Talking Re: [SOLVED] XSane failed to open device intermittent MFC-240c brother

    U rock.....

    Just 1 chmod command that made all the difference in the world.

    Thanks.

  6. #6
    Join Date
    Aug 2010
    Location
    Goteborg, Sweden
    Beans
    24
    Distro
    Ubuntu 13.10 Saucy Salamander

    Re: [SOLVED] XSane failed to open device intermittent MFC-240c brother

    Quote Originally Posted by aouie View Post
    ... to change permissions to my scanner device i would enter:

    user@somelinuxbox:~$ sudo chmod a+w /dev/bus/usb/002/002
    Your post solved the problem for mee too. Thanks, "aouie"!

    However, one thing makes me fear that the solution is a workaround. In my case, while the scanner at this moment is represented by device 004 in bus 006:

    Code:
    $ lsusb | grep Brother
    Bus 006 Device 004: ID 04f9:01ab Brother Industries, Ltd MFC-240C
    ... XSane keeps displaying bus 003 and device 001:



    That was true before I had fiddled with some USB connected devices. So even if it 'works', it would be even better if somebody could tell how to get rid of this inconsistency.

  7. #7
    Join Date
    Feb 2009
    Beans
    8
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: [SOLVED] XSane failed to open device intermittent MFC-240c brother

    Aouie, Thanks. your post solved the problem for me too. With great respect I add, sometimes y and w.

  8. #8
    Join Date
    Aug 2010
    Location
    Malaysia
    Beans
    6
    Distro
    Ubuntu 10.04 Lucid Lynx

    Lightbulb Re: [SOLVED with bash script] XSane failed to open MFC-240C scanner

    I dunno how i got into this problem (perhaps upgrading ubuntu to Lucid release ) Anyway, thanks for sharing the quick solution on 1st post. I've improved it with a bash script and attach it to the udev script. So that, i have no need to apply the chmod all the time when i wanna to use the MFC-240C USB scanner.

    The followings are the simple steps i have applied to my Ubuntu Lucid server environment:

    (1) Download brscan.sh to /opt

    (2) chmod 755 /opt/brscan.sh

    (3) nano /etc/udev/rules.d/45-libsane.rules (Create it if not existed)

    (4) Add the following lines:
    Code:
    # Brother MFC-240C
    ATTR{idVendor}=="04f9", ATTR{idProduct}=="01ab", RUN+="/opt/brscan.sh"
    Please change the 01ab (Product ID - might be different from mine) to the one you owned. You can find it with lsusb.

    (5) nano /lib/udev/rules.d/40-libsane.rules (Shall be existed)
    (6) Add the following lines at the end, just before the "# The following rule will disable USB autosuspend for the device":
    Code:
    # Brother Scanners
    ATTRS{idVendor}=="04f9", ATTRS{idProduct}=="01ab", ENV{libsane_matched}="yes"
    Again, please change the 01ab (Product ID - might be different from mine) to the one you owned. You can find it with lsusb.

    Hopefully will safe you some time to solve this problem
    Attached Files Attached Files
    Last edited by cainwong; September 28th, 2010 at 06:28 AM.

  9. #9
    Join Date
    Aug 2010
    Location
    Goteborg, Sweden
    Beans
    24
    Distro
    Ubuntu 13.10 Saucy Salamander

    Re: [SOLVED with bash script] XSane failed to open MFC-240C scanner

    Quote Originally Posted by cainwong View Post
    ... thanks for sharing the quick solution on 1st post. I've improved it with a bash script and attach it to the udev script. So that, i have no need to apply the chmod all the time when i wanna to use the MFC-240C USB scanner.
    When fixing the permissions issue, I made "lp" the group, and added write access to the group:
    Code:
    ~$ ls -l /dev/bus/usb/006
    total 0
    crw-rw-r--  1 root root 189, 640 2010-10-11 23:09 001
    crw-rw-r--  1 root root 189, 641 2010-10-11 23:09 002
    crw-rw-r--+ 1 root lp   189, 642 2010-10-12 00:14 003
    Scanning has worked fine since; no need to chmod again.

  10. #10
    Join Date
    Jan 2011
    Beans
    25

    Re: [SOLVED] XSane failed to open device intermittent MFC-240c brother

    Thanks Man this worked great!
    Dfi lanparty nf4slid,2 gig corsairxms, opteron 180, seagate 250,2x bfg 7600gt in sli

Page 1 of 2 12 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •