[sane-devel] LIDE210 5th button. sane-devel Digest, Vol 91, Issue 33
mwatson33 at comcast.net
Sun Jan 27 14:08:08 UTC 2013
Hack it is, not portable, ... I had considered something like
GENESYS_HAS_PDFS_SW and GENESYS_HAS_PDFF_SW, but it would have to integrate
with all the other interfaces and scanners. And the start,
GENESYS_HAS_PDFS_SW, is mapped as GENESYS_HAS_FILE_SW.
And then I considered one button for color PDF and the other for black and
white - perhaps something more generic would be better, like PDF0 and PDF1.
Or just have them all generic (B00 through B04).
There are 4 labels and 5 buttons. PDF has two buttons. Left to right:
"-------- PDF ---------" "AUTO SCAN" "COPY" "E-MAIL
B00 B01 B02 B03 B04
PDF START PDF FINISH
Button Map Mask filter
PDF START file x10 "^file.*"
PDF FINISH hacked x01 "^page.*"
AUTO SCAN scan x02 "^scan.*"
COPY copy x04 "^copy$"
E-MAIL email x08 "^email$"
All set up as
from-value = 1
to-value = 0
If I can be of any service please let me know.
From: Stef [mailto:stef.dev at free.fr]
Sent: Sunday, January 27, 2013 2:00 AM
To: Michael Watson
Cc: sane-devel at lists.alioth.debian.org
Subject: Re: [sane-devel] LIDE210 5th button. sane-devel Digest, Vol 91,
On 26/01/2013 04:31, Michael Watson wrote:
> The existing lide 210 code supports 4/5 buttons. I have 5/5 working
> temporarily (call it a hack) utilizing the enum OPT_PAGE_LOADED_SW
> that this scanner does not have.
> genesys_gl124.c (search for button)
> For the lide210 case add
> if (s->val[OPT_PAGE_LOADED_SW].b ==
> s->val[OPT_PAGE_LOADED_SW].b = (val & 0x01) == 0;
> Add "| GENESYS_HAS_PAGE_LOADED_SW" to static Genesys_Model
> add an action with filter = "^page.*"
> I do not understand the code that well to make a real 5th button
> addition. In genesys_low.h the options are defined (e.g. #define
> GENESYS_HAS_PAGE_LOADED_SW (1 << 4)) and all the bits could be used up
> with all the definitions. If it's portable we may have only 8 and
> they are used up.
this button is meant for document in detection. So using it like
this is effectively an hack. What are the buttons label on your scanner,
especially the one of this not yet supported button ?
More information about the sane-devel