Skip to main content

RGB2MQTT

PyPI Latest Release GitHub Code style: black Imports: isort

This is a Python script that will act as a brige between an OpenRGB server and an MQTT broker (like Mosquitto). Useful for if you want to control your PC RGB lights via Home Assistant for example.

This script is inspired by the original script from ghomasHudson and the fork from buttercheetah. This script is licensed under the MIT license, so feel free to try or change it yourself!

Installation

Use pip install rgb2mqtt to install the package. If you are running an older Python version (<3.11) you also need to install tomli: pip install tomli

Configuration

Configuration is stored in a config.toml file, see the config.toml.example file.

To generate a configuration file run the rgb2mqtt-config script after installing. To find the location of the saved config file see Logs and config location

Be aware that in the device map section, you need to list the name of the OpenRGB device exactly as key. To figure out which devices are supported by OpenRGB, see the notebooks/tryout_openrgb_sdk.ipynb file.

Logs and config location

The log file and config file will be written to a folder under:

  • Users\username\AppData\Roaming\rgb2mqtt\ when using Windows
  • /home/username/rgb2mqtt/ when using Linux

Usage

The run the script, use python src/rgb2mqtt/rgb2mqtt.py, or use rgb2mqtt-run after installing. All logging will be written to the log file, unless you use the verbose option (rgb2mqtt-run -v) in which case the logging is written to stdout.

If you want this script to autostart when your PC turns on (on Windows), use the rgb2mqtt-autostart command.

Release files for rgb2mqtt 1.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for rgb2mqtt 1.1.0
File Size Uploaded
rgb2mqtt-1.1.0.tar.gz 12.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for rgb2mqtt 1.1.0
File Interpreter ABI Platform
rgb2mqtt-1.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 21.7 kB

Release files / rgb2mqtt-1.1.0.tar.gz

Download URL rgb2mqtt-1.1.0.tar.gz
Size 12.7 kB
Tags Source
SHA-256 checksum
How to use checksums
bd2ba22561b20c2ee987d4eafeda87b977e8017d66bfdbbf7a059e29e870e57d
BLAKE2b-256 checksum
How to use checksums
87f6e36559e96ff50bf91e800d9e25e918dfdf6e1e12943fb4b4588b30f65083
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.12.1

Release files / rgb2mqtt-1.1.0-py3-none-any.whl

Download URL rgb2mqtt-1.1.0-py3-none-any.whl
Size 9.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
803abbe484d54beca24309fceac1f5c4557e9de70f2cf0491302ddbb2fccca92
BLAKE2b-256 checksum
How to use checksums
045e6d4b2747a4af845211ee0072e1d6a24a9ae7e3c3338aecba6cd984a7a6a3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.12.1

Release history Release notifications | RSS feed

This release

1.1.0 This release

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page