HeadlinesBriefing favicon HeadlinesBriefing.com

Turning an e-ink display into a printer

Hacker News •
×

I planned to build an e-ink display and found the Xteink X3, which was fully programmable. It felt solid and flat, but loading content was tedious—I had to use its hotspot and a web uploader. I wanted it to act like paper, so I explored the Internet Printing Protocol (IPP).

IPP lets a computer query a printer's capabilities, submit documents, and check job status over HTTP. I advertised monochrome output at 300 dpi, one copy, one-sided, accepting Apple and PWG raster formats. The Mac then converted pages to pixels.

I declared A5 and Letter paper, stationery media, and a face-up output bin, naming it "penguin" with Bonjour for driverless discovery on macOS. The challenge was memory: a Letter page at 300 dpi is 8.4 MB uncompressed, but the X3 only had 400 KB of RAM. I used a transformation pipeline to decode, shrink, and dither rows directly to the display, avoiding a full second image.

The display's RAM served as the frame buffer, and I processed rows sequentially, showing bands like paper feeding. Each refresh took half a second, so I switched to showing the full page at once. I saved the final image as a BMP on the SD card using the existing screenshot writer.

This freed enough RAM for network buffers. Printing a manga page from Preview worked—it appeared on the e-ink screen in about a second, and the image stayed there. The project succeeded, turning a simple e-ink display into a functional printer.