Skip to content

nanomad/openbarracuda

Repository files navigation

openbarracuda

Userspace daemon for the Razer Barracuda 2.4 wireless headset on Linux. No kernel driver required.

Features

  • Battery & charging monitoring via DBus (compatible with openrazer clients)
  • Connection detection with desktop notifications
  • PipeWire/PulseAudio sink management — auto-hides audio device when headset is off
  • WirePlumber fixes — correct headset icon and hides bogus S/PDIF profiles
  • TUI monitor for live register inspection (optional, requires textual)

Supported Devices

Device VID:PID Status
Razer Barracuda 2.4 (dongle) 1532:0584 Supported

Installation

Arch Linux

# Install AUR dependency
yay -S python-pulsectl

# Build and install
cd openbarracuda
makepkg -si

Manual

pip install .

# udev rule (hidraw access for logged-in user)
sudo cp install_files/udev/69-openbarracuda.rules /etc/udev/rules.d/
sudo udevadm control --reload-rules

# WirePlumber fixes (headset icon, hide S/PDIF)
sudo cp install_files/wireplumber/razer-barracuda.conf \
    /usr/share/alsa-card-profile/mixer/profile-sets/
mkdir -p ~/.config/wireplumber/wireplumber.conf.d/
cp install_files/wireplumber/50-openbarracuda.conf \
    ~/.config/wireplumber/wireplumber.conf.d/
systemctl --user restart wireplumber

# Replug the dongle, then start the daemon
systemctl --user enable --now openbarracuda.service

Usage

# Start the daemon
openbarracuda daemon

# Query status via CLI
openbarracuda status

# TUI monitor (requires python-textual)
openbarracuda monitor

DBus Interface

The daemon exposes an openrazer-compatible DBus interface:

org.openbarracuda /org/openbarracuda/device

  org.openbarracuda.device.misc:
    getDeviceType() -> s       # "headset"
    getDeviceName() -> s       # "Razer Barracuda 2.4"
    getSerial() -> s           # "IN2530D17XXXXXX"
    getFirmware() -> s         # "3.1.1.0"
    getDriverVersion() -> s    # "0.1.0"

  org.openbarracuda.device.power:
    getBattery() -> d          # 0-100 or -1
    isCharging() -> b
    Properties: Connected, Battery, Charging
    Signals: ConnectionChanged, BatteryChanged, ChargingChanged

How It Works

The Razer Barracuda 2.4 dongle exposes a vendor-defined HID interface (usage page 0xFF00) alongside the standard USB audio device. openbarracuda communicates with the dongle via hidraw using a custom "PA" protocol (magic bytes 0x50 0x41), matching the exact timing and command sequence used by Razer Synapse 4.

No kernel driver is needed — unlike openrazer, which requires an out-of-tree kernel module for devices that use USB control transfers, the Barracuda dongle uses interrupt transfers which are accessible from userspace via hidraw.

Architecture

protocol.py       HID PA protocol (bytes in/out, Synapse-matched timing)
headset.py        State machine (polls protocol, tracks state, fires callbacks)
dbus_service.py   DBus interface (openrazer-compatible method signatures)
audio.py          PipeWire/PulseAudio card profile management
daemon.py         Wiring layer (headset callbacks -> DBus + audio + notifications)
cli.py            CLI entry points

Related Projects

  • openrazer — Linux driver for Razer devices (kernel module + daemon). Does not support the Barracuda 2.4 yet (#2314).
  • Razer Synapse 4 — Windows-only official software

License

MIT

About

Userspace daemon for the Razer Barracuda 2.4 wireless headset on Linux — battery, connection, PipeWire integration

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors