Proprietary binary protocol reversed and a Rust macOS driver shipped
A Reddit post about using Claude Code to reverse engineer a device protocol and ship a native macOS driver.
Credits
Earliest dated source:
The full story
A Canon PIXMA G3010 arrived without proper macOS drivers. A driver package from another model got printing working but not scanning, so for a long time the owner scanned with Canon's iPhone app and sent the files across with AirDrop.
Claude Code first assumed it could borrow from the SANE pixma backend used on Linux, but the printer's Wi-Fi scanning protocol turned out to be different and proprietary. Claude talked the owner through capturing the iPhone app's network traffic, worked out Canon's CHMP protocol from it, and wrote a Rust bridge daemon that translates between macOS's eSCL/AirScan and the printer. The owner reported what worked and what didn't and wrote no Rust themselves.
Printing was a separate problem: the G3010 is not on Apple's AirPrint list and Canon never shipped a macOS driver for it, although it speaks IPP on port 631, which newer macOS versions can use directly.
How it was done
Tools
Themes
Loading themes…
Sources
From a short post by the maker, so the details are as they tell them.
- Reddit: I used Claude Code to reverse-engineer a proprietary binary protocol and ship a macOS driver in RustReddit poster: _pdrgdsPosted
The owner's post in r/ClaudeCode explaining the scanner protocol work and the Rust bridge.
If it disappears: archived copy of Reddit: I used Claude Code to reverse-engineer a proprietary binary protocol and ship a macOS driver in Rust (opens in a new tab)
- Reddit: I used Claude Code to reverse-engineer a proprietary binary protocol and ship a macOS drivReddit poster: _pdrgdsPosted
If it disappears: archived copy of Reddit: I used Claude Code to reverse-engineer a proprietary binary protocol and ship a macOS driv (opens in a new tab)