trougnouf/nubertctl
1
0
Fork
You've already forked nubertctl
0
A CLI tool to control Nubert bluetooth speakers (volume, source, power)
  • Python 70.3%
  • Shell 29.7%
Benoit Brummer (Trougnouf) dca746bafe fix: handle raw integer payloads in daemon socket handler
Prevent json.loads from parsing raw integers (like "50") into int type,
which would cause TypeError when checking "volume" in payload. Now
ensures payload is always a dict, converting raw integers to volume dict.
Generated by Mistral Vibe.
Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
2026年06月28日 12:34:33 +02:00
.gitignore Initial commit 2026年02月18日 22:43:15 +01:00
LICENSE Initial commit 2026年02月18日 22:43:15 +01:00
nubert-daemon@.service feat: resilient BLE daemon with auto-reconnect and persistent socket 2026年06月28日 10:29:31 +02:00
nubert-sync@.service feat: resilient BLE daemon with auto-reconnect and persistent socket 2026年06月28日 10:29:31 +02:00
nubert_pulseaudio_sync.sh stop aggressively intercepting every new audio stream 2026年06月28日 11:46:05 +02:00
nubertctl.py fix: handle raw integer payloads in daemon socket handler 2026年06月28日 12:34:33 +02:00
README.md feat: support name (because mac address is dynamic) 2026年03月17日 23:31:51 +01:00

nubertctl - Nubert Speaker Control (CLI)

An unofficial cross-platform Python utility to control Nubert speakers (X, XS, and A-Series) via Bluetooth Low Energy (BLE).

Features

  • Daemon Mode: Persistent BLE connection via Unix socket for instant response times.
  • PulseAudio/PipeWire Sync: Maps a virtual system volume slider to physical speaker gain.
  • Auto-Protocol Detection: Supports A600, X-Series, and XS-Series hardware.
  • Source & Power Control: Full control over inputs and standby states.
  • Name Resolution: Identifies your speaker dynamically by its Bluetooth name, circumventing rotating MAC address problems.

Installation

Arch Linux (AUR)

Install nubertctl-git. The package includes the CLI tool, the sync script, and systemd units.

# Example using yay
yay -S nubertctl-git

Manual Installation

  1. Dependencies:
    
    pip install bleak 
    # For PulseAudio/PipeWire sync:
    sudo pacman -S socat # Or your distro equivalent (e.g., apt install socat)
    

Usage

1. Find your Speaker

nubertctl --scan

Take note of the resulting Bluetooth name (e.g., nubert X-2 2272). While a MAC address is still perfectly acceptable, using the Bluetooth Name is highly recommended.

2. Desktop Integration (Linux)

The most robust way to use this on Linux is via the provided systemd services. This creates a persistent background connection so volume changes are instant.

(If your speaker name has spaces, wrap it in a systemd-escape subshell as shown below to ensure systemctl mounts the instances perfectly!)

  1. Enable the Daemon:
    systemctl --user enable --now nubert-daemon@$(systemd-escape "nubert X-2 2272").service
    
  2. Enable the Volume Sync:
    systemctl --user enable --now nubert-sync@$(systemd-escape "nubert X-2 2272").service
    

You will now see a "Nubert_Speaker_Remote" output in your system sound settings. Setting this as default allows your media keys to control the hardware speakers directly.

3. Manual CLI Commands

Set Volume (0-100):

nubertctl --address "nubert X-2 2272" --volume 45

Switch Source: aux, bluetooth, xlr, coax1, coax2, optical1, optical2, usb, port.

nubertctl --address "nubert X-2 2272" --source usb

Platform Notes

  • Linux: Uses socat and pactl for volume synchronization.
  • macOS: Use the UUID from --scan instead of a MAC address.
  • Windows: Pair the device in System Settings first.

Disclaimer

This is an unofficial community project. "Nubert" is a trademark of Nubert electronic GmbH. This tool is provided for interoperability purposes under EU Directive 2009/24/EC.