Re: Backend: When to use reader process?

From: Oliver Rauch (oliver.rauch@rauch-domain.de)
Date: Wed Feb 28 2001 - 08:51:59 PST

  • Next message: Henning Meier-Geinitz: "Re: preview and selectable scanarea for MFS-12000's ADF"

    Frederik Ramm wrote:
    >
    > Hi,
    >
    > I've noticed that the driver I am basing my M3091 work on, the
    > M3096 driver which was in turn derived from the Coolscan driver, uses
    > a separate process for reading data from the scanner, which is then
    > fed via a pipe file descriptor to sane_read.
    >
    > Other drivers (like the Bell+Howell backend I've been looking at for
    > duplex inspiration) don't use a separate process.
    >
    > Which would be the preferred way to implement it for a max. 15ppm ADF
    > scanner?

    Hi Frederik,

    the reader_process is a good and simple way to make sane_read
    independant from the scsi read commands.

    When you do some tests you will notice that scanning speed
    on linux is limited to about 1MB/sec.

    I did some tests to find out what causes that.
    The first guess was that the pipe slows down things so much
    and so I did some tests with mmaped transfers instead of
    the pipe. But that did not change anything.
    The speed limit to ca. 1MB/sec seems to be in the
    comunication between generic scsi (SG) <-> scsi driver <-> scsi hardware.

    So as long as the speed is limited in the sg driver and kernel routines
    you do not get any problems with the reader process and pipe.
    (I did the test with an AMD K6-3/400Mhz). If I remeber right
    this is also valid for a Pentium 166.

    Bye
    Oliver

    -- 
    Homepage:	http://www.rauch-domain.de
    sane-umax:	http://www.rauch-domain.de/sane-umax
    xsane:		http://www.xsane.org
    E-Mail:		mailto:Oliver.Rauch@rauch-domain.de
    

    -- Source code, list archive, and docs: http://www.mostang.com/sane/ To unsubscribe: echo unsubscribe sane-devel | mail majordomo@mostang.com



    This archive was generated by hypermail 2b29 : Wed Feb 28 2001 - 09:00:45 PST