<div dir="ltr">Hi Ralph,<div><br></div><div>Thanks for the replies. I had Claude compare the 1800 AFL with the three backends you mentioned, reading their source and the sane-mustek-sq113 HARDWARE.md.<br><br>The protocol write-up you asked for is already public: <a href="https://github.com/Pr0fB0ff/primefilm-1800afl/blob/main/docs/protocol.md">https://github.com/Pr0fB0ff/primefilm-1800afl/blob/main/docs/protocol.md</a><br><div><br></div><div>For the 1800 AFL, a new backend is the right eventual home, with the protocol document and an entry in unsupported.desc as the first step. I have an entry ready. Shall I open a merge request for it?<br><br>mustek_usb2 and sane-mustek-sq113: clearly related at the transport level, but not the same register file.<br><br>The same on both:<br><br>Open handshake 64 65 44 45 and close 64 65 16 17, through wValue 0x90.<br>wValue 0xB0 writes register/value pairs, and 0x07 reads a value back.<br>wValue 0x02 and 0x03 announce a bulk write and a bulk read, and 0xC0 is part of clearing the FIFO.<br>Status is multiplexed behind register 0x8B.<br>Different on the 1800 AFL:<br><br>bRequest is 0x0C for one byte and 0x04 for more, not 0x01, and wLength varies (no fixed 4 bytes with doubled pairs).<br>A read is selected with wValue 0xB0, not 0x04.<br>The bulk byte count goes in wIndex, with no size in registers 0x7C-0x7F.<br>USB 1.1 rather than USB 2.0.<br>The registers themselves. Register 0x90 sets the data format here (on the SQ113 it is lamp PWM), a scan starts with 0xBE rather than 0xF3/0xF4, the motor is at 0x80-0x89 rather than 0xE0-0xFE, RAM addresses are at 0xB0-0xB5 rather than 0xA0-0xA5, and banks go through 0x83 rather than 0x5F.<br>The front end looks like a Wolfson WM8196/WM8199 rather than an AD9826.<br>So I read it as a sibling of the SQ113, probably an older USB 1.1 part, with a framing layer that could be shared but scan code that could not. The name of the chip is still unknown. mustek_usb2 reads the string "ESCAN01" through status selectors 0x19-0x1F, so I tried those on my unit, and it does not identify itself that way. On this chip the selector goes in register 0x97, and selectors 0x10-0x1F only mirror 0x00-0x0F, so 0x19-0x1F return the same sensor and status bytes as 0x09-0x0F, with no string. That is one more small difference from the SQ113. Selectors 6 and 7 change between reads, which looks like a running counter.<br><br>pieusb: nothing in common beyond the bRequest values. It tunnels SCSI commands over IEEE-1284-style port writes, and the 1800 AFL has no SCSI layer. Its 05e3:0145 is, though, the ID the Pacific Image installer lists for the PF7250U.<br><br>Your 1800U and PF3600 Pro: these may be a different family from mine. Pacific Image's software splits into separate hardware libraries by model. The one for the PrimeFilm 1800U accepts only 05e3:0120 and talks to it with Genesys-style requests: bRequest 0x0C/0x04, wValue 0x83 to select a register, 0x85 to write it, 0x84 to read it, which are the constants in SANE's genesys/low.h. That comes from reading the software, as I have no 1800U to try it on. If your unit answers those requests, the genesys backend may be the closer starting point. It would also be a useful test of why your PF3600 Pro reports the same ID, whether by a wrong firmware load or by sharing the 1800U's electronics. My 1800 AFL stalls on those same requests.<br><br>Thanks,</div></div><div><br></div><div>Marcel + Clanker</div></div><br><div class="gmail_quote gmail_quote_container"><div dir="ltr" class="gmail_attr">On Sun, Nov 1, 2026 at 12:04 PM Ralph Little <<a href="mailto:skelband@gmail.com">skelband@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Hi,<br>
Further to my previous reply, we also have the mustek-usb2 backend that <br>
supports SQ113 chips which may be somewhat related.<br>
Someone recently posted here about another SQ113 based driver which you <br>
might also check out: <a href="https://gitlab.com/jayanderson0/sane-mustek-sq113" rel="noreferrer" target="_blank">https://gitlab.com/jayanderson0/sane-mustek-sq113</a><br>
<br>
Cheers,<br>
Ralph<br>
<br>
On 2026-11-01 11:34, Marcel Sereboff wrote:<br>
> Hello,<br>
> a<br>
> I while ago I bought a Pacific Image PrimeFilm 1800 AFL and got the <br>
> clanker working on building a driver for it. Things are going well and <br>
> I have something now that works, and handles greyscale at least as <br>
> well as what the factory wrote. This is a film scanner and I do not do <br>
> much color photography. Please let me know if this is useful to you <br>
> and if I can do more work with this machine to advance your project.<br>
><br>
> From the clanker...<br>
><br>
> Over the past weeks I have reverse engineered its protocol from the <br>
> vendor's Windows driver DLLs and checked each step on my unit. The <br>
> result is a working userspace driver in Python (pyusb/libusb). It <br>
> scans slides and whole film strips, feeding the strip frame by frame, <br>
> at 1800 dpi in 8 or 16 bits (12 of them significant). I would like to <br>
> make this useful to other owners and to SANE, and I'd welcome advice <br>
> on the best way to do that.<br>
><br>
> The device<br>
><br>
> USB 2770:0119, product string "AFL Film Scanner", USB 1.1 full speed, <br>
> vendor class, bulk IN 0x81, bulk OUT 0x02, interrupt IN 0x83.<br>
> The vendor's INF for this model (1800aflscan.inf) also lists <br>
> 2770:011a, 2770:011b, 05da:00cd and 1606:f000, which may be related units.<br>
> It uses the "SQ" ASIC stack from the vendor software (SQ_SCAN.DLL, <br>
> IO_PORT.DLL, FVC.DLL): a parallel-port-style (SPP/EPP) register <br>
> interface carried over USB vendor control transfers. It does not speak <br>
> the Genesys protocol (the register requests stall).<br>
> What works (checked on the hardware)<br>
><br>
> Open handshake, chip init, lamp, carriage moves, status and film sensors.<br>
> MCU commands: lens position, firmware version, film feed and eject.<br>
> 8- and 16-bit scans in colour and in a fast mono mode (one channel, <br>
> about twice the line rate), plus a 300 dpi preview mode.<br>
> Flat-field correction, front-end gain picked from open light or from <br>
> the film, and autofocus.<br>
> Strip transport: frames are placed closed-loop from the sprocket holes <br>
> and the gap between frames. I checked this along a whole uncut <br>
> 36-exposure roll, together with rewind and the end-of-strip detection.<br>
> Not done: colour negative handling (orange mask, gains), and testing <br>
> on any unit other than mine. Units seem to differ in feed slack, so <br>
> the strip feeding has deliberately wide tolerances.<br>
><br>
> What I can offer<br>
><br>
> A protocol write-up, also at the link below: the register map as far <br>
> as known, the scan setup sequences, the sensor and status bits, the <br>
> film feed commands, and a list of gotchas (for example, drive register <br>
> 0xCF must be 0x0C, or every line comes back as one flat signal). The <br>
> write-up comes from my own notes and live runs. It contains no vendor <br>
> code.<br>
> The Python driver, published at the link below (GPL-2.0-or-later).<br>
> Possibly, later, a SANE backend in C. The strip feeder seems to fit an <br>
> ADF-style source, one image per frame with scanimage --batch.<br>
> My questions<br>
><br>
> Would you prefer a new backend, or to start with a link to the <br>
> protocol notes and the external driver (for example, an entry in the <br>
> unsupported devices list)?<br>
> Is there an existing backend for this SQ / Faraday-bridge chip family <br>
> that I have missed, which this work could extend instead?<br>
> Is anyone else on the list using a PrimeFilm 1800 AFL or one of the <br>
> related IDs above? Testing on a second unit would help a lot.<br>
> Code and notes: <a href="https://github.com/Pr0fB0ff/primefilm-1800afl" rel="noreferrer" target="_blank">https://github.com/Pr0fB0ff/primefilm-1800afl</a><br>
><br>
> Thanks,<br>
><br>
> Marcel Sereboff + Clanker<br>
<br>
</blockquote></div>