There is a great deal of variation between scanners and backends regarding what buttons are available and how they are exposed. You also have the exclusive device access problem. In the end, I think you need a new frontend, or modifications to an existing one, rather than a separate monitor.
allan On Thu, Dec 2, 2021 at 5:35 PM Paul Wolneykien <mano...@altlinux.org> wrote: > > Hi! > > As I can see, XSane doesn't poll the scanner's hardware buttons. > And if I understand the scanbd manual right, the daemon locks the SANE > interface to the scanner until a button is pressed, and then gives > exclusive access to the scanner for the frontend. So, the daemon is > primarily for launching a frontend, but not for controlling the > frontend while it is running. Am I right? > > I've grep'ed the mailing list archives a little and it seems that the > main purpose of various button daemons (scanbuttond, scanbd) is to > implement such a facility as "push scan": the user goes to a remote > (possibly, network) scanner, places a standard material into it, > presses a button on the scanner and the system performes an automatic > (that's important!) scan. > It also seems that in other situations, when a user wants to use an > interactive frontend (for making previews, selecting the scan > area, adjusting black and white points and gamma) the scanner is > expected to be placed on the table near PC. Or, at least, that the > material for scan can be placed into the scanner without a need for > further attention (i.e. a sheet material), so the user can set it up > and then back to his/her keyboard and mouse to make a scan or a number > of scans with different settings using the GUI frontend. > > These two stories (the "push story" and the "desktop story") are nice > and simple, but are more or less unapplicable in the world of book > scanning! > > Firstly, books are all different, so you need to make previews, > select areas and adjust things for each one. Secondly, books aren't > flat, so even if you use a special hardware you almost always need > to handle the book with both your hands! > > So, for scanning books, it would be nice to be able to control such a > frontend as XSane with the scanner's hardware buttons. Because most of > the time you can reach the hardware button even if you handle the book > using both hands (however, a configurable delay after the button is > pressed may be helpful option). > > (The other possible way to solve the described problem is to use a > separate triggering device. May be a pedal! But that's another story...) > > I want to know/discuss, what a design of a button monitor for > use with interactive frontends would fit into SANE better. Any ideas? > > -- "well, I stand up next to a mountain- and I chop it down with the edge of my hand"