Am 16.04.2017 um 16:15 schrieb Florian Gagel: > Hi Wilhelm, > > thanks for your patch, works like a charm - I just had to made a small > modification since > the backend name inside the wrapper actually is "Genesys USB" (see below).
Thank you, Florian, for checking this once again. Just pushed this into trunk! > A minor hint for those who tinker around like me: Do no forget to turn > debugging off in > scanbd.conf when finished, otherwise syslog will overflow :-) > > Regards, > > Florian > > =============== cut here ================ > --- /usr/local/src/tmp/1.5.0/src/scanbd/scanbuttond_wrapper.c > 2017-04-05 05:46:59.000000000 +0000 > +++ scanbuttond_wrapper.c 2017-04-16 13:41:07.140209953 +0000 > @@ -1062,11 +1062,35 @@ > assert(backend_name); > slog(SLOG_INFO, "scanbtnd_button_name, backend: %s", backend_name); > > - if (strcmp("snapscan", backend_name)) { > - assert(button <= 5); > + if (strncmp("Genesys", backend_name,7) == 0) { > switch(button) { > case 0: > - return NULL; > + return "zero"; > + break; > + case 1: > + return "copy"; > + break; > + case 2: > + return "scan"; > + break; > + case 3: > + return "pdf"; > + break; > + case 4: > + return "email"; > + break; > + case 5: > + return "stop"; > + break; > + default: > + return "default"; > + break; > + } > + } > + else { > + switch(button) { > + case 0: > + return "zero"; > break; > case 1: > return "scan"; // "web"; > @@ -1084,9 +1108,10 @@ > return "stop"; > break; > default: > - return NULL; > + return "default"; > break; > } > + > } > return NULL; > } > > > Am 16.04.2017 um 11:59 schrieb Wilhelm: >> Am 15.04.2017 um 20:38 schrieb Florian Gagel: >>> Hi Wilhelm, >>> >>> thanks, your modification made all four buttons work ! >> Great! >> >>> This seems somewhat surprising to me at first glance, should the >>> backend not be strcmp'ed using "==0", providing >>> an own section for each backend :-) ? Anyway, it works, even if the >>> buttons are somewhat scrambled: >> Please backout the last patch I sent and now apply the attached one. >> This should mark your buttons with the right labels. >> >> If thats ok for you, I'll check this into trunk. >> >> Please report if teh patch is ok, or make your own modifications and >> send the patch back to me to be inserted into trunk. >> >> Thanks for using scanbd. >> >> -- Wilhelm >> >>> (Button press at scanner) -> (Action) >>> -------------------- >>> Email -> PDF >>> PDF -> Email >>> Scan -> Copy >>> Copy -> Scan. >>> >>> I also used string-triggers only. The buttons may have to be pressed for >>> a short period exceeding the polling interval. >>> Some minor possible pitfalls using the installations defaults of >>> scanbd-1.5.0 under Ubuntu 16.04: >>> - I removed the default package and configured the newer scanbd 1.5.0 as >>> described in the previous mail. I also used xinetd instead of the ubuntu >>> default >>> bsd-inetd for network scanner access although this should be of no >>> relevance. >>> - Wilhelms patch has to be applied to scanbuttond_wrapper.c (removed >>> assertion, return strings on any value of "button"). >>> - In scanbd.conf: Group should be "saned". Make sure all paths refer to >>> /usr/local/etc/scanbd, scriptdir = /usr/local/etc/scanbd/scripts, ... >>> - The new path also enters into /lib/systemd/system/scanbd.service, >>> after changing that do "systemctl daemon-reload" and restart scanbd. >>> >>> Now I am happy because of the four programmable buttons for my Odroid-U2 >>> SoC which has no monitor attached to it :-) >>> >>> Thanks again Wilhelm and Happy Easter ! >>> >>> Florian >>> >>> Am 15.04.2017 um 17:32 schrieb Wilhelm: >>>> Am 15.04.2017 um 16:13 schrieb Florian Gagel: >>>>> Hi Wilhelm, >>>>> >>>>> thanks for your reply - I made some progress in this issue however >>>>> still did not fully succeed. >>>>> >>>>> - First step as you told me: make clean, configure --enable-scanbuttond, >>>>> make, make install, copy manually the >>>>> old backends to /usr/local/lib/scanbd/scanbuttond as described in the >>>>> README (this all with the 1.5.0 version of scanbd). >>>>> - Starting scanbd -f -d7, I first got a "scanbd: Can't get the scbtn >>>>> device list" error. >>>>> - I edited /usr/local/lib/scanbd/scanbuttond/backends/meta.conf, making >>>>> it contain the single line "genesys" which was missing before. >>>> Yes, per default this was not included - I added it to trunk. >>>> >>>>> - Then the LiDE-60 was recognized by the old backend, together with its >>>>> four buttons ! >>>>> - However, scanbd finally stumbled on an assertion:/ >>>> Looks like you were the first one with an appropriate scanner to test >>>> this ;-) >>>> >>>> You can safely remove the mentioned assertion if you return non-null >>>> string-literals in all switch cases including the default case: >>>> >>>> --- scanbuttond_wrapper.c (Revision 236) >>>> >>>> +++ scanbuttond_wrapper.c (Arbeitskopie) >>>> >>>> @@ -1063,10 +1063,9 @@ >>>> >>>> slog(SLOG_INFO, "scanbtnd_button_name, backend: %s", backend_name); >>>> >>>> >>>> >>>> if (strcmp("snapscan", backend_name)) { >>>> - assert(button <= 5); >>>> switch(button) { >>>> case 0: >>>> - return NULL; >>>> + return "zero"; >>>> break; >>>> case 1: >>>> return "scan"; // "web"; >>>> @@ -1084,7 +1083,7 @@ >>>> return "stop"; >>>> break; >>>> default: >>>> - return NULL; >>>> + return "default"; >>>> break; >>>> } >>>> } >>>> >>>> >>>> If you don't mind please test this modification. I you succeed with it >>>> I'll put it into trunk. >>>> >>>>> root@gandroid:/usr/local/etc/scanbd# scanbd -f -d7 >>>>> scanbd: reading config file /usr/local/etc/scanbd/scanbd.conf >>>>> scanbd: debug on: level: 7 >>>>> scanbd: dropping privs to uid saned >>>>> scanbd: dropping privs to gid scanner >>>>> scanbd: group scanner has member: >>>>> scanbd: saned >>>>> scanbd: drop privileges to gid: 121 >>>>> scanbd: Running as effective gid 121 >>>>> scanbd: drop privileges to uid: 120 >>>>> scanbd: Running as effective uid 120 >>>>> scanbd: dbus_init >>>>> scanbd: dbus match type='signal',interface='org.freedesktop.Hal.Manager' >>>>> scanbd: Loading /usr/local/lib/scanbd/scanbuttond/backends/meta.so >>>>> scanbd: Loading /usr/local/lib/scanbd/scanbuttond/backends/genesys.so >>>>> scanbd: Scanning for local-only devices >>>>> scanbd: found device: CanoScan LiDE 60 Canon genesys:libusb:001:016 >>>>> scanbd: start_scbtn_threads >>>>> scanbd: start the threads (1) >>>>> scanbd: Starting poll thread for CanoScan LiDE 60 >>>>> scanbd: Thread started for device CanoScan LiDE 60 >>>>> scanbd: start dbus thread >>>>> scanbd: scbtn_poll >>>>> scanbd: udev init >>>>> scanbd: get udev monitor >>>>> scanbd: udev fd is non-blocking, now setting to blocking mode >>>>> scanbd: start udev thread >>>>> scanbd: udev thread started >>>>> scanbd: timeout: 500 ms >>>>> scanbd: Iteration on dbus call >>>>> scanbd: found 15 options for device CanoScan LiDE 60 >>>>> scanbd: sane_find_matching_options >>>>> scanbd: found 3 actions in section (null) >>>>> scanbd: checking action scan with filter: ^scan.* >>>>> scanbd: scanbtnd_button_name (1) >>>>> scanbd: scanbtnd_button_name, backend: Genesys USB >>>>> scanbd: found active option[0] scan for device CanoScan LiDE 60 >>>>> scanbd: installing action scan (0) for CanoScan LiDE 60, option[0]: scan >>>>> as: test.script >>>>> scanbd: multiple actions allowed >>>>> scanbd: scanbtnd_button_name (2) >>>>> scanbd: scanbtnd_button_name, backend: Genesys USB >>>>> scanbd: found active option[1] copy for device CanoScan LiDE 60 >>>>> scanbd: scanbtnd_button_name (3) >>>>> scanbd: scanbtnd_button_name, backend: Genesys USB >>>>> scanbd: found active option[2] email for device CanoScan LiDE 60 >>>>> scanbd: scanbtnd_button_name (4) >>>>> scanbd: scanbtnd_button_name, backend: Genesys USB >>>>> scanbd: found active option[3] pdf for device CanoScan LiDE 60 >>>>> scanbd: scanbtnd_button_name (5) >>>>> scanbd: scanbtnd_button_name, backend: Genesys USB >>>>> scanbd: found active option[4] stop for device CanoScan LiDE 60 >>>>> scanbd: scanbtnd_button_name (6) >>>>> scanbd: scanbtnd_button_name, backend: Genesys USB >>>>> scanbd: scanbuttond_wrapper.c:1066: scanbtnd_button_name: Assertion >>>>> `button <= 5' failed. >>>>> Aborted >>>>> >>>>> Of course there are only 4 buttons physically, plus one hidden reset >>>>> button. Now i am unsure whether simply to edit the source code in >>>>> order to >>>>> remove the assertion. My feeling is it might work then. >>>>> >>>>> Regards, >>>>> Florian/ >>>>> >>>>> /Am 15.04.2017 um 12:26 schrieb Wilhelm Meier: >>>>>> Hi Florian, >>>>>> >>>>>> scanbd totally relies on libsane to read the option (button) values. It >>>>>> is known, that some backends aren't capable doing this ... >>>>>> >>>>>> For the Lide60 you can try uing the old scanbuttond backends >>>>>> included in >>>>>> the scanbd source tree. See the ReadMe.txt for instructions please. >>>>>> >>>>>> >>>>>> >>>>>> Am 15.04.2017 um 10:44 schrieb Florian Gagel: >>>>>>> Hi, >>>>>>> >>>>>>> my LiDE60 is working well, either directly using scanimage with scanbd >>>>>>> not running, as "genesys:libusb:001:016" or with running scanbd using >>>>>>> xinetd as "net:localhost:genesys:libusb:001:016". >>>>>>> However, none of the four buttons seem to be recognized: >>>>>>> >>>>>>> root@gandroid:/usr/local/etc/scanbd# scanbd -f -d7 >>>>>>> scanbd: reading config file /usr/local/etc/scanbd/scanbd.conf >>>>>>> scanbd: debug on: level: 7 >>>>>>> scanbd: dropping privs to uid saned >>>>>>> scanbd: dropping privs to gid scanner >>>>>>> scanbd: group scanner has member: >>>>>>> scanbd: saned >>>>>>> scanbd: drop privileges to gid: 121 >>>>>>> scanbd: Running as effective gid 121 >>>>>>> scanbd: drop privileges to uid: 120 >>>>>>> scanbd: Running as effective uid 120 >>>>>>> scanbd: dbus_init >>>>>>> scanbd: dbus match >>>>>>> type='signal',interface='org.freedesktop.Hal.Manager' >>>>>>> scanbd: SANE_CONFIG_DIR=/usr/local/etc/scanbd >>>>>>> scanbd: sane version 1.0 >>>>>>> scanbd: Scanning for local-only devices >>>>>>> scanbd: found device: genesys:libusb:001:016 Canon LiDE 60 flatbed >>>>>>> scanner >>>>>>> scanbd: start_sane_threads >>>>>>> scanbd: Starting poll thread for genesys:libusb:001:016 >>>>>>> scanbd: Thread started for device genesys:libusb:001:016 >>>>>>> scanbd: sane_poll >>>>>>> scanbd: start dbus thread >>>>>>> scanbd: udev init >>>>>>> scanbd: get udev monitor >>>>>>> scanbd: udev fd is non-blocking, now setting to blocking mode >>>>>>> scanbd: start udev thread >>>>>>> scanbd: udev thread started >>>>>>> scanbd: timeout: 500 ms >>>>>>> scanbd: Iteration on dbus call >>>>>>> scanbd: Iteration on dbus call >>>>>>> scanbd: found 49 options for device genesys:libusb:001:016 >>>>>>> scanbd: sane_find_matching_options >>>>>>> scanbd: found 5 actions in section (null) >>>>>>> scanbd: checking action scan with filter: ^scan.* >>>>>>> scanbd: found active option[2] mode (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[4] preview (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[5] depth (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[6] resolution (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[8] tl-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[9] tl-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[10] br-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[11] br-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[13] custom-gamma (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[18] swdeskew (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[19] swcrop (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[20] swdespeck (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[21] despeck (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[22] swskip (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[23] swderotate (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[24] brightness (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[25] contrast (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[27] lamp-off-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[28] lamp-off-scan (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[29] threshold (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[30] threshold-curve (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[31] disable-dynamic-lineart (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[32] disable-interpolation (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[33] color-filter (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[34] calibration-file (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[35] expiration-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[48] clear-calibration (type: 4) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: checking action email with filter: ^email$ >>>>>>> scanbd: found active option[2] mode (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[4] preview (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[5] depth (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[6] resolution (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[8] tl-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[9] tl-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[10] br-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[11] br-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[13] custom-gamma (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[18] swdeskew (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[19] swcrop (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[20] swdespeck (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[21] despeck (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[22] swskip (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[23] swderotate (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[24] brightness (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[25] contrast (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[27] lamp-off-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[28] lamp-off-scan (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[29] threshold (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[30] threshold-curve (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[31] disable-dynamic-lineart (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[32] disable-interpolation (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[33] color-filter (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[34] calibration-file (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[35] expiration-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[48] clear-calibration (type: 4) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: checking action copy with filter: ^copy$ >>>>>>> scanbd: found active option[2] mode (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[4] preview (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[5] depth (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[6] resolution (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[8] tl-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[9] tl-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[10] br-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[11] br-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[13] custom-gamma (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[18] swdeskew (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[19] swcrop (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[20] swdespeck (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[21] despeck (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[22] swskip (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[23] swderotate (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[24] brightness (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[25] contrast (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[27] lamp-off-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[28] lamp-off-scan (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[29] threshold (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[30] threshold-curve (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[31] disable-dynamic-lineart (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[32] disable-interpolation (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[33] color-filter (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[34] calibration-file (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[35] expiration-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[48] clear-calibration (type: 4) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: checking action preview with filter: ^preview$ >>>>>>> scanbd: found active option[2] mode (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[4] preview (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: installing action preview (0) for genesys:libusb:001:016, >>>>>>> option[4]: preview as: test.script >>>>>>> scanbd: multiple actions allowed >>>>>>> scanbd: get_sane_option_value >>>>>>> scanbd: Initial value of option preview is 0 >>>>>>> scanbd: found active option[5] depth (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[6] resolution (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[8] tl-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[9] tl-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[10] br-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[11] br-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[13] custom-gamma (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[18] swdeskew (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[19] swcrop (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[20] swdespeck (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[21] despeck (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[22] swskip (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[23] swderotate (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[24] brightness (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[25] contrast (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[27] lamp-off-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[28] lamp-off-scan (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[29] threshold (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[30] threshold-curve (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[31] disable-dynamic-lineart (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[32] disable-interpolation (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[33] color-filter (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[34] calibration-file (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[35] expiration-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[48] clear-calibration (type: 4) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: checking action globaltest with filter: ^message.* >>>>>>> scanbd: found active option[2] mode (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[4] preview (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[5] depth (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[6] resolution (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[8] tl-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[9] tl-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[10] br-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[11] br-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[13] custom-gamma (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[18] swdeskew (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[19] swcrop (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[20] swdespeck (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[21] despeck (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[22] swskip (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[23] swderotate (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[24] brightness (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[25] contrast (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[27] lamp-off-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[28] lamp-off-scan (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[29] threshold (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[30] threshold-curve (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[31] disable-dynamic-lineart (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[32] disable-interpolation (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[33] color-filter (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[34] calibration-file (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[35] expiration-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[48] clear-calibration (type: 4) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: sane_find_matching_functions >>>>>>> scanbd: found 2 functions in section (null) >>>>>>> scanbd: checking function function_knob with filter: ^message.* >>>>>>> scanbd: option[1] has no name >>>>>>> scanbd: found active option[2] mode (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[3] is not active >>>>>>> scanbd: found active option[4] preview (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[5] depth (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[6] resolution (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[7] has no name >>>>>>> scanbd: found active option[8] tl-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[9] tl-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[10] br-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[11] br-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[12] has no name >>>>>>> scanbd: found active option[13] custom-gamma (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[14] is not active >>>>>>> scanbd: option[15] is not active >>>>>>> scanbd: option[16] is not active >>>>>>> scanbd: option[17] is not active >>>>>>> scanbd: found active option[18] swdeskew (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[19] swcrop (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[20] swdespeck (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[21] despeck (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[22] swskip (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[23] swderotate (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[24] brightness (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[25] contrast (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[26] has no name >>>>>>> scanbd: found active option[27] lamp-off-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[28] lamp-off-scan (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[29] threshold (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[30] threshold-curve (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[31] disable-dynamic-lineart (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[32] disable-interpolation (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[33] color-filter (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[34] calibration-file (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[35] expiration-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[36] has no name >>>>>>> scanbd: option[37] is not active >>>>>>> scanbd: option[38] is not active >>>>>>> scanbd: option[39] is not active >>>>>>> scanbd: option[40] is not active >>>>>>> scanbd: option[41] is not active >>>>>>> scanbd: option[42] is not active >>>>>>> scanbd: option[43] is not active >>>>>>> scanbd: option[44] is not active >>>>>>> scanbd: option[45] is not active >>>>>>> scanbd: option[46] has no name >>>>>>> scanbd: option[47] is not active >>>>>>> scanbd: found active option[48] clear-calibration (type: 4) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: checking function function_mode with filter: ^mode.* >>>>>>> scanbd: option[1] has no name >>>>>>> scanbd: found active option[2] mode (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: installing function function_mode for genesys:libusb:001:016, >>>>>>> option[2]: mode as env: SCANBD_FUNCTION_MODE >>>>>>> scanbd: option[3] is not active >>>>>>> scanbd: found active option[4] preview (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[5] depth (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[6] resolution (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[7] has no name >>>>>>> scanbd: found active option[8] tl-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[9] tl-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[10] br-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[11] br-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[12] has no name >>>>>>> scanbd: found active option[13] custom-gamma (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[14] is not active >>>>>>> scanbd: option[15] is not active >>>>>>> scanbd: option[16] is not active >>>>>>> scanbd: option[17] is not active >>>>>>> scanbd: found active option[18] swdeskew (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[19] swcrop (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[20] swdespeck (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[21] despeck (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[22] swskip (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[23] swderotate (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[24] brightness (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[25] contrast (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[26] has no name >>>>>>> scanbd: found active option[27] lamp-off-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[28] lamp-off-scan (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[29] threshold (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[30] threshold-curve (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[31] disable-dynamic-lineart (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[32] disable-interpolation (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[33] color-filter (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[34] calibration-file (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[35] expiration-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: option[36] has no name >>>>>>> scanbd: option[37] is not active >>>>>>> scanbd: option[38] is not active >>>>>>> scanbd: option[39] is not active >>>>>>> scanbd: option[40] is not active >>>>>>> scanbd: option[41] is not active >>>>>>> scanbd: option[42] is not active >>>>>>> scanbd: option[43] is not active >>>>>>> scanbd: option[44] is not active >>>>>>> scanbd: option[45] is not active >>>>>>> scanbd: option[46] has no name >>>>>>> scanbd: option[47] is not active >>>>>>> scanbd: found active option[48] clear-calibration (type: 4) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found 6 local device sections >>>>>>> scanbd: checking device section avision with filter: ^avision.* >>>>>>> scanbd: checking device section fujitsu with filter: ^fujitsu.* >>>>>>> scanbd: checking device section hp with filter: ^hpaio.* >>>>>>> scanbd: checking device section pixma with filter: ^pixma.* >>>>>>> scanbd: checking device section snapscan with filter: >>>>>>> (.*snapscan.*|.*Perfection.*) >>>>>>> scanbd: checking device section canon with filter: ^genesys.* >>>>>>> scanbd: found 1 local action for device genesys:libusb:001:016 [canon] >>>>>>> scanbd: sane_find_matching_options >>>>>>> scanbd: found 1 actions in section canon >>>>>>> scanbd: checking action file with filter: ^file.* >>>>>>> scanbd: found active option[2] mode (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[4] preview (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[5] depth (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[6] resolution (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[8] tl-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[9] tl-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[10] br-x (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[11] br-y (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[13] custom-gamma (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[18] swdeskew (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[19] swcrop (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[20] swdespeck (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[21] despeck (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[22] swskip (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[23] swderotate (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[24] brightness (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[25] contrast (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[27] lamp-off-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[28] lamp-off-scan (type: 0) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[29] threshold (type: 2) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[30] threshold-curve (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[31] disable-dynamic-lineart (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[32] disable-interpolation (type: 0) for >>>>>>> device genesys:libusb:001:016 >>>>>>> scanbd: found active option[33] color-filter (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[34] calibration-file (type: 3) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[35] expiration-time (type: 1) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: found active option[48] clear-calibration (type: 4) for device >>>>>>> genesys:libusb:001:016 >>>>>>> scanbd: sane_find_matching_functions >>>>>>> scanbd: no matching functions in section canon >>>>>>> scanbd: timeout: 500 ms >>>>>>> scanbd: Start the polling for device genesys:libusb:001:016 >>>>>>> scanbd: polling thread for genesys:libusb:001:016, before >>>>>>> cancellation point >>>>>>> scanbd: polling thread for genesys:libusb:001:016, after >>>>>>> cancellation point >>>>>>> scanbd: polling device genesys:libusb:001:016 >>>>>>> scanbd: get_sane_option_value >>>>>>> scanbd: checking option preview number 4 (0) for device >>>>>>> genesys:libusb:001:016: value: 0 >>>>>>> scanbd: polling thread for genesys:libusb:001:016, before >>>>>>> cancellation point >>>>>>> scanbd: polling thread for genesys:libusb:001:016, after >>>>>>> cancellation point >>>>>>> scanbd: polling device genesys:libusb:001:016 >>>>>>> scanbd: get_sane_option_value >>>>>>> scanbd: checking option preview number 4 (0) for device >>>>>>> genesys:libusb:001:016: value: 0 >>>>>>> scanbd: Iteration on dbus call >>>>>>> scanbd: polling thread for genesys:libusb:001:016, before >>>>>>> cancellation point >>>>>>> scanbd: polling thread for genesys:libusb:001:016, after >>>>>>> cancellation point >>>>>>> scanbd: polling device genesys:libusb:001:016 >>>>>>> scanbd: get_sane_option_value >>>>>>> scanbd: checking option preview number 4 (0) for device >>>>>>> genesys:libusb:001:016: value: 0 >>>>>>> scanbd: polling thread for genesys:libusb:001:016, before >>>>>>> cancellation point >>>>>>> scanbd: polling thread for genesys:libusb:001:016, after >>>>>>> cancellation point >>>>>>> scanbd: polling device genesys:libusb:001:016 >>>>>>> scanbd: get_sane_option_value >>>>>>> scanbd: checking option preview number 4 (0) for device >>>>>>> genesys:libusb:001:016: value: 0 >>>>>>> scanbd: Iteration on dbus call >>>>>>> scanbd: polling thread for genesys:libusb:001:016, before >>>>>>> cancellation point >>>>>>> scanbd: polling thread for genesys:libusb:001:016, after >>>>>>> cancellation point >>>>>>> scanbd: polling device genesys:libusb:001:016 >>>>>>> scanbd: get_sane_option_value >>>>>>> scanbd: checking option preview number 4 (0) for device >>>>>>> genesys:libusb:001:016: value: 0 >>>>>>> scanbd: polling thread for genesys:libusb:001:016, before >>>>>>> cancellation point >>>>>>> scanbd: polling thread for genesys:libusb:001:016, after >>>>>>> cancellation point >>>>>>> scanbd: polling device genesys:libusb:001:016 >>>>>>> scanbd: get_sane_option_value >>>>>>> scanbd: checking option preview number 4 (0) for device >>>>>>> genesys:libusb:001:016: value: 0 >>>>>>> scanbd: Iteration on dbus call >>>>>>> scanbd: polling thread for genesys:libusb:001:016, before >>>>>>> cancellation point >>>>>>> scanbd: polling thread for genesys:libusb:001:016, after >>>>>>> cancellation point >>>>>>> scanbd: polling device genesys:libusb:001:016 >>>>>>> scanbd: get_sane_option_value >>>>>>> >>>>>>> >>>>>>> My scanbd.conf: >>>>>>> >>>>>>> /* >>>>>>> * $Id: scanbd.conf 237 2017-04-05 05:46:59Z wimalopaan $ >>>>>>> * >>>>>>> * scanbd - KMUX scanner button daemon >>>>>>> * >>>>>>> * Copyright (C) 2008 - 2016 Wilhelm Meier (wilhelm.me...@fh-kl.de) >>>>>>> * >>>>>>> * This program is free software; you can redistribute it and/or >>>>>>> modify >>>>>>> * it under the terms of the GNU General Public License as >>>>>>> published by >>>>>>> * the Free Software Foundation; either version 2 of the License, or >>>>>>> * (at your option) any later version. >>>>>>> * >>>>>>> * This program is distributed in the hope that it will be useful, >>>>>>> * but WITHOUT ANY WARRANTY; without even the implied warranty of >>>>>>> * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the >>>>>>> * GNU General Public License for more details. >>>>>>> * >>>>>>> * You should have received a copy of the GNU General Public License >>>>>>> * along with this program; if not, write to the Free Software >>>>>>> * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA >>>>>>> 02110-1301, USA. >>>>>>> */ >>>>>>> >>>>>>> >>>>>>> # global settings >>>>>>> global { >>>>>>> # turn on debugging >>>>>>> # log to console >>>>>>> debug = true >>>>>>> >>>>>>> # debug logging >>>>>>> # 1=error, 2=warn, 3=info, 4-7=debug >>>>>>> debug-level = 7 >>>>>>> # drop priviliges to this user >>>>>>> #============================= >>>>>>> # Linux (most distributions use the saned user): >>>>>>> # user = saned >>>>>>> # ArchLinux (ArchLinux doesn't have saned user) >>>>>>> # user = daemon >>>>>>> # *BSD >>>>>>> # user = root >>>>>>> user = saned >>>>>>> >>>>>>> # Group to be used >>>>>>> #================= >>>>>>> # Linux (most distributions use the lp group to access >>>>>>> scanners) >>>>>>> # group = lp >>>>>>> # ArchLinux (ArchLinux uses the scanner group) >>>>>>> # group = scanner >>>>>>> # >>>>>>> # *BSD (no group lp here, use daemon instead) >>>>>>> # group = daemon # root >>>>>>> # >>>>>>> #group = lp >>>>>>> group = scanner >>>>>>> >>>>>>> # the saned executable for manager-mode >>>>>>> saned = "/usr/sbin/saned" >>>>>>> saned_opt = {} # string-list >>>>>>> saned_env = { "SANE_CONFIG_DIR=/etc/scanbd" } # list of >>>>>>> environment vars for saned >>>>>>> >>>>>>> # Scriptdir specifies where scanbd normally looks for >>>>>>> scripts. >>>>>>> # The scriptdir option can be defined as: >>>>>>> # - a path relative to the configuations >>>>>>> (<path>/etc/scanbd) >>>>>>> directory >>>>>>> # - an abosolute path >>>>>>> # Examples: >>>>>>> # scriptdir = scripts >>>>>>> # sets scriptdir to <path>/etc/scanbd/scripts. >>>>>>> # scriptdir = /some/path >>>>>>> # sets scriptdir to the specified absolute path >>>>>>> # Default scriptdir is <path>/etc/scanbd, this is normally >>>>>>> appropriate >>>>>>> scriptdir = /etc/scanbd/scripts >>>>>>> # Scripts to execute upon device insertion/removal. >>>>>>> # It can be necessary to load firmware into the device >>>>>>> when it >>>>>>> is first >>>>>>> # inserted. For example, scanbuttond backend does not know >>>>>>> how >>>>>>> to load >>>>>>> # scanner firmware, and it can be rectified by making a >>>>>>> custom >>>>>>> script. >>>>>>> # A simple command like "scanimage -L" in an example >>>>>>> insert.script >>>>>>> # invokes saned and it loads the appropriate firmware if >>>>>>> necessary. >>>>>>> # These scripts receive environmental variables named in the >>>>>>> "environment" subsection: >>>>>>> # SCANBD_DEVICE - device name (fixed string "dbus device" for >>>>>>> dbus notification) >>>>>>> # SCANBD_ACTION - "insert" or "remove", so one script can >>>>>>> be used. >>>>>>> # device_insert_script = "insert.script" >>>>>>> # device_remove_script = >>>>>>> >>>>>>> # scanbuttond_backends_dir sets the path where scanbd >>>>>>> looks for >>>>>>> the scanbuttond backends >>>>>>> # It can be defined as relative path, starting from the >>>>>>> scanbd >>>>>>> config directory or >>>>>>> # as an absolute path >>>>>>> # Default is <libdir>/scanbd/scanbutond/backends >>>>>>> # Example >>>>>>> # scanbuttond_backends_dir = >>>>>>> "/usr/local/lib/scanbd/scanbuttond/backends" >>>>>>> >>>>>>> # poll timeout in [ms] >>>>>>> # (for polling the devices) >>>>>>> timeout = 500 >>>>>>> pidfile = "/var/run/scanbd.pid" >>>>>>> # env-vars for the scripts >>>>>>> environment { >>>>>>> # pass the device label as below in this env-var >>>>>>> device = "SCANBD_DEVICE" >>>>>>> # pass the action label as below in this env-var >>>>>>> action = "SCANBD_ACTION" >>>>>>> } >>>>>>> >>>>>>> # function definitions >>>>>>> # values of the options are simply passed via env-vars >>>>>>> >>>>>>> function function_knob { >>>>>>> filter = "^message.*" >>>>>>> desc = "The value of the function knob / wheel / >>>>>>> selector" >>>>>>> env = "SCANBD_FUNCTION" >>>>>>> } >>>>>>> function function_mode { >>>>>>> filter = "^mode.*" >>>>>>> desc = "Color mode" >>>>>>> env = "SCANBD_FUNCTION_MODE" >>>>>>> } >>>>>>> >>>>>>> multiple_actions = true # allow multiple actions per >>>>>>> option (up >>>>>>> to the total amount of options) >>>>>>> >>>>>>> # action definitions >>>>>>> # if the filter matches and the value changes >>>>>>> # from from-value to to-value, >>>>>>> # <script> is executed >>>>>>> # <script> is the full pathname (do not include any >>>>>>> parameters) >>>>>>> # if parameters are needed, write a script >>>>>>> # since we can have only at most one action for >>>>>>> each option, the >>>>>>> action-script >>>>>>> # can use the function definition (see above) to distinguish >>>>>>> different tasks >>>>>>> # (e.g. use the env-var SCANBD_FUNCTION defined above) >>>>>>> action scan { >>>>>>> filter = "^scan.*" >>>>>>> numerical-trigger { >>>>>>> from-value = 1 >>>>>>> to-value = 0 >>>>>>> } >>>>>>> desc = "Scan to file" >>>>>>> # script must be an relative path starting from >>>>>>> scriptdir (see above), >>>>>>> # or an absolute pathname. >>>>>>> # It must contain the path to the action script >>>>>>> without >>>>>>> arguments >>>>>>> # Absolute path example: script = >>>>>>> "/some/path/foo.script >>>>>>> script = "test.script" >>>>>>> } >>>>>>> action email { >>>>>>> filter = "^email$" >>>>>>> string-trigger { >>>>>>> from-value = "" >>>>>>> to-value = "^email.*" >>>>>>> } >>>>>>> desc = "Scan to email" >>>>>>> # script must be an relative path starting from >>>>>>> scriptdir (see above), >>>>>>> # or an absolute pathname. >>>>>>> # It must contain the path to the action script >>>>>>> without >>>>>>> arguments >>>>>>> # Absolute path example: script = >>>>>>> "/some/path/foo.script >>>>>>> script = "test.script" >>>>>>> } >>>>>>> action copy { >>>>>>> filter = "^copy$" >>>>>>> string-trigger { >>>>>>> from-value = "" >>>>>>> to-value = "^copy.*" >>>>>>> } >>>>>>> desc = "Copy to printer" >>>>>>> # script must be an relative path starting from >>>>>>> scriptdir (see above), >>>>>>> # or an absolute pathname. >>>>>>> # It must contain the path to the action script >>>>>>> without >>>>>>> arguments >>>>>>> # Absolute path example: script = >>>>>>> "/some/path/foo.script >>>>>>> script = "test.script" >>>>>>> } >>>>>>> action preview { >>>>>>> filter = "^preview$" >>>>>>> numerical-trigger { >>>>>>> from-value = 1 >>>>>>> to-value = 0 >>>>>>> } >>>>>>> desc = "Preview" >>>>>>> # script must be an relative path starting from >>>>>>> scriptdir (see above), >>>>>>> # or an absolute pathname. >>>>>>> # It must contain the path to the action script >>>>>>> without >>>>>>> arguments >>>>>>> # Absolute path example: script = >>>>>>> "/some/path/foo.script >>>>>>> script = "test.script" >>>>>>> } >>>>>>> action globaltest { >>>>>>> filter = "^message.*" >>>>>>> desc = "Test (print all env vars)" >>>>>>> # script must be an relative path starting from >>>>>>> scriptdir (see above), >>>>>>> # or an absolute pathname. >>>>>>> # It must contain the path to the action script >>>>>>> without >>>>>>> arguments >>>>>>> # Absolute path example: script = >>>>>>> "/some/path/foo.script >>>>>>> script = "test.script" >>>>>>> } >>>>>>> } >>>>>>> >>>>>>> # include >>>>>>> # include another file at this point. This may only occur outside >>>>>>> general and devices blocks. >>>>>>> # an include statement may be relative to the direcory where >>>>>>> scanbd.conf >>>>>>> is located or absolute >>>>>>> # include("scanner.d/myscanner.conf") >>>>>>> # include("/my/long/path/myscanner.conf") >>>>>>> >>>>>>> # devices >>>>>>> # each device can have actions and functions, you can disable not >>>>>>> relevant devices >>>>>>> include(scanner.d/avision.conf) >>>>>>> include(scanner.d/fujitsu.conf) >>>>>>> include(scanner.d/hp.conf) >>>>>>> include(scanner.d/pixma.conf) >>>>>>> include(scanner.d/snapscan.conf) >>>>>>> include(scanner.d/canon.conf) >>>>>>> #include(scanner.d/plustek.conf) >>>>>>> >>>>>>> >>>>>>> I also commented out the include statements for the devices, tested >>>>>>> different sections for the options such as "preview", tried the >>>>>>> default >>>>>>> Ubuntu-Package for 16.04 as well as the newest version 1.5.0 of >>>>>>> scanbd. >>>>>>> >>>>>>> Syslog contains essentially the same output as scanbd -f -d7, no >>>>>>> events >>>>>>> registered at all on button press. Scanimage -A also gave no evidence >>>>>>> for the presence of scanner buttons. >>>>>>> >>>>>>> For me it seems that the problem might be the scanner button >>>>>>> options not >>>>>>> being recognized, strangely there are options "with no name" ?! >>>>>>> >>>>>>> Thanks very much for any hint ! >>>>>>> >>>>>>> >>>>>>> Regards, >>>>>>> >>>>>>> >>>>>>> Florian >>>>>>> >>>>>>> >>>>>>> >>>>> >>> >> >> > > > -- sane-devel mailing list: sane-devel@lists.alioth.debian.org http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/sane-devel Unsubscribe: Send mail with subject "unsubscribe your_password" to sane-devel-requ...@lists.alioth.debian.org