[sane-devel] hp5300c usb problem

Stefan Kornhuber stefan@kornhuber.com
Tue, 26 Feb 2002 07:15:44 +0100


Hi Abel! Hi Rene!

Here is the output of scanimage with SANE_DEBUG_AVISION=255

thx for your help
steve

stefan@stefan:~ > scanimage -d avision:/dev/scanner
[sanei_debug] Setting debug level of avision to 255.
[avision] sane_init: parsing config line "scsi AVISION"
[avision] sane_init: config file line 1: trying to attach `scsi AVISION'
[avision] sane_init: parsing config line "/dev/sg0"
[avision] sane_init: config file line 2: trying to attach `/dev/sg0'
[avision] attach:
[avision] attach: opening /dev/sg0
[avision] attach: sending INQUIRY
[avision] wait_ready: sending TEST_UNIT_READY
[avision] attach: Inquiry gives mfg=HP, model=ScanJet 5370C, product 
revision=6.00.
[avision] FOUND
[avision] attach: The attached scanner is a USB model are not suported, yet!
[avision] attach: Use the allow-usb option in the config file to try anyway 
...
[avision] sane_init: parsing config line ""
[avision] sane_init: config file line 3: ignoring empty line
[avision] sane_init: parsing config line "#option disable-gamma-table"
[avision] sane_init: config file line 4: ignoring comment line
[avision] sane_init: parsing config line "#option force-a4"
[avision] sane_init: config file line 5: ignoring comment line
[avision] sane_init: parsing config line "option allow-usb"
[avision] sane_init: config file line 6: enabling allow-usb
[avision] sane_open:
[avision] attach:
[avision] attach: opening /dev/scanner
[avision] attach: sending INQUIRY
[avision] wait_ready: sending TEST_UNIT_READY
[avision] attach: Inquiry gives mfg=HP, model=ScanJet 5370C, product 
revision=6.00.
[avision] FOUND
[avision] RAW-Data:
[avision] result [ 0] 00000110b   6o   6d  6x
[avision] result [ 1] 10000000b 200o 128d 80x
[avision] result [ 2] 00000010b   2o   2d  2x
[avision] result [ 3] 01000010b 102o  66d 42x
[avision] result [ 4] 01011011b 133o  91d 5bx
[avision] result [ 5] 00000000b   0o   0d  0x
[avision] result [ 6] 00000000b   0o   0d  0x
[avision] result [ 7] 00000000b   0o   0d  0x
[avision] result [ 8] 01001000b 110o  72d 48x
[avision] result [ 9] 01010000b 120o  80d 50x
[avision] result [10] 00100000b  40o  32d 20x
[avision] result [11] 00100000b  40o  32d 20x
[avision] result [12] 00100000b  40o  32d 20x
[avision] result [13] 00100000b  40o  32d 20x
[avision] result [14] 00100000b  40o  32d 20x
[avision] result [15] 00100000b  40o  32d 20x
[avision] result [16] 01010011b 123o  83d 53x
[avision] result [17] 01100011b 143o  99d 63x
[avision] result [18] 01100001b 141o  97d 61x
[avision] result [19] 01101110b 156o 110d 6ex
[avision] result [20] 01001010b 112o  74d 4ax
[avision] result [21] 01100101b 145o 101d 65x
[avision] result [22] 01110100b 164o 116d 74x
[avision] result [23] 00100000b  40o  32d 20x
[avision] result [24] 00110101b  65o  53d 35x
[avision] result [25] 00110011b  63o  51d 33x
[avision] result [26] 00110111b  67o  55d 37x
[avision] result [27] 00110000b  60o  48d 30x
[avision] result [28] 01000011b 103o  67d 43x
[avision] result [29] 00100000b  40o  32d 20x
[avision] result [30] 00100000b  40o  32d 20x
[avision] result [31] 00100000b  40o  32d 20x
[avision] result [32] 00110110b  66o  54d 36x
[avision] result [33] 00101110b  56o  46d 2ex
[avision] result [34] 00110000b  60o  48d 30x
[avision] result [35] 00110000b  60o  48d 30x
[avision] result [36] 10100000b 240o 160d a0x
[avision] result [37] 00000110b   6o   6d  6x
[avision] result [38] 00001100b  14o  12d  cx
[avision] result [39] 01100111b 147o 103d 67x
[avision] result [40] 00000100b   4o   4d  4x
[avision] result [41] 10110000b 260o 176d b0x
[avision] result [42] 00000100b   4o   4d  4x
[avision] result [43] 10110000b 260o 176d b0x
[avision] result [44] 00001001b  11o   9d  9x
[avision] result [45] 01100000b 140o  96d 60x
[avision] result [46] 00001001b  11o   9d  9x
[avision] result [47] 01100000b 140o  96d 60x
[avision] result [48] 00000000b   0o   0d  0x
[avision] result [49] 00000000b   0o   0d  0x
[avision] result [50] 11111001b 371o 249d f9x
[avision] result [51] 10010111b 227o 151d 97x
[avision] result [52] 11010011b 323o 211d d3x
[avision] result [53] 00011000b  30o  24d 18x
[avision] result [54] 00001000b  10o   8d  8x
[avision] result [55] 00001000b  10o   8d  8x
[avision] result [56] 00000010b   2o   2d  2x
[avision] result [57] 00001000b  10o   8d  8x
[avision] result [58] 00001000b  10o   8d  8x
[avision] result [59] 00001000b  10o   8d  8x
[avision] result [60] 11000000b 300o 192d c0x
[avision] result [61] 11010100b 324o 212d d4x
[avision] result [62] 00100000b  40o  32d 20x
[avision] result [63] 00000101b   5o   5d  5x
[avision] result [64] 00000001b   1o   1d  1x
[avision] result [65] 00000001b   1o   1d  1x
[avision] result [66] 00000010b   2o   2d  2x
[avision] result [67] 00000011b   3o   3d  3x
[avision] result [68] 00000100b   4o   4d  4x
[avision] result [69] 00000101b   5o   5d  5x
[avision] result [70] 00000000b   0o   0d  0x
[avision] result [71] 00000000b   0o   0d  0x
[avision] result [72] 00000000b   0o   0d  0x
[avision] result [73] 00000000b   0o   0d  0x
[avision] result [74] 00000000b   0o   0d  0x
[avision] result [75] 00001111b  17o  15d  fx
[avision] result [76] 00000000b   0o   0d  0x
[avision] result [77] 00000101b   5o   5d  5x
[avision] result [78] 11011100b 334o 220d dcx
[avision] result [79] 00000101b   5o   5d  5x
[avision] result [80] 11011100b 334o 220d dcx
[avision] result [81] 00001001b  11o   9d  9x
[avision] result [82] 11111000b 370o 248d f8x
[avision] result [83] 00001101b  15o  13d  dx
[avision] result [84] 10110011b 263o 179d b3x
[avision] result [85] 00001001b  11o   9d  9x
[avision] result [86] 11111000b 370o 248d f8x
[avision] result [87] 00010000b  20o  16d 10x
[avision] result [88] 01101000b 150o 104d 68x
[avision] result [89] 00000100b   4o   4d  4x
[avision] result [90] 10110000b 260o 176d b0x
[avision] result [91] 00000101b   5o   5d  5x
[avision] result [92] 00000100b   4o   4d  4x
[avision] result [93] 11001000b 310o 200d c8x
[avision] result [94] 00000101b   5o   5d  5x
[avision] result [95] 00000000b   0o   0d  0x
[avision] attach: [8-15]  Vendor id.:      "HP      "
[avision] attach: [16-31] Product id.:     "ScanJet "
[avision] attach: [32-35] Product rev.:    "6.00"
[avision] attach: [36]    Bitfield: ADF 3-pass color 1-pass color 
RGB_COLOR_PLANE
[avision] attach: [37]    Optical res.:    600 dpi
[avision] attach: [38]    Maximum res.:    1200 dpi
[avision] attach: [39]    Bitfield1: Q_SCAN EXTENDET_RES NEW_PROTOCOL
[avision] attach: [40-41] X res. in gray:  1200 dpi
[avision] attach: [42-43] Y res. in gray:  1200 dpi
[avision] attach: [44-45] X res. in color: 2400 dpi
[avision] attach: [46-47] Y res. in color: 2400 dpi
[avision] attach: [48-49] USB max read:    0
[avision] attach: [50]    ESA1: LIGHT BUTTON NEED_SW_COLORPACK SW_CALIB 
NEED_SW_GAMMA XYRES_DIFFERENT
[avision] attach: [51]    ESA2: EXPOSURE_CTRL SUPP_QUALITY_SPEED_CAL 
HAS_PUSH_BUTTON NEW_CAL_METHOD ADF_MIRRORS
[avision] attach: [52]    ESA3: GRAY_WHITE 3x3COL_TABLE POWER_SAVING_TIMER 
NVM_DATA_REC
[avision] attach: [53]    line difference (software color pack): 24
[avision] attach: [54]    color mode pixel boundary: 8
[avision] attach: [55]    grey mode pixel boundary: 8
[avision] attach: [56]    4bit grey mode pixel boundary: 2
[avision] attach: [57]    lineart mode pixel boundary: 8
[avision] attach: [58]    halftone mode pixel boundary: 8
[avision] attach: [59]    error-diffusion mode pixel boundary: 8
[avision] attach: [60]    channels per pixel: 1 3
[avision] attach: [61]    bits per channel: 1 4 8 12
[avision] attach: [62]    scanner type: Flatbed (ADF)
[avision] attach: [77-78] Max X of transparency: 1500 FUBA
[avision] attach: [79-80] May Y of transparency: 1500 FUBA
[avision] attach: [81-82] Max X of flatbed:      2552 FUBA
[avision] attach: [83-84] May Y of flatbed:      3507 FUBA
[avision] attach: [85-86] Max X of ADF:          2552 FUBA
[avision] attach: [87-88] May Y of ADF:          4200 FUBA
[avision]                 (FUBA: not yet recognized unit ...)
[avision] attach: [89-90] Res. in Ex. mode:      1200 dpi
[avision] attach: [92]    Buttons:  4
[avision] attach: [93]    ESA4: SUPP_ACCESSORIES_DETECT SUPP_FLASH_UPDATE 
SUPP_LIGHT_DETECT SUPP_READ_PRNU_DATA SCAN_FLATBED_MIRRORED
[avision] Inquiry x/y-range seems to be vaild!
[avision] attach: range:        27.008667 x 37.115750
[avision] attach: adf_range:    27.008667 x 44.450000
[avision] attach: transp_range: 15.875000 x 15.875000
[avision] init_options
[avision] max_string_size
[avision] make_mode
[avision] sane_control_option
[avision] sane_control_option
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_control_option
[avision] sane_get_option_descriptor
[avision] sane_control_option
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_get_option_descriptor
[avision] sane_control_option
[avision] sane_control_option
[avision] sane_control_option
[avision] sane_get_option_descriptor
[avision] sane_control_option
[avision] constrain_value
[avision] sane_control_option
[avision] sane_get_option_descriptor
[avision] sane_control_option
[avision] constrain_value
[avision] sane_start
[avision] sane_get_parameters
[avision] tlx: 0.000000, tly: 0.000000, brx 1275.590551, bry 1748.031496
[avision] wait_ready: sending TEST_UNIT_READY
[avision] getting light status.
[avision] read_data: bytes 1
[avision] Light status: command is 0. Result is warming up
[avision] Light status: command is 0. Result is warming up
[avision] Light status: command is 0. Result is warming up
[avision] Light status: command is 0. Result is on
[avision] set_windows
[avision] set_gamma
[avision] brightness: 0.000000, contrast: 0.000000
[avision] gamma-table is used
[avision] start_scan
[avision] reader_process
[avision] lines_per_buffer=69, bytes_per_line=948
[avision] read_data
[avision] read_data: bytes 65412
[avision] go_home
scanimage: sanei_scsi.c:4334: sanei_scsi_cmd: Assertion `src_size >= cmd_size' 
failed.
Abgebrochen
stefan@stefan:~ > [avision] reader_process: read 69 lines
[avision] read_data
[avision] read_data: bytes 65412
[avision] reader_process: read 69 lines
[avision] read_data
[avision] read_data: bytes 65412
[avision] reader_process: read 69 lines
[avision] read_data
[avision] read_data: bytes 65412
[avision] reader_process: read 69 lines
[avision] read_data
[avision] read_data: bytes 65412
[avision] reader_process: read 69 lines
[avision] read_data
[avision] read_data: bytes 65412
[avision] reader_process: read 69 lines
[avision] read_data
[avision] read_data: bytes 20856
[avision] reader_process: read 22 lines



On Tuesday 26 February 2002 00:35, you wrote:
> Stefan Kornhuber wrote:
> > Hi Rene!
> >
> > I have tried following:
> >
> > stefan@stefan:~ > scanimage -d avision:/dev/scanner
> > scanimage: sanei_scsi.c:4334: sanei_scsi_cmd: Assertion `src_size >=
> > cmd_size' failed.
> > Abgebrochen
> >
> > but what means that.
>
> This means that you discovered a bug either in sanei_scsi.c or in the
> avision backend ;) More technically: It means that the function
> sanei_scsi_cmd in the sanei_scsi library was called with an "illegal"
> SCSI command. This function receives the SCSI comamnd block and possibly
> a write data block associated with this command from the caller;
> sanei_scsi_cmd needs to figure out (or to guess, if you prefer that) the
> size of the SCSI command block; if this guessed size is less than the
> parameter src_size, the program is stopped by an assert().
>
> Rene, do you have any idea where this could happen? Stefan, if you run
>
> 	export SANE_DEBUG_AVISION=255
> 	scanimage -d avision:/dev/scanner
>
> we might get, what happens.
>
> Abel