[sane-devel] HP ScanJet N6310 - SANE Not Supporting

stef stef.dev at free.fr
Wed Sep 14 11:30:39 UTC 2011


Le mercredi 7 septembre 2011 15:27:03 Abdul Salam V, vous avez écrit :
> This is amazing. Thanks Stef for this quick reply and great hint.
> 
> I have taken the values of Cannon Lide200 for motor, DAC and gpo entry.
> Since it's CCD one, for sensor entry taken the value of hp g4050. Now
> device is responding, motor & lamp is on and moving front and back. Hope
> this will not kill the device, let me if I'm anything wrong.
> 
> However, the output it generates is black screen file. Below is the code
> added into the genesys_devices.c file.
> 
> static Genesys_Model hpn6310_model = {
>   "hewlett-packard-scanjet-n6310",      /* Name */
>   "Hewlett Packard",                    /* Device vendor string */
>   "ScanJet N6310",                      /* Device model name */
>   GENESYS_GL847,
>   NULL,
> 
>   { 4800, 2400, 1200, 600, 400, 300, 200, 150, 100, 0},
>   { 4800, 2400, 1200, 600, 400, 300, 200, 150, 100, 0},
>   {16, 8, 0},                   /* possible depths in gray mode */
>   {16, 8, 0},                   /* possible depths in color mode */
> 
>   SANE_FIX (6.55),              /* Start of scan area in mm  (x) */
>   SANE_FIX (15.00),             /* Start of scan area in mm (y) */
>   /*SANE_FIX (217.9),             /* Size of scan area in mm (x) 5148
> pixels at 600 dpi*/
>   /*SANE_FIX (315.0),             /* Size of scan area in mm (y) */
>   SANE_FIX (216),        /* Size of scan area in mm (x) 435*/
>   SANE_FIX (511),         /* Size of scan area in mm (y) 511*/   /* In the
> device user manual flatbed glass size is maximum 216 mm, 300 mm. If I give
> this value to above yellow shaded code, motor is moving half and coming
> back.*/
> 
>   SANE_FIX (3.0),               /* Start of white strip in mm (y) */
>   SANE_FIX (0.0),               /* Start of black mark in mm (x) */
> 
>   SANE_FIX (0.0),               /* Start of scan area in TA mode in mm (x)
> */
>   SANE_FIX (0.0),               /* Start of scan area in TA mode in mm (y)
> */
>   SANE_FIX (100.0),             /* Size of scan area in TA mode in mm (x)
> */ SANE_FIX (100.0),             /* Size of scan area in TA mode in mm (y)
> */
> 
>   SANE_FIX (0.0),              /* Start of white strip in TA mode in mm (y)
> */
> 
>   SANE_FIX (0.0),               /* Size of scan area after paper sensor
> stops
>                                    sensing document in mm */
>   SANE_FIX (0.0),               /* Amount of feeding needed to eject
> document
>                                    after finishing scanning in mm */
> 
>   0, 32, 48,                    /* RGB CCD Line-distance correction in
> pixel */
> 
>   COLOR_ORDER_RGB,              /* Order of the CCD/CIS colors */
> 
>   SANE_FALSE,                   /* Is this a CIS scanner? */
>   SANE_FALSE,                   /* Is this a sheetfed scanner? */
>   CCD_G4050,
>   DAC_CANONLIDE200,
>   GPO_CANONLIDE200,
>  MOTOR_CANONLIDE200,
>   GENESYS_FLAG_UNTESTED        /* not fully working yet */
> 
>     | GENESYS_FLAG_LAZY_INIT
>     | GENESYS_FLAG_14BIT_GAMMA
>     | GENESYS_FLAG_DARK_CALIBRATION
>     | GENESYS_FLAG_OFFSET_CALIBRATION
>     | GENESYS_FLAG_CUSTOM_GAMMA
>     | GENESYS_FLAG_SKIP_WARMUP
>    | 
>    | GENESYS_FLAG_NO_CALIBRATION,
> 
> /*     | GENESYS_FLAG_HALF_CCD_MODE,*/
>   GENESYS_HAS_NO_BUTTONS, /* no buttons supported */
>   100,
>   100
> };
> 
> Still I'm looking into this in more detail. Since I'm newbie to this, I'm
> moving further without any proper managed way. Also I want to know how to
> analyse/compare the USBSnoopy.log .
> 
> Thanks once again,
> Abdul Salam

> > 
> >         Stef

	Hello,

	nice to have motor moving. Please use git to clone SANE's source tree and 
develop on branch you'll create. So that you'll be able to send patches 
generated by git-format-patch . That'll ease the process.
	Instead of reusing CCD_G4050 entry, create a new CCD_N6310 define and add 
an entry (filling it with G4050 values as a starting point if want, they'll 
have to be changed anyway) to the Sensor[] table in genesys_devices.c . Then 
use it in the device description.
	I use the appended script to reformat the UsbSnoop.log file. I have sent 
several time the 'rl' script I use to run a local test version of the genesys 
backend. It will set up debug messages to the max.
	The first goal is to have uncalibrated color preview (e.g. 75 or 100 dpi 
scan) working.

Regards,
	Stef

Regards,
	Stef
-------------- next part --------------
A non-text attachment was scrubbed...
Name: scripts.tar.gz
Type: application/x-compressed-tar
Size: 3079 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/sane-devel/attachments/20110914/b6a3f894/attachment.bin>


More information about the sane-devel mailing list