Claude moves into hardware, not just code

A Red Hat engineer used Claude Code to troubleshoot a scanner and then a ThinkPad camera on Linux. His approach, published open source, shows how AI can help reverse-engineer hardware.

Claude Code is no longer just for writing software: Christian Schaller, engineering director at Red Hat, used it to get a stubborn scanner and camera working under Linux. In both cases, the agent compared the hardware's behavior with that of Windows drivers to suggest actionable fixes. The challenge goes beyond individual tinkering: this method could speed up device porting to Linux, without promising magic. The scanner, for its part, hadn’t received the free software world memo.

When the agent serves as a backup camera

Schaller’s first project involved a Plustek OpticFilm 8200i scanner advertised as compatible but equipped with a chipset that the Linux driver did not recognize. After several unsuccessful attempts, he ended up giving Claude Code a richer environment: a Windows driver to observe, USB captures, and a comparison system between the manufacturer’s implementation and his own code. As a result, he obtained a first usable scan within a few hours, then the infrared dust removal. Schaller then published the approach as an open source project, hw-harness, under the MIT license.

The principle is simple to describe but harder to implement. The tool runs the Windows driver in a KVM virtual machine, captures exchanges via usbmon on the Linux host, then lets the agent spot where the experimental driver diverges. Schaller also includes scripts to retrieve device descriptors, registry entries, ACPI tables, and INF files. The idea is not to produce a perfect driver in one go, but to arrive at code that a maintainer can integrate without rolling their eyes.

The driver that progresses faster than a tired human

Schaller also measured performance. In his single-image test, his driver completed a scan in 34.6 seconds, versus 54.4 seconds for the upstream SANE version, with the same detail level at 3,600 dpi. His code also handles infrared correction, exposure for dense negatives, as well as color and grayscale up to 7,200 dpi. Another developer had already added support for the new OpticFilm 8200i to SANE in September 2026, which reduces the interest of a competing branch in the long run, but not the demonstration’s value.

Schaller built around this work a GNOME application called Negative Vibes, written in Rust with Claude’s help. It preserves the original 16-bit data, including the infrared channel, then allows dust removal, image adjustment, and export to TIFF, JPEG, PNG, or DNG. Here, AI did not replace hardware expertise; it mainly accelerated reverse engineering. It’s less spectacular than a robot that understands everything, but much more useful.

A ThinkPad camera, then patches for the Linux kernel

The second use case is even more telling. On his Lenovo ThinkPad X1 Carbon Gen 14 Aura Edition, the internal camera produced images under Linux that were too dark, with very dark corners and a yellow-green cast. Schaller did not have USB traffic to analyze, as it was an internal MIPI sensor, not a standard USB device. He therefore provided Claude with Windows configuration files, registry entries, ACPI tables, and hardware properties, then added a reference USB webcam. By the end of the day, he had patches for the Linux kernel and libcamera.

The fixes address several points: a cropping selection bug, a poorly defined test pattern register, and an analog gain limit that caused about 1.8 stops of sensitivity loss. On the image processing side, Claude also helped correct the absence of lens-shading correction, responsible for corners about 2.7 stops darker than the center, as well as a calculation discrepancy on the black level. In low light, image brightness rose from 31.1 to 90.9, and colors moved closer to the reference webcam. The patches have not yet been merged but are under review at Nvidia and Red Hat.

What this method changes for hardware drivers

This sequence says something broader about the use of code agents. Their value is not only to write code faster; they also know how to explore a system from heterogeneous clues, compare traces, propose fixes, and retain context memory better than a human who has let three weeks pass. For teams maintaining drivers, hardware access layers, or low-level tools, this can reduce the time spent reconstructing a proprietary protocol. There remains a simple limit: a useful fix must still pass review, testing, and field validation.

This should interest system developers, Linux maintainers, and more broadly, anyone working on poorly documented devices. The model does not replace hardware, patience, or USB captures. It just puts them in order faster.

By the numbers

  • 34.6 seconds — scan duration with Schaller’s driver, single test, 2026.
  • 54.4 seconds — scan duration with upstream SANE driver, same test, 2026.
  • 1.8 stops — sensitivity gained on the camera side after analog gain correction.
  • 2.7 stops — brightness gap reduced in corners after lens-shading correction.
  • 7,200 dpi — maximum announced resolution for color and grayscale scanning.

To read