Hama myScan Linux driver tools: scan mode, frame decoding, stitching

UVC extension-unit control (mouse/scan mode, LEDs, exposure), JPEG header
fix and embedded laser record decoding, session recorder, and a stitcher
that combines laser dead reckoning with phase correlation and ECC refinement.
FINDINGS.md holds the reverse-engineered protocol and laser calibration.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
erik
2026-10-02 10:41:22 +00:00
co-authored by Claude Opus 5.5
commit e1c1012c1c
13 changed files with 1751 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
# myscan
Linux driver tools for the Hama myScan (00052343) scanner mouse, a Dacuda design
(USB 274f:c001: UVC MJPEG camera + HID mouse).
- `myscan/xu.py` — UVC extension-unit access: switch between mouse and scan mode, LEDs, exposure
- `myscan/frame.py` — fix the lying JPEG header and decode the per-frame sensor record (laser dx/dy)
- `myscan/stitch.py` — assemble frames into a page image (laser dead reckoning + image registration)
- `tools/record.py` — record a scan session: `python tools/record.py -d 25 -o scan_text`
- `tools/stitch.py` — stitch a recording: `python tools/stitch.py scan_text` -> `scan_text/page.png`
- `tools/probe.py` — log raw frames and HID reports side by side
- `tools/scantest.py` — minimal scan-mode test: grab frames, decode records, restore mouse mode
See [FINDINGS.md](FINDINGS.md) for the protocol and calibration notes.
Setup: `python -m venv .venv && .venv/bin/pip install -r requirements.txt`