[sane-devel] scanner buttons

2004-07-09 Thread David Stevenson
> ok, here's a crazy idea- why not just reload the entire option array every 
> few seconds? the backend then gets to decide what order to reload them in 
> (i.e. load the 'mode' switch first, then change all the mode params, then 
> load the 'scan' button press).
> 
> is this nuts?
> 
> allan
> 

What sort of response time do we need?
I am thinking of a scan button, having pushed the button when will the 
user see some action? My feeling is less than one second is expected, 
ideally much less. Which implies to me either the polling is very low 
overhead or some sort of event triggered call back is needed.

just a thought...
David

(Henning sorry if this ends up double posting - I just sent from wrong 
account )



[sane-devel] scanner buttons

2004-07-09 Thread David Stevenson
> ok, here's a crazy idea- why not just reload the entire option array every 
> few seconds? the backend then gets to decide what order to reload them in 
> (i.e. load the 'mode' switch first, then change all the mode params, then 
> load the 'scan' button press).
> 
> is this nuts?
> 
> allan
> 
What sort of response time do we need?
I am thinking of a scan button, having pushed the button when will the 
user see some action? My feeling is less than one second is expected, 
ideally much less. Which implies to me either the polling is very low 
overhead or some sort of event triggered call back is needed.

just a thought...
David




[sane-devel] [CanoScan5000f] Analyse of logs

2004-07-08 Thread David Stevenson
Thibault North wrote:
> 
>> Unlikely, all things are possible but the windows driver will be 
>> reasonably efficient, and will not send the image more than it needs to.
>>
>> For a small image the calibration data may be larger than the image. 
>> You could try a larger scan - expect a very large log - and look for 
>> where the data is similar and where there is a large amount of new data.
>>
>> David
>>
> Ok but :
> - There are more thant 3 blocks which seems to be image data: 2 for 
> calibration and 1 for the picture ?
> What is the format of the sent picture ? RAW ? it might be possible to 
> find this no? To be able to determine what size if may have.
> For exemple : 100dpi, 1cm2 is about 39x39 pixels : this represents 1511 
> pixels. 8bits per pixel ? 16 ? (don't know..) if  8 : 4968 hex codes, 
> true ?
> 
The scanner may scan more than asked for, and the front end will use 
what it needs. 39x39 may scan as 40x40 or 64x64 or . It is also 
possible that 100dpi scans as 150dpi. OK not that likely but be prepared 
for it.
A colour scan is normally 24bits - 3 bytes per pixel. But again other 
values are possible.
> 
> - There is apparently a timeout when sniffing a big scan or a preview : 
> my computer my be to slow :( (Athlon 600Mhz, 256RAM). The scan stops at 
> that point :(
> 
> Now I have to understand libusb in order to try and get an answer of the 
> scanner from Linux...
> 
> Thanks,
> Thibault
> 
> 




[sane-devel] [CanoScan5000f] Analyse of logs

2004-07-08 Thread David Stevenson
> I was wondering if the image data could be sent in may times, or if as 
> you suggest there is some calibration : indeed the Windows driver says : 
> "lamp adjusment, please wait" or something like that in French :)
> 
Unlikely, all things are possible but the windows driver will be 
reasonably efficient, and will not send the image more than it needs to.

For a small image the calibration data may be larger than the image. You 
could try a larger scan - expect a very large log - and look for where 
the data is similar and where there is a large amount of new data.

David



[sane-devel] discussion: Future of SANE-project

2004-07-06 Thread David Stevenson
m. allan noah wrote:
> it is important to remember that the developers of sane are volunteers 
> just like you. most of us got involved because we had a lame scanner too. 
> we probably dont have time for such evangelism.

But if someone was offering
> that said, even if someone had the time to run around and convince vendors 
> of the merits of sane, there would be at least two recurring sentiments:
> 
> 1. sane spec is not complete, cause it does not support various 
> LEDs,buttons or sensors that the manufacturers believe add so much value 
> (and brand distinction) to their products.

Proposals to include this have been discussed, possibly input from a 
manufacture would help.
> 2. they are going to want more control over the gui so they can do things 
> like show pictures and diagrams of the scanner, which means they are going 
> to write their own front-end half the time.
> 
Or repackage existing - under GPL - is this a problem.
> then, i as a developer, and hopefully you as an open-source/free software 
> user would have another complaint:
> 
> 3. closed-source backends are much harder to debug/extend than free, even 
> if you have the vendor to complain to.
> 
This is looking for problems, why assume they will be closed source.
> that said, there are a couple vendors who do make backends (brother comes 
> to mind).




[sane-devel] SANE and switching off the scanner lamp.

2004-05-10 Thread David Stevenson
  is there a safe way to detect when the
> lamp is ready to scan?  maybe during coarse calibration?)
> 
This is going to be very scanner dependent.
I have done this for the GT68xx backend by using the coarse calibration 
test every 500msec and waiting till the result is unchanging.

David



[sane-devel] Xsane startup problems

2003-07-03 Thread david stevenson
On Thursday 03 July 2003 1:57 am, Farhan Ahmed wrote:
> Hi,
>
> I'm running Mandrake 9.1 on my Athlon system. When I initially installed
> Mandrake, Xsane was configured perfectly automatically and I had no
> problems using my Lexmark X73 flatbed scanner. But then I had to move to a
> new place and so I unhooked my computer and moved it. When I reconnected
> everything, to my utter surprise and dissapointment, I got the following
> error message:
>
> gt68xx] Couldn't open firmware file
> (neither`/usr/share/sane/gt68xx/OSLO3071b2.usb' nor
> `/usr/share/sane/gt68xx/oslo3071b2.usb'): No such file or directory

This means the backend could not find a file it needs to load into your 
scanner. You must have had this file installed correctly before for it to 
work so I do not know what happened in your move to loose it.
If you can not find it on your system see 
http://www.meier-geinitz.de/sane/gt68xx-backend/
for details of where to get it from.


> I still get the icon for Xsane on my desktop (KDE) automatically when I
> hook up the scanner and so the OS is detecting the scanner fine. Also, the
> Control Center on Mandrake seems to recognize the scanner correctly too. By
> the way, the scanner has a USB interface and it's connected to
> /dev/usb/scanner0
>
> Can anyone help me out please?



[sane-devel] Manufactures

2003-06-20 Thread david stevenson
Excellent,
What instant service.
Now all we need is manufactures to read it and start writing backends 8-)
Thanks
David

> Ok, what about this one:
>
> http://www.meier-geinitz.de/sane/misc/manufacturers.html
>
> There is now also a page that explains the SANE license:
>
> http://www.meier-geinitz.de/sane/misc/license.html
>
> Bye,
>   Henning
> ___
> Sane-devel mailing list
> sane-de...@www.mostang.com
> http://www.mostang.com/mailman/listinfo/sane-devel



[sane-devel] Manufactures

2003-06-20 Thread david stevenson
On Friday 20 June 2003 12:35 pm, Henning Meier-Geinitz wrote:
> Hi,
>
> On Fri, Jun 20, 2003 at 11:27:37AM +0100, david stevenson wrote:
> > and it occurred to me that it may help to have a page directed at
> > manufactures to explain how they can get their scanner supported.
>
> You mean a page about what a manufacturer can do to get a SANE driver?
>
> Well, that's pretty easy: Write a driver like explained on the
> "unsupported page". Or pay someone else to write it. Releasing
> programming information may make it easier for someone else to write a
> driver, but it's not a guarantee to get it written.
>
> Something along these lines? I could also add that to the "unsupported
> page".
>
Yes, general encouragement, I had not thought about all the details, it was an 
idea to see what others thought.
But could include, benefits of working with the mailing list, testing, finding 
developers. Feedback on what would help them release Sane drivers with new 
units.
David


> Bye,
>   Henning
>
>
> ___
> Sane-devel mailing list
> sane-de...@www.mostang.com
> http://www.mostang.com/mailman/listinfo/sane-devel



[sane-devel] Manufactures

2003-06-20 Thread david stevenson
Henning and all,

I was rereading your 

>Some links on how to write a SANE driver:
>http://www.meier-geinitz.de/sane/misc/unsupported.html
>http://www.meier-geinitz.de/sane/misc/develop.html

and it occurred to me that it may help to have a page directed at manufactures 
to explain how they can get their scanner supported.
I realise that the number of requests on the list of this nature is low 8-)
but the optimist in me says anyone working professionally on a scanner will 
have a look sooner or later, but may not want to reveal them selves.

Just an idle thought,  to generate work for others.

David



[sane-devel] "gamma" and "bayer" ? What are they?

2003-06-12 Thread david stevenson
On Thursday 12 June 2003 6:55 pm, Theodore Kilgore wrote:
> On Thu, 12 Jun 2003, [iso-8859-1] Thomas VIAL wrote:
> > Hi,

> Again, yes. My point was that a string of bytes equal in number to the
> number of pixels in the picture will give precisely no good result, but
> that on the other hand putting the text fomat of same data, obtained by
> suitable editing of the log file, will give a picture provided one only
> puts a ppm header on the top. In other words, if you read (for example) bc
> as one byte, and not as three bytes (one for b, one for c, and one for the
> space after it, and so on through the rest of the file) you do get a file
> but it is not a picture, but if you do it the second way (stupid as that
> may look) you do get a picture.
>
An interesting way to process data, but if it works...
In converting a byte to hex it is effectivly split into 2 nibbles of 4bits and 
a fixed value of 0x30 added to each. (or 0x37 if the nibble value is more 
than 9)
So using the ascii file as data should be twice the size (having ignored the 
spaces). The question then is what headers have you added to make the bitmap. 
Most headers include information on bits per pixel, pixels per line ...

David


[sane-devel] Proposal: Change of the backend and model status strings

2003-06-07 Thread david stevenson
Here are 2 personal opinions

On Friday 06 June 2003 7:18 pm, Henning Meier-Geinitz wrote:>
> There has been some criticism of the current handling of the :status
> keywords in the .desc files. These filse are used to create our lists
> of scanners and the output of the scanner search engine.
>
> We currently have two sorts of status indicators:
>
> 1) The backend status: alpha, beta or stable
> 2) The model status: unsupported, untested, alpha, beta or stable
>
>
> Concerning the backends status I think we don't really have the need
> to talk about stability. Crashing backends are rather seldom. So I'm
> not sure if we need this overall status at all anymore. If we want to
> keep it, what about a measurement on how active the backend is
> maintained, e.g.:
>
> unmaintained: There is no maintainer. Only security and other
>   grave bugs will be fixed
> supported:There is a maintainer for the backend. Bugs will be fixed and
>   patches will be accepted.
> development:  The backend is under active development. New features
>   and/or new models may be added.

Many backends support several scanners, and may be "supported" for most and 
under "development" for some. 
Is unmaintained and supported enough without the 3rd option?

> Model status: As proposed by others, I'd like to have a measurement on
> how good a scanner works compared to its capabilities. E.g.:
>
> unsupported:This device is not working at all.
> untested:   The device may work, but nobody has tested it yet.
> minimal:The device is detected and does something but is not
> really usable. E.g. It scans in one mode but colors
>   are off.
> basic:  The device is usable, but some modes are not supported
> or quality is not perfect yet.
> good:   Usable for day-to-day work. Some unusual modes or
> seldomly-used features aren't supported.
> perfect:Everything the scanner can do is supported.
>

I do not like the word "perfect" it implies totally bug free and not 
improvable, would "complete" be more suitable.

>
> Here is an example on how the HTML lists could look like:
>
> http://www.meier-geinitz.de/sane/tmp/sane-mfgs.html#MUSTEK
>
> Only the model status is implemented. And only Mustek SCSi scanners
> have set the values.
>
> Comments?
>
> Bye,
>   Henning
> ___
> Sane-devel mailing list
> sane-de...@www.mostang.com
> http://www.mostang.com/mailman/listinfo/sane-devel



[sane-devel] DLL backend doesn't work on 680x0 machines

2003-04-12 Thread david stevenson

> > I never was very good with declaring pointers to functions; it's
> > possible that I have some misplaced parentheses or something.
>
> Same here. Maybe one of the other developers has a better idea :-)

Me too, but I once met a man who had the magic. His advice was use #typedef 
then you do not have to fight with parentheses.


[sane-devel] Re: scanner.o modules

2003-03-14 Thread david stevenson
> Still I don't see any problem with the autoloading of the scanner
> module.
>
Is this a matter of leaving the light on?
I can not see any problem with the scanner being "on" from the usb point of 
view, but not running the light source for weeks on end.
Do all backends allow lamp off option?

David



[sane-devel] Movie size

2003-03-06 Thread david stevenson
Whoops sorry all
The previous message was not intended for the list at all, a mouse click 
error.


[sane-devel] Movie size

2003-03-06 Thread david stevenson
The first attempt was with 7bit encoding that made the file size 5.2meg and 
bounced.
The second attempt has not bounced and is 8bit raw file 3.9meg, so I guess 
your mail box is 5meg.
Question is can you watch the movie, or did the 8bit screw up?
David



[sane-devel] HP5470c scanner nearly working!

2003-02-21 Thread David Stevenson
On Wednesday 19 February 2003 10:52 pm, Martijn van Oosterhout wrote:
> This is only a test program, not a backend. Things still to do:
> 1. Actually use results of calibration scans. Anyone who has an idea how
> scanners are calibrated, point me at some info, please.
Martin
I did some work on gains and offsets for the GT68xx backend, the CCD version. 
The CIS version is somewhat different.
I was mostly porting the code supplied by the manufacture but the principal 
was fairly straight forward.
Loop 6 times,  adjusting by trial and error, scanning the line with it's 
black mark and white strip to set the offset. With a low gain, read an 
average white and and average black and adjust offset till these are equal 
distance from mid point. 
Then start looping to set the gain.
This was done for each colour building the gain till the avg signal level was 
near max.

Let me know if you need any more details.
David




[sane-devel] Scanner Basics

2002-11-17 Thread David Stevenson
On Saturday 16 November 2002 10:08 pm, Henning Meier-Geinitz wrote:
> Hi,

> * Put "scanner" in /etc/modules (works on Debian and Mandrake)
> * Add "modprobe scanner" to /etc/rc.d/rc.local or similar (RedHat)
>
putting a file called module containing the single word scanner in 
/etc/usbmgr/055f/021e works in sue 7.2 (changing the numbers to suit your 
scanner)

But suse 8.x is different. as it uses hotplug

David




[sane-devel] New backend: gt68xx for some Mustek USB scanners

2002-09-17 Thread David Stevenson
Thankyou and well done.

Quick first test with scanimage shows it to work as Sergey's test prog did on 
the 1200TA.
One bug from that I have failed to fix is the offset for top left origin is 
odd. 
using default 0,0 includes 4mm of extra margin on image, -l4 gets left margin 
correct but moves top edge.

I will try to look at this.
David


On Monday 16 September 2002 12:38 pm, Henning Meier-Geinitz wrote:
> Hi,
>
> There is now a SANE backend for GT-6801 and GT-6816 based scanners.
> It's based Sergey Vlasov's gt68xx driver. Actually, he did all the
> hard work and I only added the SANE interface.
>
> It's the first release and so it's VERY alpha:
> http://www.meier-geinitz.de/sane/gt68xx-backend/
>
> It intends to support the following scanners:
>
> Mustek BearPaw 1200 CU
> Mustek BearPaw 2400 CU
> Mustek ScanExpress 1200 UB Plus
> Mustek BearPaw 1200 TA
> Mustek BearPaw 2400 TA
> Mustek BearPaw 2400 TA Plus
>
> Only the first one is tested and somewhat works.
>
> Maybe other scanners that use one of the GT chips can be supported,
> too.
>
> Please test and send bug and success reports.
>
> Happy scanning,
>
>   Henning
> ___
> Sane-devel mailing list
> sane-de...@www.mostang.com
> http://www.mostang.com/mailman/listinfo/sane-devel


[sane-devel] USB scanner module ioctl

2002-01-21 Thread David Stevenson
Another request for help

Has anyone used ioctl in the usb scanner module to read control data from a 
unit?

My first attempts to send control messages to the scanner returns no error.
But when I try to read data back I do not get the data I hoped for.
As the function returns immediately, has it had time to send the request to 
the unit and wait for a reply?

David Stevenson


[sane-devel] Help with usb scanner module

2002-01-17 Thread David Stevenson
I am trying to find my way round to write a Bearpaw 1200TA driver. So here 
are some queries that I am stuck on.

I am loading "modprobe scanner"
and sane-find-scanner then reports 
sane-find-scanner: found USB scanner (vendor = 0x055f, product = 0x021e) at 
device /dev/usb/scanner0
sane-find-scanner: found USB scanner (vendor = 0x055f, product = 0x021e) at 
device /dev/usbscanner
sane-find-scanner: found USB scanner (vendor = 0x055f, product = 0x021e) at 
device /dev/usbscanner0

Is it correct to find it 3 times?

I have the start of a test program that opens /dev/usb/scanner0 and reads the 
vendor and product numbers. This works but after it has run once "lsmod" then 
shows
Module  Size  Used by
scanner 7984   7
usb-uhci   21488   0  (unused)
Subsequent runs do not alter the used number, but I now cannot rmmod scanner 
as it is 'in use'. Is there something obvious I have done wrong?

Where is devrequest defined?  As in
struct ctrlmsg_ioctl {
devrequest  req;
void*data;
} cmsg;

David


[sane-devel] BearPaw 1200TA

2002-01-02 Thread David Stevenson
I would like to write a driver for this USB scanner, but I am somewhat short 
on experience of sane. (and several other details 8-) )

I have looked a Henning's drivers and the 1200TA is quite different from the 
1200 he has done.

Does anyone else have a 1200TA?

David Stevenson