Hello, On 12/27/05, Pierre Willenbrock <pie...@pirsoft.dnsalias.org> wrote: > Parag N(????) schrieb: > > I have usb log captured on windows just after powering up > > scanner HP 2400. I am checking Genesys_Frontend,Genesys_Motor > > structure values in genesys_devices.c. I want to know how to calculate > > values for Genesys_Frontend structure. Also how to calculate maximum > > start speed ,maximum end speed of scanner motor? > > I assume you can already interpret register reads/writes. > > Genesys_Frontend contains the setting of the analog frontend: > AFE |Genesys_Frontend > Register| member > --------+---------------- > 0x00 |.reg[0] > 0x01 |.reg[1] > 0x02 |.reg[2] > 0x03 |.reg[3] > 0x04 |(reset) > 0x06 |.reg2[0] > 0x08 |.reg2[1] > 0x09 |.reg2[2] > 0x20 |.offset[0] > 0x21 |.offset[1] > 0x22 |.offset[2] > 0x24 |.sign[0] > 0x25 |.sign[1] > 0x26 |.sign[2] > 0x28 |.gain[0] > 0x29 |.gain[1] > 0x2a |.gain[2] > does that mean i have to fill Genesys_Frontend like this with replacing values of registers mentioned above {{0x00, 0x31, 0x1f, 0x13} , {0x08, 0x02, 0x16} , {0x20, 0x80, 0x10} , {0x80, 0x00, 0x00} , {0x01, 0xff, 0x00} }
> AFE Registers a written by setting register FEWDA(0x50) to the register > number and then writing to registers FEWRDATA(0x3a,0x3b), so you will > see these three register writes repeat in your log(Register numbers for > gl646). > But i am getting 0x51,0x3a,0x3b as repetitive registers in my linux debug log in gl646_bulk_write_register function. ??? > Genesys_Motor is not used in the gl646 part, but we want to move over to > parametrized slope generation not depending on hard-coded settings. > > Each Genesys_Motor_Slope contains a slope description for a specific > stepping mode. The described slope should lead to the fastest final > speed possible. > > The needed numbers can be directly derived from the slope tables(bulk > writes of maximum 256/512 bytes, to be interpreted as usigned short. > Each entry is the time between the corresponding steps). Take the > maximum starting speed you can find, and the maximum ending > speed(minimum value). > > The motor can be actuated in different step modes, so there will be > slope tables using half steps and tables using full steps. Half step > tables will contain values half as large as full step tables. Currently > the values in Genesys_Motor are the time for a full step, even if used > for half step mode. They will be devided accordingly. > > The 'g' entry can be set to 1, resulting in a linear acceleration. > > I see that 'minimum_steps' is misleading, it contains the number of > steps used for the slope, which is more of an upper limit for the number > of steps. > > In Genesys_Motor the 'base_ydpi' member is the motor resolution for full > step mode. 'optical_ydpi' is the maximum stepping resolution possible. > 'max_step_type' is the smallest step type: 0->full step, 1->half step, > 2->quarter step. Actually there is redundant information here, as > optical_ydpi=base_ydpi*2^max_step_type > > If you got your scanner to work and you are not afraid to damage it, you > can try to finetune the acceleration slopes. I could speed them up for > my scanner. But that will only improve low quality scan time and head > moving home time. > > Regards, > Pierre > > -- > sane-devel mailing list: sane-devel@lists.alioth.debian.org > http://lists.alioth.debian.org/mailman/listinfo/sane-devel > Unsubscribe: Send mail with subject "unsubscribe your_password" > to sane-devel-requ...@lists.alioth.debian.org > From pie...@pirsoft.dnsalias.org Wed Dec 28 13:42:01 2005 From: pie...@pirsoft.dnsalias.org (Pierre Willenbrock) Date: Wed Dec 28 13:42:15 2005 Subject: [sane-devel] how to fill values in Genesys_Frontend structure from usb log? In-Reply-To: <f4586a2e0512280516y7e74e217oeed83f801171b...@mail.gmail.com> References: <f4586a2e0512270632u1ceda55vbb4e708daa153...@mail.gmail.com> <43b17b39.30...@pirsoft.dnsalias.org> <f4586a2e0512280516y7e74e217oeed83f801171b...@mail.gmail.com> Message-ID: <43b29629.5060...@pirsoft.dnsalias.org> Hi Parag N(????) schrieb: > Hello, > > On 12/27/05, Pierre Willenbrock <pie...@pirsoft.dnsalias.org> wrote: > >>Parag N(????) schrieb: >> >>> I have usb log captured on windows just after powering up >>>scanner HP 2400. I am checking Genesys_Frontend,Genesys_Motor >>>structure values in genesys_devices.c. I want to know how to calculate >>>values for Genesys_Frontend structure. Also how to calculate maximum >>>start speed ,maximum end speed of scanner motor? >> >>I assume you can already interpret register reads/writes. >> >>Genesys_Frontend contains the setting of the analog frontend: >> AFE |Genesys_Frontend >>Register| member >>--------+---------------- >>0x00 |.reg[0] >>0x01 |.reg[1] >>0x02 |.reg[2] >>0x03 |.reg[3] >>0x04 |(reset) >>0x06 |.reg2[0] >>0x08 |.reg2[1] >>0x09 |.reg2[2] >>0x20 |.offset[0] >>0x21 |.offset[1] >>0x22 |.offset[2] >>0x24 |.sign[0] >>0x25 |.sign[1] >>0x26 |.sign[2] >>0x28 |.gain[0] >>0x29 |.gain[1] >>0x2a |.gain[2] >> > > does that mean i have to fill Genesys_Frontend like this with > replacing values of registers mentioned above > {{0x00, 0x31, 0x1f, 0x13} > , {0x08, 0x02, 0x16} > , {0x20, 0x80, 0x10} > , {0x80, 0x00, 0x00} > , {0x01, 0xff, 0x00} > } > You need to create a new entry in the list and add a new DAC_ in genesys_low.h, if there is no entry matching your data. Then you need to fill that entry with what you found. Ususally we set the .gain and .offset to only somehow sane values, as those will be calibrated before scanning. The rest depends on what you get in the log. >>AFE Registers a written by setting register FEWDA(0x50) to the register >>number and then writing to registers FEWRDATA(0x3a,0x3b), so you will >>see these three register writes repeat in your log(Register numbers for >>gl646). >> > > But i am getting 0x51,0x3a,0x3b as repetitive registers in my linux > debug log in gl646_bulk_write_register function. > ??? > Sorry, 0x51 is correct. Regards, Pierre