Sony Audio smart home integration, free and open source

Sony sound bars, receivers and speakers: power, volume, source, sound mode, in real time, locally.
Control your Sony sound bars, AV receivers and wireless speakers from Gladys, on your local network: power, volume, mute, source, sound mode, night mode, voice enhancement and subwoofer level, updated in real time.
Developed without the hardware: feedback welcome. Tell what works and what does not on github.com/guim31/gladys-songpal/issues, with the model of your device.
This integration is not affiliated with, nor endorsed by, Sony.
Overview
The integration talks to the devices that work with the Sony Music Center app (formerly SongPal) through their local Audio Control API: sound bars (HT-A7000, HT-A5000, HT-ST5000, HT-ZF9, HT-XF9000, HT-NT5…), AV receivers (STR-DN1080, STR-AN1000, STR-AZ…), wireless speakers (SRS-X77, SRS-X99, SRS-ZR7…). No account, no cloud: everything stays on your network.
- Found by the search of the Discovery tab (no address to type).
- One Gladys device per product, with only the features it has.
- Real-time updates: a change made with the remote, the TV or the Sony app shows in Gladys within a second.
- Two dashboard widgets, a scene trigger and two scene actions.
Sony Bravia TVs use the same API but are left to the Sony Bravia TV integration.
Requirements
- Gladys 5.1.0 or later.
- The device connected to your network (Wi-Fi or Ethernet), set up once with the Sony Music Center app.
- Network standby on ("Network standby", "Quick start" or "Remote start", depending on the model): without it the device leaves the network in standby, and Gladys cannot turn it on nor see it.
- Gladys and the device on the same network: the search uses SSDP (UPnP), relayed by Gladys. Across subnets, type the address of the device in the configuration.
Installation and configuration
- In Gladys, open Integrations → Install from GitHub and install
https://github.com/guim31/gladys-songpal(or install Sony Audio from the store). - Turn your device on (not in standby) so that it gives its sources and sound settings.
- Open the Discovery tab of the integration and start a search. Each device found shows with its features: add it to Gladys.
- Optional, in Configuration:
- Addresses (optional): only for a device the search does not find, its IP address
(several separated by commas, e.g.
192.168.1.30, 192.168.1.31). Give it a fixed address in your router. - Refresh interval: how often a device is read when it cannot send its changes (30 seconds by default).
- Volume step of the widget: how much the Volume − and Volume + buttons change the volume.
- Language of the feature names: the names given to the features of a new device, and the language of the messages (French by default).
- Addresses (optional): only for a device the search does not find, its IP address
(several separated by commas, e.g.
- Test the connection reads every known device and tells what it finds: on or in standby, source, volume, and whether live updates work.
Devices and features
Each product is one device, identified by its MAC address (a new IP address given by your router keeps the same device: search again, it is found at its new address). Only the features the device has are created:
| Feature | Gladys type | What it does |
|---|---|---|
| Power | switch (on/off) | On / standby. |
| Volume | music volume | The volume, in the units of the device (often 0 to 50, 0 to 74 on a receiver). |
| Mute | switch (on/off) | Mute on / off. |
| Source | list | The inputs of the device (HDMI, TV, optical, analog, Bluetooth…), with the names set on it. "Other (network, app)" while Spotify, Chromecast or USB plays. |
| Sound mode | list | The sound fields of the device (Standard, Movie, Music…), or the equalizer presets of a speaker. |
| Night mode | switch (on/off) | Night mode of a sound bar. |
| Voice enhancement | switch, or list | On/off, or the levels (Type 1, 2, 3) of the older sound bars. |
| Subwoofer level | dimmer | The level of the subwoofer, within the bounds of the device (in 0.5 dB steps on a receiver). |
| Play, Pause, Previous, Next | music buttons | On a network or USB source only: an input (HDMI, TV) plays whatever its device sends. |
| Playback | music playback state | Playing or paused, for the Music box of the dashboard. |
Choosing a source while the device is in standby turns it on first. A receiver is controlled on its main zone.
Widgets
- Sony Audio remote: the device and its state, its source, sound mode and volume, with four buttons: Turn on (or Standby), Volume −, Volume + and Mute (its icon is a check mark while muted).
- Sony Audio sources: four favorite sources in one tap, the device turned on if needed. Type
their names in the widget settings (e.g.
TV,HDMI 1,Bluetooth); empty, the first connected inputs. The source in use has a check mark.
Choose the device in the settings of each widget (the first one otherwise).
Scene trigger
Sony Audio: source changed: the input in use changed, whatever changed it: the TV over HDMI (turning the TV on often switches the sound bar to it), a console, the remote, the Sony app or Gladys. Turning the device on counts when it lands on another source than the last one.
- Filters: the device, and the new source, written exactly as in the source list of the device
(e.g.
HDMI 1; empty: any source). - Variables: the device name, the new source, the previous source.
Scene actions
- Sony Audio: choose a source: by its name as the device shows it (
TV,HDMI 1,Bluetooth; case and spaces do not matter). Turns the device on first if needed. Returns the source chosen. - Sony Audio: set the sound: in one step, the sound mode by its name (
Movie,Music), night mode and voice enhancement (on, off or unchanged), and the volume. Turns the device on first if needed. Returns the sound mode and the volume.
Scene examples
- Movie night: when the "Movie" scene runs, Sony Audio: choose a source
TV, then Sony Audio: set the sound withMovie, voice enhancement on and volume 18; dim the lights. - Quiet at night: every day at 22:00, if the sound bar is on, set Night mode on and the Subwoofer level down.
- Console time: with Sony Audio: source changed filtered on
HDMI 2, turn on the lamp of the TV cabinet and send a message "The console is on".
Troubleshooting
- The search finds nothing: check that the device is on the same network as Gladys, with network standby on, and that it shows in the Sony Music Center app. Your router may drop multicast between Wi-Fi and Ethernet: type the address in Addresses (optional).
- "does not answer (unplugged, or network standby off)": the device left the network. Turn on network standby in its settings. Its Gladys device stays, its power shows off until it answers.
- No live updates (the test says "live updates off"): the device does not accept the WebSocket connection; it is read at the refresh interval instead. Nothing to change.
- A source or a sound mode is missing: the lists are those the device gives when on. Turn it on, then start a search again: the lists of an added device are updated without touching it.
- A feature appears after an update: a device added while in standby had no sound settings yet; the Discovery tab proposes to update it.
- Logs: the integration writes little (start, devices lost and back, user actions). For more,
set
LOG_LEVEL=debugon the integration.
Limits
- Developed without the hardware: built from the Sony Audio Control API reference and the open-source projects that use it. Some models may name their settings differently.
- The device must stay on the network in standby to be turned on from Gladys (no Wake-on-LAN).
- Only the main zone of a receiver; no multi-room groups, no presets, no browsing of the network services, no equalizer bands.
- Play and pause depend on the source: an HDMI or TV input cannot be paused from the sound bar.
- The device is read at most every 10 seconds when it cannot notify, every 5 minutes otherwise; the API is local, without quota.
- Bravia TVs are left to the Sony Bravia TV integration.
Configuration settings
These are the settings Sony Audio asks for in its configuration screen in Gladys.
| Setting | Type | Required | Description |
|---|---|---|---|
| Your Sony audio devices | section | No | Sound bars, receivers and speakers that work with the Sony Music Center app (formerly SongPal). Connect them to your network, turn on network standby ("Network standby" or "Quick start") so they can be turned on from Gladys, then search in the Discovery tab of this integration. |
| Addresses (optional) | string | No | Only for a device the search does not find: its IP address, several separated by commas. Give it a fixed address in your router. |
| Options | section | No | The devices send their changes as they happen. When they cannot, they are read at this interval. |
| Refresh interval | select | No | |
| Volume step of the widget | select | No | How much the Volume − and Volume + buttons change the volume. |
| Language of the feature names | select | No | Used for the names of the features of a new device, and the messages of the integration. |
How to install Sony Audio in Gladys
- In Gladys, open Integrations: Sony Audio appears in the catalog, next to the native integrations, with a community badge.
- Click Install. Gladys pulls the Docker image (
ghcr.io/guim31/gladys-songpal:1.0.1), starts it in a sandbox isolated from the core, and generates the integration's interface (devices, discovery and configuration). - Open the Configuration screen of the integration, fill in the settings, and save.
- You can also install it directly from its repository URL: https://github.com/guim31/gladys-songpal.
Sony Audio requires Gladys >=5.1.0. The catalog inside Gladys refreshes every hour, so a new version becomes available at most one hour after its release.
Not running Gladys yet? It is free and open source: follow the installation guide to get started.
About external integrations
Sony Audio is an external integration: a community integration packaged as a Docker container and published on GitHub, that Gladys installs in one click and runs in a sandbox isolated from its core. It is published and maintained by guim31, not by the Gladys core team.
- Browse all integrations, native and community
- Build and publish your own external integration
- Source code on GitHub — source of this documentation