1. 08 Jun, 2021 1 commit
    • Wolfram Sang's avatar
      treewide: use SANE_CURRENT_* macros consistently · eb42ad08
      Wolfram Sang authored
      Backends use a mixture of SANE_CURRENT_{MAJOR | MINOR} and V_{MAJOR |
      MINOR} with all kind of permutations. I was confused by this and one
      comment in pieusb.c tells me I was not alone. Some items in old
      changelogs suggest to use the SANE_CURRENT_ macros in backends, so let's
      switch to do that with the exception of net.c and dll.c. Done with:
      $ find backend -name '*.[ch]' | xargs sed -i '/nearly every/ ! { s/\<V_M/SANE_CURRENT_M/g }'
      $ git checkout backend/net.c backend/dll.c
      And manually removing the comment from pieusb.c. Everything still builds
  2. 22 Feb, 2021 1 commit
    • Giovanni Cappellotto's avatar
      Add function to debug avision command · 325c7750
      Giovanni Cappellotto authored
      Define a new enum that contains Avision data type codes and use those instead
      of pure values. I also added a couple of helper functions for debugging the
      command operation and data type code if read or send.
  3. 12 Feb, 2021 1 commit
  4. 20 Dec, 2020 2 commits
  5. 28 Sep, 2020 1 commit
  6. 29 Aug, 2020 1 commit
  7. 24 Aug, 2020 1 commit
  8. 10 Aug, 2020 1 commit
  9. 26 Jul, 2020 19 commits
  10. 03 Oct, 2019 1 commit
  11. 04 May, 2019 1 commit
  12. 28 Oct, 2018 1 commit
    • Michael Niewoehner's avatar
      backend/avision: fix thread cancellation · c16ff3ff
      Michael Niewoehner authored
      sigprocmask does not work for threads but only for forked processes.
      Even though a thread-safe version, pthread_sigmask, we do not use it
      since using singals with threads is a bad practice. Instead implement
      pthread's own cancellation method. Because sane_read blocks when
      reader_process is terminated, read_fds is closed and invalidated to
      make sane_read abort read and return gracefully.
  13. 29 Sep, 2018 1 commit
  14. 15 Jul, 2017 1 commit
    • Olaf Meeuwissen's avatar
      SANE_Pid: Fix [-Wint-conversion] issues · df1aba21
      Olaf Meeuwissen authored
      Not all pthreads implementations use an integer type for pthread_t.
      As a matter of fact, POSIX has explicitly withdrawn the requirement
      that it must be an arithmatic type.
      The musl C library uses a `struct __pthread *` which triggered the
      warnings.  As of this change, sanei_thread.h works around this by
      providing two new macros to help keep this issue out of sight.  All
      backends have been changed to use these macros.
  15. 26 Jun, 2017 2 commits
  16. 29 May, 2017 1 commit
  17. 16 Dec, 2016 3 commits
    • Dave Platt's avatar
      avision.c: abort "wait for light" loop if interrupted · 755e829c
      Dave Platt authored
      Adds a "cancelled" flag to the Avision device structure, cleared
      in sane_start() and set in sane_cancel().  Test this flag in
      wait_4_light() and bail out of the 90-second "wait for the
      light to warm up" loop if the scan is cancelled.
    • Dave Platt's avatar
      avision.c: Recognize "backlight on" status · 28963459
      Dave Platt authored
      Avision scanners can return an additional light-status value meaning
      "Transparent Media Adapter back-light is on".  Accept this as
      equivalent to "on" during the lamp-warmup check prior to starting a
      scan.  Re-check the light status after sending the window command, as
      the light selection might have been changed and a further warm-up
      may be required.
    • Dave Platt's avatar
      avision.c: Add "skip-adf" option · 6585b6f6
      Dave Platt authored
      The code which tries aggressively to reset/initialize HP 82xx/83xx
      Automatic Document Feeders doesn't work well if there's no ADF attached,
      because the scanner reports a non-zero ADF model type in this case.
      The retry code makes several attempts to initialize the ADF, and then
      bails out with an "Operation not supported" error.
      Add a new "option skip-adf" which will cause the backend to believe
      the "ADF not present" status if that's what the scanner reports.
      Fixes #313751
  18. 27 Dec, 2015 1 commit