Skip to main content

A unified library for controlling various radio devices (receivers and transceivers)

Project description

Radio Manager

A unified Python library for controlling various radio devices including receivers, scanners, and transceivers.

Supported Radios

Uniden

  • SDS200 - Digital scanning receiver (serial and network) ✓ Tested
  • BCD996P2 - Analog/digital scanner (serial) ✓ Tested
  • SDS100 - Digital scanning receiver (coming soon)
  • BCD536HP - Handheld scanner (coming soon)

Motorola

  • XPR4350 - UHF transceiver with GPIO control (planned)

Installation

Recommended: pipx (for CLI usage)

pipx is the recommended way to install command-line tools on Ubuntu 24.04+ and other modern Linux systems:

# Install pipx if you don't have it
sudo apt install pipx
pipx ensurepath

# Install radio-manager
pipx install /home/tomn2tsr/dev/personal/radio-manager

# Or for development (editable install)
pipx install -e /home/tomn2tsr/dev/personal/radio-manager

# Use the rmgr command anywhere
rmgr list-radios
rmgr set-volume 8

Local Development Installation (library usage)

For development or if you need to use it as a Python library:

cd radio-manager
python3 -m venv venv
source venv/bin/activate
pip install -e .

From PyPI (when available)

pipx install radio-manager  # For CLI usage
# or
pip install radio-manager   # For library usage in your own projects

Quick Start

  1. Create a radios.yaml file (see below)
  2. Call the rmgr command

Command Line Interface (rmgr)

The easiest way to control your radios is via the rmgr command:

# List configured radios
rmgr list-radios

# Control the default radio
rmgr set-volume 8
rmgr get-volume
rmgr status
rmgr reboot
rmgr stream-audio

# Or specify a specific radio
rmgr set-volume --radio bcd996p2 5
rmgr status --radio sds200_serial

Configuration File

Create a radios.yaml file in one of these locations (in priority order):

  1. ./radios.yaml (current directory)
  2. ~/.config/radio-manager/radios.yaml
  3. Or specify with --config /path/to/radios.yaml

Example radios.yaml:

# Optional: Set a default radio
default_radio: sds200_desk

radios:
  sds200_desk:
    type: sds200
    host: 192.168.1.23
    port: 50536

  bcd996p2:
    type: bcd996p2
    ser_port: /dev/ttyACM1
    baudrate: 115200

See radios.yaml.example for more examples.

Python Library

Uniden SDS200

Serial Connection

from radio_manager.uniden import SDS200

# Connect via USB/serial
scanner = SDS200({
    'ser_port': '/dev/ttyACM0',
    'baudrate': 115200
})

with scanner:
    # Get status
    status = scanner.get_status()
    print(f"Current channel: {status['channel']}")

    # Control volume
    scanner.volume = 15
    print(f"Volume set to: {scanner.volume}")

Network Connection

from radio_manager.uniden import SDS200

# Connect via network
scanner = SDS200({
    'host': '192.168.1.1',
    'port': 50536
})

with scanner:
    status = scanner.get_status()
    print(f"Scanner status: {status}")

Uniden BCD996P2

from radio_manager.uniden import BCD996P2

# Connect via USB/serial
scanner = BCD996P2({
    'ser_port': '/dev/ttyACM1',
    'baudrate': 115200
})

with scanner:
    # Get status
    status = scanner.get_status()
    print(f"Firmware: {status['firmware']}")
    print(f"Mode: {status['scanner_mode']}")

    # Control volume (0-15 for BCD996P2)
    scanner.volume = 8

Development Status

This library is in early alpha development. APIs may change.

License

MIT License - see LICENSE file for details

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

radio_manager-0.3.0.tar.gz (32.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

radio_manager-0.3.0-py3-none-any.whl (35.6 kB view details)

Uploaded Python 3

File details

Details for the file radio_manager-0.3.0.tar.gz.

File metadata

  • Download URL: radio_manager-0.3.0.tar.gz
  • Upload date:
  • Size: 32.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for radio_manager-0.3.0.tar.gz
Algorithm Hash digest
SHA256 1bfbb351017ae856cf7257c4baf2c767250fba6072ccaac7fee780ddde966dcc
MD5 b2a6dbde60a7b22c884acce2244f613e
BLAKE2b-256 8e29898b7d254b4144bdf4baa45a22bdbe2cd2eda395c12849eed8919d32c2aa

See more details on using hashes here.

File details

Details for the file radio_manager-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: radio_manager-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 35.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for radio_manager-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 60cdc8f9f33c0f7db7f9e204514dc4499b179e0dd120206cddfd7ff1d877e6c4
MD5 15d9ba452a04f1043846c634f2e5b06f
BLAKE2b-256 0d57dd01c16bae13b22b07a706b6c4786648d0bf51f99c7283a23e0f7a37d55d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page