[sane-devel] Passing all scanner usage through local saned

Alexander Pevzner pzz at apevzner.com
Sat May 11 14:08:00 BST 2024


Hi, guys!

On 5/11/24 10:19, Till Kamppeter wrote:
>> One advantage to this is it would give us a path to support all TWAIN 
>> scanners on Linux via TWAIN Direct.  It would just be a matter of 
>> building a TWAIN Driect to eSCL in the same way.
> 
> For this we would need a Scanner Application which on its back side 
> speaks TWAIN Direct, and this running on Linux and ideally on any 
> operating system. We would ideally have the specification of TWAIN 
> Direct. Is this specification published? Or is it only available under 
> NDA for paying customers.Or do you think about reverse-engineering here, 
> as we have done with the many scanners with their proprietary protocols 
> do get SANE drivers for them? Reverse-engineering is principally 
> possible (we started eSCL this way, too) but always prone to 
> incompleteness and inaccuracy.

Regarding TWAIN Direct, I have few comments.

First of all, TWAIN Direct has nothing in common with the classical 
old-fashion TWAIN except that it is backed by the same organization.

The classical TWAIN is the scanner API standard, like SANE. Driver may 
implement any protocol under the hood, but if it implements the TWAIN 
API, it is compatible with all apps that can work with TWAIN drivers.

The TWAIN Direct is the, first of all, network protocol. It is similar 
to eSCL and WSD on its spirit, uses HTML as a transport and, as far as I 
remember, DNS-SD for discovery. Requests and responses are encoded in 
JSON (unlike eSCL and WSD; these are XML-based),

Specification is freely available, but it's quality, well, like WSD: 
many ambiguous places that needs experimenting.

In theory, TWAIN Direct can be one of the driverless protocols for 
scanner, like others already in use.

Practically, scanners that support TWAIN Direct in firmware are very 
rare things. So far I know only one such a device, Xerox D70n Scanner 
(https://www.xeroxscanners.com/en/us/products/item.asp?PN=D70N) but 
never seen it in real life.

If TWAIN Direct scanners will become more popular, I will consider 
adding support of this protocol into sane-airscan. Currently I even 
don't have a device for testing.

-- 

	Wishes, Alexander Pevzner (pzz at apevzner.com)




More information about the sane-devel mailing list