| 1 |
.\" Automatically generated by Pandoc 2.7.2 |
| 2 |
.\" |
| 3 |
.TH "sane-hp5590" "5" "13 Jul 2008" "" "SANE Scanner Access Now Easy" |
| 4 |
.hy |
| 5 |
.SH NAME |
| 6 |
.PP |
| 7 |
sane-hp5590 - SANE backend for Hewlett-Packard |
| 8 |
4500C/4570C/5500C/5550C/5590/7650 Workgroup/Document scanners |
| 9 |
.SH DESCRIPTION |
| 10 |
.PP |
| 11 |
The |
| 12 |
.B sane-hp5590 |
| 13 |
library implements a SANE (Scanner Access Now Easy) backend that provides access |
| 14 |
to the following Hewlett-Packard Workgroup/Document scanners: |
| 15 |
.IP \[bu] 2 |
| 16 |
ScanJet 4500C |
| 17 |
.IP \[bu] 2 |
| 18 |
ScanJet 4570C |
| 19 |
.IP \[bu] 2 |
| 20 |
ScanJet 5500C |
| 21 |
.IP \[bu] 2 |
| 22 |
ScanJet 5550C |
| 23 |
.IP \[bu] 2 |
| 24 |
ScanJet 5590 |
| 25 |
.IP \[bu] 2 |
| 26 |
ScanJet 7650 |
| 27 |
.PP |
| 28 |
If you own a scanner other than the ones listed above that works with |
| 29 |
this backend, please let us know this by sending the scanner\[cq]s exact |
| 30 |
model name and the USB vendor and device ids (e.g.\ from |
| 31 |
.IR /sys/bus/usb/devices , |
| 32 |
.BR sane-find-scanner (1) |
| 33 |
or syslog) to us. |
| 34 |
Even if the scanner\[cq]s name is only slightly different from the |
| 35 |
models mentioned above, please let us know. |
| 36 |
.SH OPTIONS |
| 37 |
.PP |
| 38 |
The options the backend supports can either be selected through command |
| 39 |
line options to programs like |
| 40 |
.BR scanimage (1) |
| 41 |
or through GUI elements in |
| 42 |
.BR xscanimage (1) |
| 43 |
or |
| 44 |
.BR xsane (1). |
| 45 |
Valid command line options and their syntax can be listed by using: |
| 46 |
.IP |
| 47 |
.nf |
| 48 |
\f[I] |
| 49 |
scanimage --help -d hp5590:interface:device |
| 50 |
\f[R] |
| 51 |
.fi |
| 52 |
.PP |
| 53 |
where \f[I]interface\f[R] and \f[I]device\f[R] specify the device in |
| 54 |
question, as in the configuration file. |
| 55 |
Add |
| 56 |
.B --all-options |
| 57 |
to also list the hardware read-out options. |
| 58 |
The |
| 59 |
.B \-d |
| 60 |
parameter and its argument can be omitted to obtain information |
| 61 |
on the first scanner identified. |
| 62 |
.PP |
| 63 |
Use the command: |
| 64 |
.IP |
| 65 |
.nf |
| 66 |
\f[I] |
| 67 |
scanimage -L |
| 68 |
\f[R] |
| 69 |
.fi |
| 70 |
.PP |
| 71 |
to list all devices recognized by your SANE installation. |
| 72 |
.SH DEVICE SPECIFIC OPTIONS |
| 73 |
.TP |
| 74 |
.B -l \f[I]n\f[R] |
| 75 |
Top-left X position of scan area in \f[B]mm\f[R]. |
| 76 |
Allowed range: 0 .. |
| 77 |
215.889. |
| 78 |
.TP |
| 79 |
.B -t \f[I]n\f[R] |
| 80 |
Top-left Y position of scan area in \f[B]mm\f[R]. |
| 81 |
Allowed range: 0 .. |
| 82 |
297.699. |
| 83 |
.TP |
| 84 |
.B -x \f[I]n\f[R] |
| 85 |
X width of scan-area in \f[B]mm\f[R]. |
| 86 |
Allowed range: 0 .. |
| 87 |
215.889. |
| 88 |
.TP |
| 89 |
.B -y \f[I]n\f[R] |
| 90 |
Y height of scan-area in \f[B]mm\f[R]. |
| 91 |
Allowed range: 0 .. |
| 92 |
297.699. |
| 93 |
.PP |
| 94 |
By default, the maximum size will be scanned. |
| 95 |
.TP |
| 96 |
.B --mode \f[I]mode\f[R] |
| 97 |
Select color mode. |
| 98 |
\f[I]mode\f[R] must be one of: \[lq]Color\[rq], \[lq]Color (48 |
| 99 |
bits)\[rq], \[lq]Gray\[rq], \[lq]Lineart\[rq]. |
| 100 |
.RS |
| 101 |
.IP \[bu] 2 |
| 102 |
\[lq]Color\[rq] - Scanning is done with 3 * 8 bit RGB color values per |
| 103 |
pixel. |
| 104 |
.IP \[bu] 2 |
| 105 |
\[lq]Color (48 bits)\[rq] - Scanning is done with 3 * 16 bit RGB color |
| 106 |
values per pixel. |
| 107 |
.IP \[bu] 2 |
| 108 |
\[lq]Gray\[rq] - Scanning is done with 1 * 8 bit gray value per pixel. |
| 109 |
.IP \[bu] 2 |
| 110 |
\[lq]Lineart\[rq] - Scanning is done with 1 bit black and white value |
| 111 |
per pixel. |
| 112 |
.RE |
| 113 |
.TP |
| 114 |
.B --source \f[I]source\f[R] |
| 115 |
Select the source for scanning. |
| 116 |
\f[I]source\f[R] must be one of: \[lq]Flatbed\[rq], \[lq]ADF\[rq], |
| 117 |
\[lq]ADF Duplex\[rq], \[lq]TMA Slides\[rq], \[lq]TMA Negatives\[rq]. |
| 118 |
.RS |
| 119 |
.IP \[bu] 2 |
| 120 |
\[lq]Flatbed\[rq] - Scan document on the flat document glass. |
| 121 |
.IP \[bu] 2 |
| 122 |
\[lq]ADF\[rq] - Scan frontsides of documents with automatic document |
| 123 |
feeder. |
| 124 |
.IP \[bu] 2 |
| 125 |
\[lq]ADF Duplex\[rq] - Scan front- and backsides of documents with |
| 126 |
automatic document feeder. |
| 127 |
Note, the backside images must be rotated in a separate post process |
| 128 |
step. |
| 129 |
.IP \[bu] 2 |
| 130 |
\[lq]TMA Slides\[rq] - Slide scanning with transparent media adapter. |
| 131 |
(Not fully supported by hp5590 backend). |
| 132 |
.IP \[bu] 2 |
| 133 |
\[lq]TMA Negatives\[rq] - Negative film scanning with transparent media |
| 134 |
adapter. |
| 135 |
(Not fully supported by hp5590 backend). |
| 136 |
.RE |
| 137 |
.TP |
| 138 |
.B --resolution \f[I]res\f[R] |
| 139 |
Set the resolution of the scanned image in \f[B]dpi\f[R]. |
| 140 |
\f[I]res\f[R] must be one of: 100, 200, 300, 600, 1200, 2400. |
| 141 |
.PP |
| 142 |
Default settings: Lineart, Flatbed, 100dpi. |
| 143 |
.TP |
| 144 |
.B --extend-lamp-timeout[=yes|no] |
| 145 |
Extend lamp timeout period. |
| 146 |
no = 15 minutes, yes = 1 hour. |
| 147 |
(Default: no) |
| 148 |
.TP |
| 149 |
.B --wait-for-button[=yes|no] |
| 150 |
Wait for button press before scanning starts. |
| 151 |
(Default: no) |
| 152 |
.TP |
| 153 |
.B --preview[=yes|no] |
| 154 |
Request a preview-quality scan. |
| 155 |
(Default: no) |
| 156 |
.TP |
| 157 |
.B --hide-eop-pixel[=yes|no] |
| 158 |
Hide end-of-page indicator pixels and overwrite with color of next |
| 159 |
neighbor pixels. |
| 160 |
(Default: yes) |
| 161 |
.br |
| 162 |
The scanner uses the last pixel in every scan line for storing the |
| 163 |
end-of-page status. |
| 164 |
This is needed to detect the end of the document sheet when the |
| 165 |
automatic document feeder (ADF) is used. |
| 166 |
Unfortunately the end-of-page pixels are also generated in flatbed |
| 167 |
scans. |
| 168 |
It is recommended to hide these pixels. |
| 169 |
.TP |
| 170 |
.B --trailing-lines-mode \f[I]mode\f[R] |
| 171 |
Filling mode of trailing lines after end of page when automatic document |
| 172 |
feeder (ADF) is used. |
| 173 |
\f[I]mode\f[R] must be one of: \[lq]last\[rq], \[lq]raw\[rq], |
| 174 |
\[lq]raster\[rq], \[lq]white\[rq], \[lq]black\[rq], \[lq]color\[rq]. |
| 175 |
(Default: \[lq]last\[rq]) |
| 176 |
.RS |
| 177 |
.IP \[bu] 2 |
| 178 |
\[lq]last\[rq] = repeat the last scan line (recommended), |
| 179 |
.IP \[bu] 2 |
| 180 |
\[lq]raw\[rq] = read raw scan data (not recommended), |
| 181 |
.IP \[bu] 2 |
| 182 |
\[lq]raster\[rq] = generate black and white pixel pattern, |
| 183 |
.IP \[bu] 2 |
| 184 |
\[lq]white\[rq] = white pixels, |
| 185 |
.IP \[bu] 2 |
| 186 |
\[lq]black\[rq] = black pixels, |
| 187 |
.IP \[bu] 2 |
| 188 |
\[lq]color\[rq] = RGB or gray colored pixels (see next option). |
| 189 |
.RE |
| 190 |
.TP |
| 191 |
.B --trailing-lines-color \f[I]n\f[R] |
| 192 |
Set color value for filling trailing scan lines in trailing lines mode |
| 193 |
\[lq]color\[rq] (see previous option). |
| 194 |
(Default color: violet) |
| 195 |
.br |
| 196 |
The RGB color value must be specified and calculated as 65536 * r + 256 |
| 197 |
* g + b, with r, g, b being values in the range of 0 .. |
| 198 |
255. |
| 199 |
.SH READ OUT OPTIONS |
| 200 |
.PP |
| 201 |
The following options allow reading out the button state, counter value, |
| 202 |
color setting, and the state of document in ADF. |
| 203 |
This can be used to programmatically control corresponding scanner |
| 204 |
options like switching between \f[I]flatbed\f[R] and \f[I]ADF\f[R] mode, |
| 205 |
or triggering post processing tasks after scanning. |
| 206 |
.TP |
| 207 |
.B --button-pressed |
| 208 |
Get the id of the last button pressed. |
| 209 |
Id is one of \[lq]none\[rq], \[lq]power\[rq], \[lq]scan\[rq], |
| 210 |
\[lq]collect\[rq], \[lq]file\[rq], \[lq]email\[rq], \[lq]copy\[rq], |
| 211 |
\[lq]up\[rq], \[lq]down\[rq], \[lq]mode\[rq], \[lq]cancel\[rq]. |
| 212 |
.br |
| 213 |
The scanner stores the id of the last button pressed until it is read. |
| 214 |
After read out, the state is reset and subsequent readings will return |
| 215 |
\[lq]none\[rq]. |
| 216 |
|
| 217 |
.TP |
| 218 |
.B --color-led |
| 219 |
Get the state of the color LED indicators. |
| 220 |
The state is either \[lq]color\[rq] or \[lq]black_white\[rq]. |
| 221 |
|
| 222 |
.TP |
| 223 |
.B --counter-value |
| 224 |
Get the counter value as shown on LCD. |
| 225 |
The value is in the range of 1 .. |
| 226 |
99. |
| 227 |
|
| 228 |
.TP |
| 229 |
.B --doc-in-adf |
| 230 |
Get the state of the document-available indicator of the automatic |
| 231 |
document feeder (ADF). |
| 232 |
The state is either \[lq]yes\[rq] or \[lq]no\[rq]. |
| 233 |
|
| 234 |
.SH HINTS FOR USERS OF SCANBD |
| 235 |
.PP |
| 236 |
.BR scanbd (8) |
| 237 |
is a scanner button daemon, which can read scanner |
| 238 |
buttons and trigger scan actions. |
| 239 |
.PP |
| 240 |
Do not use the old |
| 241 |
.BR scanbuttond (8) |
| 242 |
interface with hp5590. |
| 243 |
It is outdated and shall not be used any more. |
| 244 |
The regular interface of |
| 245 |
.BR scanbd (8) |
| 246 |
is fully supported by the current version |
| 247 |
of the \f[I]hp5590\f[R] backend. |
| 248 |
.PP |
| 249 |
This example shows a minimum configuration file and the corresponding |
| 250 |
script file for |
| 251 |
.BR scanbd (8) |
| 252 |
to be included in |
| 253 |
.IR scanbd.conf . |
| 254 |
.IP \[bu] 2 |
| 255 |
.I hp5590.conf |
| 256 |
.IP |
| 257 |
.nf |
| 258 |
\f[I] |
| 259 |
device hp5590 { |
| 260 |
# Device matching |
| 261 |
filter = \[dq]\[ha]hp5590.*\[dq] |
| 262 |
desc = \[dq]HP5590 Scanner Family\[dq] |
| 263 |
|
| 264 |
# Read out counter value and store in environment variable. |
| 265 |
function function_lcd_counter { |
| 266 |
filter = \[dq]\[ha]counter-value.*\[dq] |
| 267 |
desc = \[dq]hp5590: LCD counter\[dq] |
| 268 |
env = \[dq]SCANBD_FUNCTION_LCD_COUNTER\[dq] |
| 269 |
} |
| 270 |
|
| 271 |
# Run scan script when button is pressed. |
| 272 |
action do-scan { |
| 273 |
filter = \[dq]\[ha]button-pressed.*\[dq] |
| 274 |
desc = \[dq]hp5590: Scan button pressed\[dq] |
| 275 |
script = \[dq]scan_action.script\[dq] |
| 276 |
string-trigger { |
| 277 |
from-value = \[dq]none\[dq] |
| 278 |
to-value = \[dq]scan\[dq] |
| 279 |
} |
| 280 |
} |
| 281 |
} |
| 282 |
\f[R] |
| 283 |
.fi |
| 284 |
.IP \[bu] 2 |
| 285 |
\f[B]scan_action.script\f[R] |
| 286 |
.IP |
| 287 |
.nf |
| 288 |
\f[I] |
| 289 |
#!/bin/bash |
| 290 |
echo device = $SCANBD_DEVICE |
| 291 |
echo action = $SCANBD_ACTION |
| 292 |
echo counter = $SCANBD_FUNCTION_LCD_COUNTER |
| 293 |
scanfile=\[dq]$HOME/tmp/scans/scan-$(date +%s).pnm\[dq] |
| 294 |
case $SCANBD_ACTION in |
| 295 |
do-scan) |
| 296 |
scanimage -d \[dq]$SCANBD_DEVICE\[dq] > \[dq]$scanfile\[dq] |
| 297 |
;; |
| 298 |
*) |
| 299 |
echo Warning: Unknown scanbd action: \[dq]$SCANBD_ACTION\[dq] |
| 300 |
;; |
| 301 |
esac |
| 302 |
\f[R] |
| 303 |
.fi |
| 304 |
.SH FILES |
| 305 |
.TP |
| 306 |
.B \f[I]\[at]LIBDIR\[at]/libsane-hp5590.a\f[R] |
| 307 |
The static library implementing this backend. |
| 308 |
.TP |
| 309 |
.B \f[I]\[at]LIBDIR\[at]/libsane-hp5590.so\f[R] |
| 310 |
The shared library implementing this backend (present on systems that |
| 311 |
support dynamic loading). |
| 312 |
.SH ENVIRONMENT |
| 313 |
.PP |
| 314 |
If the library was compiled with debug support enabled, this environment |
| 315 |
variable controls the debug level for this backend. |
| 316 |
.PP |
| 317 |
\f[B]SANE_DEBUG_HP5590\f[R] |
| 318 |
.PP |
| 319 |
Higher debug levels increase the verbosity of the output: |
| 320 |
.IP |
| 321 |
.nf |
| 322 |
\f[I] |
| 323 |
10 - generic processing |
| 324 |
20 - verbose backend messages |
| 325 |
40 - HP5590 high-level commands |
| 326 |
50 - HP5590 low-level (USB-in-USB) commands |
| 327 |
\f[R] |
| 328 |
.fi |
| 329 |
.TP |
| 330 |
.B Example: |
| 331 |
export SANE_DEBUG_HP5590=50 |
| 332 |
.SH SEE ALSO |
| 333 |
.PP |
| 334 |
.BR sane (7), |
| 335 |
.BR sane\-usb (5) |
| 336 |
.BR scanbd (8), |
| 337 |
.BR scanimage (1), |
| 338 |
.BR xscanimage (1), |
| 339 |
.BR xsane (1) |
| 340 |
|
| 341 |
.SH AUTHORS |
| 342 |
Ilia Sotnikov |
| 343 |
.RI < [email protected] >. |