A userspace firmware loader for webcams based on the Ricoh R5U87x chipset, found in various Sony VAIO and HP Pavilion laptop computers.
This version has been modernized to use libusb-1.0 and no longer requires GLib.
Important: This tool only uploads firmware to UVC-capable devices and then relies on the kernel's built-in
uvcvideodriver for video streaming. WDM devices (see the hardware table below) are not supported by this loader.
| USB ID | Type | Device | Notes |
|---|---|---|---|
05ca:1803 |
UVC | Flybook V5 | Firmware version unknown |
05ca:1810 |
UVC | HP Pavilion Webcam | |
05ca:1812 |
UVC | HP Pavilion Webcam (DV6502AU) | Does not require firmware |
05ca:1830 |
WDM | Sony VGP-VCC2 (VAIO SZ) | WDM: not supported |
05ca:1832 |
WDM | Sony VGP-VCC3 (VAIO UX) | WDM: not supported |
05ca:1833 |
WDM | Sony VGP-VCC2 (VAIO AR1) | WDM: not supported |
05ca:1834 |
WDM | Sony VGP-VCC2 (VAIO AR2) | WDM: not supported |
05ca:1835 |
UVC | Sony VGP-VCC5 (VAIO SZ) | |
05ca:1836 |
UVC | Sony VGP-VCC4 (VAIO FE) | |
05ca:1837 |
UVC | Sony VGP-VCC4 (VAIO FZ) | Camera mounted upside-down |
05ca:1839 |
UVC | Sony VGP-VCC6 (VAIO CR) | |
05ca:183a |
UVC | Sony VGP-VCC7 (VAIO SZ/TZ) | |
05ca:183b |
UVC | Sony VGP-VCC8 (VAIO FZ) | |
05ca:183e |
UVC | Sony VGP-VCC9 (VAIO FZ) | |
05ca:1841 |
UVC | Fujitsu F01 / Lifebook U810 | Camera mounted upside-down |
05ca:1870 |
WDM | HP Pavilion Webcam / HP Webcam 1000 | Two devices share this ID; not supported |
- Linux kernel with
uvcvideomodule (present in all modern distributions) - Firmware blobs (shipped in the
ucode/directory)
| Package | Debian/Ubuntu name | Fedora/RHEL name |
|---|---|---|
| GCC 9+ or Clang 11+ | build-essential |
gcc make |
| libusb-1.0 headers | libusb-1.0-0-dev |
libusbx-devel |
GLib is no longer required. The dependency on
libglib2.0-devhas been removed in this modernized version.
Install on Debian/Ubuntu:
sudo apt install build-essential libusb-1.0-0-dev
Install on Fedora/RHEL:
sudo dnf install gcc make libusbx-devel
make
This produces the loader binary and generates the udev rules file at
contrib/90-r5u87x-loader.rules.
To also build the fw-extract Intel HEX conversion utility:
make fw-extract
sudo make install
This installs:
r5u87x-loaderin/usr/sbin/r5u87x-loader- Firmware blobs in
/usr/lib/r5u87x/ucode/ - udev rules in
/etc/udev/rules.d/90-r5u87x-loader.rules
After installation, reload udev rules:
sudo udevadm control --reload-rules
sudo r5u87x-loader
After a successful upload, the camera will identify itself to the kernel
as a standard UVC device and /dev/video0 (or similar) will appear.
sudo r5u87x-loader --reload
sudo r5u87x-loader --force-clear
The path template supports %vid% and %pid% placeholders:
sudo r5u87x-loader --firmware=/my/path/r5u87x-%vid%-%pid%.fw
sudo r5u87x-loader --pretend
sudo r5u87x-loader --dump-ucode
This writes r5u87x-dump-<pid>-<vid>.bin to the current directory.
./fw-extract ucode/r5u87x-05ca-1836.fw
- The tool scans the USB bus for a recognized Ricoh device.
- It checks whether firmware has already been uploaded (persists across reboots but not across power cycles).
- If the firmware version does not match the expected version, the existing firmware is cleared.
- The firmware blob is transferred to the device using the Ricoh
vendor-specific USB command
0xa0. - The firmware is enabled with command
0xa1. - On cameras mounted upside-down (0x1837, 0x1841), horizontal and
vertical flip registers are written via command
0xc2. - Optionally, the
uvcvideokernel module is reloaded.
Installing the udev rules causes the loader to run automatically whenever the camera is connected or the system boots with the camera already attached.
To trigger the rules manually without rebooting:
sudo udevadm trigger --action=add --subsystem-match=usb
Any Linux kernel with uvcvideo support (present since kernel 2.6.26).
The loader itself is a userspace application and is not kernel-version
dependent.
-
WDM devices (
0x1830,0x1832,0x1833,0x1834,0x1870) are listed in the device table for informational purposes but are not supported by this loader. A separate kernel module (r5u870) is required for those devices. -
0x1870ambiguity: USB ID05ca:1870is shared by two distinct devices (HP Webcam 1000 and HP Pavilion dv1xxx). Distinguishing them requires reading the DMI product name, which is not yet implemented. Both entries are commented out in the device table. -
Power cycle behaviour: Firmware does not survive a complete power cycle. The udev rules handle re-upload on reconnect automatically.
- Copyright (c) 2008-2009 Alexander Hixon alex@alexhixon.com
- Copyright (c) 2026 J. A. Corbal jacorbal@gmail.com
These tools are licensed under the terms of the GNU General Public
License, version 2 or later. See the included file COPYING
for the full text.
The files located under the ucode directory were derived from
usbsnoop/sniffusb tracing of various Windows drivers, including some
named Mvc25u870.sys, 5U870CAP.sys, and R5U870FLx86.sys.
- Original project: Alexander Hixon
<alex@alexhixon.com>(2008–2009) - Loading routines based on Sam Revitch's original r5u870 kernel driver
fw-extract.cby Marcin Cieslak<saper@saper.info>(2009)- Modernized for
libusb-1.0by J. A. Corbal<jacorbal@gmail.com>(2026)
Huge kudos to Sam Revitch for writing the original r5u870 driver. Additional thanks to those who helped Sam develop the driver.
Many thanks to Willem van Engen for working on getting this included into Ubuntu, as well as helping me with my Makefile writing, writing the udev template and awk/sed scripts, and creating a Debian package.
Thanks to Gonzalo Álvarez for testing the 1812 driver and providing
usbsnoop traces of the device.
Thanks to Utz-Uwe Haus for getting the Sony VGP-VCC7 firmware extracted,
and providing a patch against the original r5u870 driver, and providing
the recode-fw.scm script.
Some friendly folk on the Ubuntu Forums for providing extracted version of firmwares and their associated version numbers.
Thanks to 'franz' for providing an updated version of 183b driver, and testing.
Thanks to Alex Hixon for the original project.