Sofabaton plugin

siclark
Posts: 2355
Joined: Tue Jun 13, 2017 5:08 am
Location: UK

Sofabaton plugin

Post by siclark »

Sharing a new plugin for the Sofabaton X2 universal remote hub. If you use a Sofabaton to
control your AV gear, this brings it into Indigo with bidirectional activity control and
real-time status updates.

What it does

The plugin connects to your Sofabaton X2 hub via MQTT and gives you full activity control
from Indigo:

- Hub device — a master status device that shows the currently active activity name in the
Indigo device list. Shows "off" when nothing's running, or the activity name like "Watch
TV" or "Listen to Heos".
- Activity devices — auto-created as relay (on/off) devices, one per activity. Turn on to
activate, turn off to deactivate. These update in real time when someone uses the physical
remote.
- Send key presses — volume, navigation, play/pause, channel, colour buttons and more. All
27 hardware remote keys are supported, either targeted at a specific activity or the
currently active one.
- Macros and favorites — trigger macro sequences and favorite shortcuts by key ID from
Indigo actions.
- mDNS discovery — Plugins → Sofabaton → Discover Hub finds your hub automatically, saves
the MAC address, connects to MQTT, and discovers all activities. No manual configuration
needed beyond the MQTT broker address.
- Device folder selection — choose which Indigo device folder new activity devices are
created in, keeping your device list organised.

Setup

1. You need an MQTT broker on your network. If you already run Mosquitto or the Indigo MQTT
Broker plugin, you're set.
2. In the Sofabaton app, go to Add Device → Home Assistant and enter your broker's
IP/port/credentials. This tells the hub to publish and subscribe to MQTT topics.
3. Download and double-click the .indigoPlugin bundle to install. Python dependencies
(paho-mqtt, zeroconf) are installed automatically on first load.
4. Go to Plugins → Sofabaton → Configure and enter your broker address.
5. Go to Plugins → Sofabaton → Discover Hub (mDNS). The plugin finds your hub, saves the
config, connects, and auto-creates devices for all your activities.

Actions

- Turn On / Turn Off — Activate or deactivate a specific activity
- Send Key Press — Send a remote key to a specific activity
- Send Key to Current Activity — Send a key to whatever activity is currently active
- Send Macro Key — Trigger a macro sequence by key ID
- Send Favorite Key — Trigger a favorite shortcut by key ID
- Refresh Activities — Re-query the hub for activities
- Stop All Activities — Turn off all active activities


All 27 hardware remote keys are available: Up, Down, Left, Right, OK, Back, Home, Menu,
Volume Up/Down, Channel Up/Down, Mute, Guide, Rewind, Play, Fast Forward, DVR, Pause, Exit,
Red, Green, Yellow, Blue, A, B, C.

Menu items

- Discover Hub (mDNS) — find and auto-configure your hub
- Refresh Activities — re-query the hub
- List Macro Keys / List Favorite Keys — dump key IDs to the Event Log (useful for setting
up actions)
- Dump Hub Config to Log — full config dump for debugging

Use cases

- Trigger "Watch TV" from a schedule, trigger, or action group
- Volume control from Indigo (e.g. "turn down the TV when the phone rings")
- Use the hub device state in triggers ("if Watch TV is active and it's after 11pm...")
- Stop all activities from a "Goodnight" action group
- Send play/pause from a motion sensor or button press

GitHub: https://github.com/simons-plugins/indigo-sofabaton

Return to “Sofabaton”