xref: /third_party/backends/backend/epsonds-io.h (revision 141cc406)
1/*
2 * epsonds-io.h - Epson ESC/I-2 driver, low level I/O.
3 *
4 * Copyright (C) 2015 Tower Technologies
5 * Author: Alessandro Zummo <a.zummo@towertech.it>
6 *
7 * This file is part of the SANE package.
8 *
9 * This program is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License as
11 * published by the Free Software Foundation, version 2.
12 */
13
14#ifndef epsonds_io_h
15#define epsonds_io_h
16
17#define USB_TIMEOUT (6 * 1000)
18#define USB_SHORT_TIMEOUT (1 * 800)
19
20size_t eds_send(epsonds_scanner *s, void *buf, size_t length, SANE_Status *status, size_t reply_len);
21size_t eds_recv(epsonds_scanner *s, void *buf, size_t length, SANE_Status *status);
22
23SANE_Status eds_txrx(epsonds_scanner *s, char *txbuf, size_t txlen,
24	char *rxbuf, size_t rxlen);
25
26SANE_Status eds_control(epsonds_scanner *s, void *buf, size_t buf_size);
27
28SANE_Status eds_fsy(epsonds_scanner *s);
29SANE_Status eds_fsx(epsonds_scanner *s);
30SANE_Status eds_lock(epsonds_scanner *s);
31
32#endif
33