Hi , Adding 192.168.1.50 mf8230 to /etc/hosts was really effective!
I still have a delay, now around 10 seconds. As seen below, its not the pixma enumeration that takes all this time (only one second), so I'm suspecting it's because all the backends are given a chance to find a device. And given the number of backends this will obviously take some time. But then I tried to do ./configure BACKENDS="pixma" --without-snmp --disable-ipv6 and then make Same result. To flip things around, I don't mind a full auto-detect taking 10 seconds or 1 minute, if only there was a way to specify the device manually (from command-line, environment-variable etc) scanimage -d mfnp://mf8230:8610 does not work, - can I specify a network device on the command line like this? - and will that stop the auto-detection? any help greatly appreciated! /Troels aug 21 20:21:08 -V, --version print version information aug 21 20:21:08 ---------------- before sane_get_devices() tpt aug 21 20:21:10 [sanei_debug] Setting debug level of pixma to 11. aug 21 20:21:10 [pixma] pixma is compiled with pthread support. aug 21 20:21:10 [pixma] pixma version 0.17.9 aug 21 20:21:10 [sanei_debug] Setting debug level of bjnp to 3. aug 21 20:21:10 [pixma] before find_scanners aug 21 20:21:10 [pixma] find_scanners() 1111 aug 21 20:21:10 [bjnp] sanei_bjnp_find_devices: aug 21 20:21:10 [bjnp] sanei_bjnp_find_devices: No devices specified in configuration file. aug 21 20:21:10 [bjnp] sanei_bjnp_find_devices: Added all configured scanners, now do auto detection aug 21 20:21:10 [bjnp] prepare_socket: lo is not a valid IPv4 interface, skipping... aug 21 20:21:10 [bjnp] prepare_socket: eth0 is IPv4 capable, sending broadcast, socket = 3 aug 21 20:21:10 [bjnp] sanei_bjnp_find_devices: Select returned, time left 0.499997.... aug 21 20:21:10 [bjnp] get_scanner_name: Forward lookup for mf8230 succeeded, using as hostname aug 21 20:21:10 [bjnp] bjnp_allocate_device(mfnp://mf8230:8610) 0 aug 21 20:21:10 [bjnp] get_scanner_name: Forward lookup for mf8230 succeeded, using as hostname aug 21 20:21:10 [bjnp] setup_udp_socket: Setting up a UDP socket, dest: 192.168.1.50 port 8610 aug 21 20:21:10 [bjnp] bjnp_allocate_device: Scanner not yet in our list, added it: mf8230:8610 aug 21 20:21:10 [bjnp] setup_udp_socket: Setting up a UDP socket, dest: 192.168.1.50 port 8610 aug 21 20:21:10 [bjnp] get_scanner_id: Scanner identity string = MFG:CANON;CMD:MFNP1,MultiPASS 2.1;M aug 21 20:21:10 [bjnp] get_scanner_id: Scanner model = MF8200C Series aug 21 20:21:10 [pixma] Scanner model found: Name MF8200C(Canon i-SENSYS MF8200C Series) matches MF8 aug 21 20:21:10 [bjnp] sanei_bjnp_find_devices: Select returned, time left 0.499998.... aug 21 20:21:10 [bjnp] get_scanner_name: Forward lookup for mf8230 succeeded, using as hostname aug 21 20:21:10 [bjnp] bjnp_allocate_device(mfnp://mf8230:8610) 1 aug 21 20:21:10 [bjnp] get_scanner_name: Forward lookup for mf8230 succeeded, using as hostname aug 21 20:21:10 [bjnp] setup_udp_socket: Setting up a UDP socket, dest: 192.168.1.50 port 8610 aug 21 20:21:10 [bjnp] add_scanner: Scanner at mfnp://mf8230:8610 was added before, good! aug 21 20:21:11 [bjnp] sanei_find_devices: scanner discovery finished... aug 21 20:21:11 [pixma] pixma_collect_devices() found Canon i-SENSYS MF8200C Series at mfnp://mf8230 aug 21 20:21:11 [pixma] find_scanners() 2222 aug 21 20:21:11 [pixma] pixma_find_scanners() found 1 devices aug 21 20:21:11 [pixma] find_scanners() 3333 aug 21 20:21:11 [pixma] after find_scanners aug 21 20:21:20 ---------------- after sane_get_devices() aug 21 20:21:20 55555 sane_open[pixma] sane_open() 1 <-------------- aug 21 20:21:20 [bjnp] sanei_bjnp_find_devices: 2014-08-16 12:50 GMT+02:00 Louis Lagendijk <[email protected]>: > Hi Troels > pixma.conf should have only contain > mfnp://192.168.1.50:8610 > in your case. It tells the backend where to find the scanner. The mfnp > part tells the backend that the device is a laser multi-functional (I > still don't understand why Canon choose to make that a different > protocol as except for the protocol name, identifier an port it is > pretty much the same as the bjnp protocol. > The delays may come from the reverse lookup on 192.168.1.50. > What does > nslookup 192.168.1.50 > return? Hoe long does that take? I guess around 5 seconds? > > What is the content of /etc/resolv.conf on your machine? Which > namservers do you use? Do you run your own nameserver? > > kind regards, Louis > > On Sat, 2014-08-16 at 12:36 +0200, Rolf Bensch wrote: > > Hi Troels, > > > > I just committed the patches to Sanes git repository. > > > > Please discuss the network issue with Louis. > > > > Many thanks for your help. > > > > Cheers, > > Rolf > > > > > > > > Am 14.08.2014 um 22:14 schrieb Troels Thomsen: > > > > > > Excelent! > > > I can now scan several times without resetting the device! > > > > > > One thing still drives me crazy, and its the delays. > > > There is a ~ one minute delay on "scanimage -h"! > > > See below > > > > > > I cant figure out how to cut this down. > > > I tried to ./Configure only with pixma backend, in case it was the sum > > > of all network broadcasts for all kinds of drivers that takes the time. > > > Then I tried adding bjnp://192.168.1.50 <http://192.168.1.50> to > > > /usr/local/etc/sane.d/pixma.conf > > > which only made things worse. > > > There should also be an environment option... > > > Do you have an advice? > > > > > > Regarding scanner, ADF is not tested, will do soon. > > > And debug the buttons, as you described. > > > > > > > > > troels@troels-Inspiron-530 ~/sane/sane-backends $ unbuffer scanimage > -h | ts > > > aug 14 22:07:09 Usage: scanimage [OPTION]... > > > aug 14 22:07:09 > > > aug 14 22:07:09 Start image acquisition on a scanner device and write > > > image data to > > > aug 14 22:07:09 standard output. > > > aug 14 22:07:09 > > > aug 14 22:07:09 Parameters are separated by a blank from > > > single-character options (e.g. > > > aug 14 22:07:09 -d epson) and by a "=" from multi-character options > > > (e.g. --device-name=epson). > > > aug 14 22:07:09 -d, --device-name=DEVICE use a given scanner device > > > (e.g. hp:/dev/scanner) > > > aug 14 22:07:09 --format=pnm|tiff file format of output file > > > aug 14 22:07:09 -i, --icc-profile=PROFILE include this ICC profile > into > > > TIFF file > > > aug 14 22:07:09 -L, --list-devices show available scanner > devices > > > aug 14 22:07:09 -f, --formatted-device-list=FORMAT similar to -L, but > > > the FORMAT of the output > > > aug 14 22:07:09 can be specified: %d (device > > > name), %v (vendor), > > > aug 14 22:07:09 %m (model), %t (type), %i > > > (index number), and > > > aug 14 22:07:09 %n (newline) > > > aug 14 22:07:09 -b, --batch[=FORMAT] working in batch mode, > FORMAT > > > is `out%d.pnm' or > > > aug 14 22:07:09 `out%d.tif' by default > > > depending on --format > > > aug 14 22:07:09 --batch-start=# page number to start naming > > > files with > > > aug 14 22:07:09 --batch-count=# how many pages to scan in > > > batch mode > > > aug 14 22:07:09 --batch-increment=# increase page number in > > > filename by # > > > aug 14 22:07:09 --batch-double increment page number by > two, > > > same as > > > aug 14 22:07:09 --batch-increment=2 > > > aug 14 22:07:09 --batch-print print image filenames to > stdout > > > aug 14 22:07:09 --batch-prompt ask for pressing a key > before > > > scanning a page > > > aug 14 22:07:09 --accept-md5-only only accept authorization > > > requests using md5 > > > aug 14 22:07:09 -p, --progress print progress messages > > > aug 14 22:07:09 -n, --dont-scan only set options, don't > > > actually scan > > > aug 14 22:07:09 -T, --test test backend thoroughly > > > aug 14 22:07:09 -A, --all-options list all available backend > > > options > > > aug 14 22:07:09 -h, --help display this help message > and > > > exit > > > aug 14 22:07:09 -v, --verbose give even more status > messages > > > aug 14 22:07:09 -B, --buffer-size=# change input buffer size (in > > > kB, default 32) > > > aug 14 22:07:09 -V, --version print version information > > > aug 14 22:07:11 [sanei_debug] Setting debug level of pixma to 3. > > > aug 14 22:07:11 [pixma] pixma is compiled with pthread support. > > > aug 14 22:07:11 [pixma] pixma version 0.17.9 > > > aug 14 22:07:11 [sanei_debug] Setting debug level of bjnp to 2. > > > aug 14 22:07:11 [bjnp] sanei_bjnp_find_devices: > > > aug 14 22:07:11 [bjnp] prepare_socket: eth0 is IPv4 capable, sending > > > broadcast, socket = 3 > > > aug 14 22:07:11 [bjnp] prepare_socket: eth0 is IPv6 capable, sending > > > broadcast, socket = 4 > > > aug 14 22:07:16 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:07:21 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:07:21 [bjnp] bjnp_allocate_device: Scanner not yet in our > > > list, added it: 192.168.1.50:8610 <http://192.168.1.50:8610> > > > aug 14 22:07:21 [bjnp] get_scanner_id: Scanner identity string = > > > MFG:CANON;CMD:MFNP1,MultiPASS 2.1;MDL:MF8200C Series;CLS:IMG;DES:Canon > > > MF8200C Series; - length = 86 > > > aug 14 22:07:21 [bjnp] get_scanner_id: Scanner model = MF8200C Series > > > aug 14 22:07:21 [pixma] Scanner model found: Name MF8200C(Canon > i-SENSYS > > > MF8200C Series) matches MF8200C Series > > > aug 14 22:07:26 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:07:31 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:07:31 [bjnp] add_scanner: Scanner at mfnp:// > 192.168.1.50:8610 > > > <http://192.168.1.50:8610> was added before, good! > > > aug 14 22:07:32 [pixma] pixma_collect_devices() found Canon i-SENSYS > > > MF8200C Series at mfnp://192.168.1.50:8610 <http://192.168.1.50:8610> > > > aug 14 22:07:32 [pixma] pixma_find_scanners() found 1 devices > > > aug 14 22:07:40 [bjnp] sanei_bjnp_find_devices: > > > aug 14 22:07:40 [bjnp] prepare_socket: eth0 is IPv4 capable, sending > > > broadcast, socket = 3 > > > aug 14 22:07:40 [bjnp] prepare_socket: eth0 is IPv6 capable, sending > > > broadcast, socket = 4 > > > aug 14 22:07:45 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:07:50 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:07:50 [bjnp] bjnp_allocate_device: Scanner not yet in our > > > list, added it: 192.168.1.50:8610 <http://192.168.1.50:8610> > > > aug 14 22:07:50 [bjnp] get_scanner_id: Scanner identity string = > > > MFG:CANON;CMD:MFNP1,MultiPASS 2.1;MDL:MF8200C Series;CLS:IMG;DES:Canon > > > MF8200C Series; - length = 86 > > > aug 14 22:07:50 [bjnp] get_scanner_id: Scanner model = MF8200C Series > > > aug 14 22:07:50 [pixma] Scanner model found: Name MF8200C(Canon > i-SENSYS > > > MF8200C Series) matches MF8200C Series > > > aug 14 22:07:55 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:08:00 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:08:00 [bjnp] add_scanner: Scanner at mfnp:// > 192.168.1.50:8610 > > > <http://192.168.1.50:8610> was added before, good! > > > aug 14 22:08:00 [pixma] pixma_collect_devices() found Canon i-SENSYS > > > MF8200C Series at mfnp://192.168.1.50:8610 <http://192.168.1.50:8610> > > > aug 14 22:08:00 [pixma] pixma_open(): Canon i-SENSYS MF8200C Series > > > aug 14 22:08:00 [bjnp] sanei_bjnp_open(mfnp://192.168.1.50:8610 > > > <http://192.168.1.50:8610>, -1221962896): > > > aug 14 22:08:05 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:08:05 [pixma] *iclass_open***** This is a generation 1 > > > scanner. ***** > > > aug 14 22:08:05 [pixma] Trying to clear the interrupt buffer... > > > aug 14 22:08:05 [bjnp] bjnp_set_timeout to 200 > > > aug 14 22:08:05 [bjnp] bjnp_read_int(0, bufferptr, 0x10 = 16): > > > aug 14 22:08:05 [pixma] no packets in buffer > > > aug 14 22:08:05 [bjnp] sanei_bjnp_deactivate (0) > > > aug 14 22:08:05 > > > aug 14 22:08:05 Options specific to device > `pixma:MF8200C_192.168.1.50': > > > aug 14 22:08:05 Scan mode: > > > aug 14 22:08:05 --resolution auto||75|150|300|600dpi [75] > > > aug 14 22:08:05 Sets the resolution of the scanned image. > > > aug 14 22:08:05 --mode auto|Color|Gray [Color] > > > aug 14 22:08:05 Selects the scan mode (e.g., lineart, > > > monochrome, or color). > > > aug 14 22:08:05 --source Flatbed|Automatic Document Feeder > [Flatbed] > > > aug 14 22:08:05 Selects the scan source (such as a > > > document-feeder). Set source before > > > aug 14 22:08:05 mode and resolution. Resets mode and resolution > > > to auto values. > > > aug 14 22:08:05 --button-controlled[=(yes|no)] [no] > > > aug 14 22:08:05 When enabled, scan process will not start > > > immediately. To proceed, > > > aug 14 22:08:05 press "SCAN" button (for MP150) or "COLOR" > > > button (for other models). > > > aug 14 22:08:05 To cancel, press "GRAY" button. > > > aug 14 22:08:05 Gamma: > > > aug 14 22:08:05 --custom-gamma[=(auto|yes|no)] [inactive] > > > aug 14 22:08:05 Determines whether a builtin or a custom > > > gamma-table should be used. > > > aug 14 22:08:05 --gamma-table auto|0..255,... [inactive] > > > aug 14 22:08:05 Gamma-correction table. In color mode this > > > option equally affects the > > > aug 14 22:08:05 red, green, and blue channels simultaneously > > > (i.e., it is an intensity > > > aug 14 22:08:05 gamma table). > > > aug 14 22:08:05 --gamma auto|0.299988..5 [inactive] > > > aug 14 22:08:05 Changes intensity of midtones > > > aug 14 22:08:05 Geometry: > > > aug 14 22:08:05 -l auto|0..216.747mm [0] > > > aug 14 22:08:05 Top-left x position of scan area. > > > aug 14 22:08:05 -t auto|0..355.6mm [0] > > > aug 14 22:08:05 Top-left y position of scan area. > > > aug 14 22:08:05 -x auto|0..216.747mm [216.747] > > > aug 14 22:08:05 Width of scan-area. > > > aug 14 22:08:05 -y auto|0..355.6mm [355.6] > > > aug 14 22:08:05 Height of scan-area. > > > aug 14 22:08:05 Buttons: > > > aug 14 22:08:05 --button-update > > > aug 14 22:08:05 Update button state > > > aug 14 22:08:05 Extras: > > > aug 14 22:08:05 --threshold auto|0..100% (in steps of 1) [inactive] > > > aug 14 22:08:05 Select minimum-brightness to get a white point > > > aug 14 22:08:05 --threshold-curve auto|0..127 (in steps of 1) > [inactive] > > > aug 14 22:08:05 Dynamic threshold curve, from light to dark, > > > normally 50-65 > > > aug 14 22:08:05 > > > aug 14 22:08:05 Type ``scanimage --help -d DEVICE'' to get list of all > > > options for DEVICE. > > > aug 14 22:08:05 > > > aug 14 22:08:06 [bjnp] sanei_bjnp_find_devices: > > > aug 14 22:08:06 [bjnp] prepare_socket: eth0 is IPv4 capable, sending > > > broadcast, socket = 4 > > > aug 14 22:08:06 [bjnp] prepare_socket: eth0 is IPv6 capable, sending > > > broadcast, socket = 6 > > > aug 14 22:08:11 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:08:16 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:08:16 [bjnp] bjnp_allocate_device: Scanner not yet in our > > > list, added it: 192.168.1.50:8610 <http://192.168.1.50:8610> > > > aug 14 22:08:16 [bjnp] get_scanner_id: Scanner identity string = > > > MFG:CANON;CMD:MFNP1,MultiPASS 2.1;MDL:MF8200C Series;CLS:IMG;DES:Canon > > > MF8200C Series; - length = 86 > > > aug 14 22:08:16 [bjnp] get_scanner_id: Scanner model = MF8200C Series > > > aug 14 22:08:16 [pixma] Scanner model found: Name MF8200C(Canon > i-SENSYS > > > MF8200C Series) matches MF8200C Series > > > aug 14 22:08:21 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:08:26 [bjnp] get_scanner_name: Name for 192.168.1.50 not > found > > > : Name or service not known > > > aug 14 22:08:26 [bjnp] add_scanner: Scanner at mfnp:// > 192.168.1.50:8610 > > > <http://192.168.1.50:8610> was added before, good! > > > aug 14 22:08:26 [pixma] pixma_collect_devices() found Canon i-SENSYS > > > MF8200C Series at mfnp://192.168.1.50:8610 <http://192.168.1.50:8610> > > > aug 14 22:08:26 [pixma] pixma_find_scanners() found 1 devices > > > aug 14 22:08:29 List of available devices: > > > aug 14 22:08:29 pixma:MF8200C_192.168.1.50 > > > aug 14 22:08:29 [pixma] pixma_close(): Canon i-SENSYS MF8200C Series > > > aug 14 22:08:29 [bjnp] sanei_bjnp_close(0): > > > > > > > > > Aparantly the delay problem has many facets. > > > - if I could figure out how to specify the device, no auto-detect would > > > take place. > > > - Aparantly the autodetection is done multiple times. Could 'scanimage' > > > in theory be refined to only do it once? Well this is out of scope > > > currently! > > > - ... > > > > > > > > > > > > >
-- sane-devel mailing list: [email protected] http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to [email protected]
