iRidi for Sonos
A toolkit for creating control interfaces using the Sonos speaker system driver.
Documentation updated 01.01.2024
iRidi for Sonos is a driver for creating a Hi-Fi system control interface without scripts. A native driver is more familiar to integrators and makes settings easier to change.
The Sonos driver lets you:
- Work with devices in a group or individually,
- Create playlists and play radio,
- Control the player,
- Display all available artist, soundtrack, or radio station information in any convenient format.
Example: Sonos
Connection
To work with Sonos equipment in a project, you need to find the speaker system's IP address and enter it in the driver settings. Follow these steps:
- Connect the Sonos equipment. Its IP address is assigned automatically using DHCP.
- Download and run Sonos Controller for Sonos. It automatically scans the network, and the equipment appears under "Rooms".
- There are several ways to find the Sonos equipment's network settings:
3.1. On a PC.

3.2. In the mobile application.

3.3. By scanning the local network with dedicated software, such as Advanced Port Scanner.
The scan produces a device list. Select the required device. Sonos systems are identified as Sonos,inc. in the "Manufacturer" column.

Once you have identified the IP address, you can configure the equipment in iRidi Studio.
The router must not block UDP or multicast traffic for a connection to Sonos equipment.
Connecting streaming services
To play media from music streaming services:
- Open the official Sonos application;
- Add a music streaming service to the device using Manage > Service Settings > Add (sign-in to the music service is required). Added services appear in the Sonos account's service list, and all of the service's media becomes available in the official Sonos application;
- Select the required media and right-click it;
- In the context menu, select Add to Sonos Playlist or select Add to Sonos Favorites;
- Open i3 pro. The added media now appears in the project.
Working in iRidi
- Create a project and select "Add driver". Select "Sonos" in the list that appears and add it.
By default, the Sonos driver works with one device. To synchronize all Sonos devices, combine them into a group using the additional Sonos group.
For more information about working with native drivers, see here.
- Fill in the fields in the driver properties required for operation.
Driver properties

- Name is the driver name; do not change it in a finished interface;
- Driver Type provides information about the driver type;
- Protocol is the TCP data transmission protocol;
- Log Level is the logging level;
- Host is the equipment IP address;
- Port is the connection port (1443 by default).
Configuring commands and feedbacks

To control equipment, configure Commands and Feedbacks. To send a command, drag it onto a graphical item and specify the Value to send. To display feedback, drag the Feedback onto a graphical item and specify how to display its Value.
For more information about graphical items, see Graphical item types.
Commands

- Name - command name;
- Type - command type:
- Control - commands for equipment control;
- Selection - navigation commands:
Control
| Parameter | Value | Description |
|---|---|---|
| Play/Pause | Play or pause a track | — |
| Volume | Adjust the volume | 0-100 |
| Mute | Mute the sound | 1 - mute the sound 0 - unmute the sound |
| Relative volume | Adjust the volume relative to the current "Volume" feedback value | 0-100 |
| Next | Play the next track | Value |
| Previous song | Play the previous track | Value |
| Seek | Seek within a track | Value used on a Level item with Duration feedback |
| Seek relative | Seek relative to the current timeline position | Value A negative value in ms (e.g., -5000) seeks backward A positive value in ms (e.g., 25000) seeks forward |
| Group volume | Command for adjusting volume within a group (for multiple devices) | 0-100 |
| Group relative volume | Adjust group volume relative to the current "Volume" feedback value | 0-100 |
| Group mute | Mutes the group | 1 - unmute the group 0 - mute the group |
| Update state | Refresh feedback states | Value |
| Repeat | Repeat the playlist | 1 - enable playlist repeat 0 - disable playlist repeat |
| Repeat one | Repeat the current track | 1 - enable current track repeat 0 - disable current track repeat |
| Crossfade | Fade out the end of a track and gradually increase the volume at the start of the next one | True/False |
| Shuffle | Plays a random song | 1 - enable Shuffle 0 - disable Shuffle |
| Reset error | Command to reset the "Error status" feedback value | Value |
Selection
| Parameter | Value | Description |
|---|---|---|
| Explorer | Navigation command (implemented using Advanced List) | Value |
| Explorer back | Command to return to the previous folder/page (Advanced List) | Value |
| Explorer root | Command to return to the root page | Value |
| Queue | Command to select a track from the queue | Value |
| Clear queue | Command to remove the track list from the queue | Value |
Feedbacks

- Name - feedback name;
- Type - feedback type
- Control - equipment control feedback;
- List - playlist feedback.
For convenience, driver feedback channels are divided into categories by purpose.
Control
Control - control feedback.
| Parameter | Value | Description |
|---|---|---|
| Play | Current playback state (play/pause) | 1 - Play state 0 - Pause state |
| Player name | Player name | Value |
| Volume | Current volume | 0-100 |
| Mute | Mute parameter state | 1 - Mute is active 0 - Mute is inactive |
| Group name | Group name | Value |
| Group Volume | Current group volume | 0-100 |
| Group mute | Group mute parameter state | 1 - active 0 - inactive |
| Error | Error | Value |
| Playbackstate | Current player state | Play, Pause, Idle |
| Position millis | Current timeline position (ms) | Value |
| Is coordinator | Indicates the main device in the group | 1 - master device 0 - slave device |
| Error status | Displays the current error status | 1 - error detected 0 - no error detected The status is retained until the Reset error command |
Stream, Radio - stream feedback.
| Parameter | Value | Description |
|---|---|---|
| Container image | Display an image | Value |
| Container name | Radio station name | Value |
| Current show name | Show name | Value |
| Container type | Content type (usually Track) | Value |
| Container service | Service name | Value |
| Current stream info | Artist + track name | Value |
Indicators - command availability indicators.
| Parameter | Value | Description |
|---|---|---|
| Can skip | Play the next track | 1 - available 0 - unavailable |
| Can skip back | Play the previous track | 1 - available 0 - unavailable |
| Can seek | Seek within a track | 1 - available 0 - unavailable |
| Can pause | Pause | 1 - available 0 - unavailable |
| Can stop | Stop playback | 1 - available 0 - unavailable |
| Can repeat | Playlist repeat | 1 - available 0 - unavailable |
| Can repeat one | Track repeat | 1 - available 0 - unavailable |
| Can crossfade | Fade effect | 1 - available 0 - unavailable |
| Can shuffle | Shuffle | 1 - available 0 - unavailable |
Modes - playback modes.
| Parameter | Value | Description |
|---|---|---|
| Mode repeat | Playlist repeat | 1 - active 0 - inactive |
| Mode repeat one | Track repeat | 1 - active 0 - inactive |
| Mode crossfade | Fade mode | 1 - active 0 - inactive |
| Mode shuffle | Shuffle mode | 1 - active 0 - inactive |
Current track info - current track information.
| Parameter | Value | Description |
|---|---|---|
| Service | Playback service | Value |
| Album | Album name | Value |
| Type | Content type | Value |
| Image | Track artwork | Value |
| Artist | Artist | Value |
| Name | Track name | Value |
| Duration (ms) | Duration (ms) | Value |
| Time | Duration | Format 00:00:00 |
| Time passed | Elapsed time | Format 00:00:00 |
| Time remaining | Remaining time | Format 00:00:00 |
| Name/Artist/Stream | Combined value | Value |
| Album/Show | Album or show | Value |
Next track info - next track information.
| Parameter | Value | Description |
|---|---|---|
| Next track Service | Service | Value |
| Next track Album | Album | Value |
| Next track Type | Content type | Value |
| Next track Image | Artwork | Value |
| Next track Artist | Artist | Value |
| Next track Name | Track name | Value |
| Next track Duration (ms) | Duration (ms) | Value |
| Next track Time | Duration | Format 00:00:00 |
List
| Parameter | Value | Description |
|---|---|---|
| Explorer | Folders/playlists/services/radio stations/tracks | Value |
| Queue | Playback queue | Value |
Position millis. Displaying track duration on a Level item.
Dynamic track duration changes apply to a Level item.
To display artwork, bind the driver's Position millis feedback to the Max token of the Level item. Follow these steps:
-
Drag the Position millis feedback onto the required item.
-
Select "More...", then the parameter Max .

Image (Current). Displaying track artwork on an item.
To display the artwork of the current track, bind the driver's Image (Current) feedback to the Image token of the item (use the same method for radio station artwork). Follow these steps:
-
Drag the Image (Current) feedback onto the required item.
-
Select "More...", then State 1 , Image .

Some radio station/service images are not displayed due to an error in the Sonos protocol.
Is Coordinator. Devices working in a group.
The device role is indicated by the Is Coordinator feedback. A value of 0 means the device is in Slave mode; 1 means it is in Master mode.
Devices working in a group have two roles:
- Master - the main device that duplicates commands for the other devices in the group;
- Slave - a subordinate device that receives settings from the Master.
A value of 0 means the device is in Slave mode; 1 means it is in Master mode.
Update State. Refreshing feedback values
The Update State command clears feedback values and polls the Sonos device again to display current information. The driver and Sonos devices can occasionally become unsynchronized; use this command to restore synchronization.
Refreshes these feedback values: Service, Album, Type, Image, Artist, Name, Duration, Time passed, Time remaining, Duration (ms), Time.
Configuring Explorer
The "Explorer" popup displays folders/playlists/tracks. It also provides navigation and selection of playlists created using the native Sonos application.
-
To create the Explorer popup, draw an Advanced List item.
-
Create 3 "Templates" popups. Name them TplFavorite (to display the "Playlists" and "Favorites" folders), TplRoot (to display the contents of the "Playlists" folder), and TplPlayList (to display the contents of the "Favorite" folder). Create Label items on each popup as templates for displaying folders, playlist information, artwork, and track names.

Example of Label items drawn for the TplFavorite popup.
-
After creating the items, return to the Advanced List item.
-
Open the template settings by clicking "Template setting".

- Add the template popups. In the Code field, enter type, as shown in the figure.
- Double-click a template to configure it, then add labels. For the "TplFavorite" template, enter favorite in the Type field, then add the following labels with the required tokens: lbl.Name.Text; lbl.Type.Text; lbl.NextImage 1.State 1.Image.
After adding the labels, specify a Value for each. To enter a value in a Value row, click the row 3 times. Label Values:
- lbl.Name.Text - name
- lbl.Type.Text - description
- lbl.NextImage - imageUrl

- Configure the labels for the remaining "TplRoot" and "TplPlayList" templates in the same way.
For TplRoot, enter Directory in Type. Create the lbl.Name.Text label and enter name in Value.

TplPlayList, enter playlist in Type. Create the labels:
- lbl.Name.Text: enter name in Value.
- lblTrackCount: enter trackCount in Value.

- After configuring the labels and templates, bind the "Explorer" command and feedback to the Advanced List item.
To bind the command, select the Advanced List item, then click + next to the Press event in the Programming window.

In the window that opens, select Send tag and bind SelectItem -> Commands -> Explorer.

To bind the feedback, select the Advanced List item, then open Data source (next to Template setting). Select Driver -> Feedbacks -> Explorer. This completes the Explorer popup setup!

Configuring Queue
The "Queue" popup displays information about tracks in the current playback queue and lets you select a track from that queue.
- Create an Advanced List item. Create the TplQueue template to display information about tracks in the playback queue. It has the following labels:
- lblName
- lblType
- lblNextImage1
- Configure the template and labels.
Tpl.Queue , enter playlisttrack in the Type field. Create these labels:
- lbl.Name - enter name in the Value field;
- lblType - enter description in the Value field;
- lblNextImage 1 - enter imageUrl in the Value field.

- Drag the Queue command and feedback onto Advanced List.
Command binding:

Feedback binding:

Sonos group
The "Sonos groups" driver controls Sonos devices in a group.
- This driver supplements the Sonos speaker system driver and is not intended for standalone use in a project.
Driver properties
- Name - the driver name; do not change it in a completed interface;
- Driver Type provides information about the driver type;
- Protocol is the TCP data transmission protocol;
- Log Level - logging detail level.
Configuring commands and feedbacks

To control equipment, configure Commands and Feedbacks. To send a command, drag it onto a graphical item and specify the Value to send. To display feedback, drag the Feedback onto a graphical item and specify how to display its Value.
For more information about graphical items, see Graphical item types.
Commands
- Name is the command name;
- Type is the command type:
- Group - command to group devices;
- Ungroup - command to ungroup devices;
- Select - command to select devices for grouping.
Feedbacks
- Name - the status feedback name;
- Type - feedback type:
- Players - a list of the current device states (grouped or ungrouped).
Configuring Popup groups
The "Popup groups" popup lets you select devices from a list and group / ungroup them.
-
Create a popup (Popup groups) and add Advanced List to it.
-
Create 2 "Templates" popups. Name them TplPlayer (an item representing one device) and TplGroup (an item representing a group of devices). Create Label items on each popup as templates for group information (name, device count, and coordinator).
Example Label items drawn for the TplGroup popup:

Example Label items drawn for the TplPlayer popup:

-
After creating the items, return to the Advanced List item.
-
Open the template settings by clicking "Template setting".

- Add the template popups. In the Code field, enter type, as shown in the figure.
- Double-click a template to configure it, then add labels. For the "TplGroup" template, enter group in the Type field (for TplPlayer, Type = player ), then add the following labels with the required tokens: lbl.Name.Text, Selection.Value, lbl.Name 1.Value.
After adding the labels, set their Value fields. To edit a Value field, double-click the label row. Label values:
- lbl.Name.Text - name,
- Selection.Value - selected,
- lbl.Name 1.Value - coordinator.
- After configuring the labels and templates, bind the "Select" command to the Advanced List item.
To bind the command, select the Advanced List item, then click + next to the Release event in the Programming window.

In the window that opens, select Send tag and bind SelectItem -> Commands -> Select.

- Bind the Players feedback to the item. Select the Advanced List item, then open Data source (next to Template setting). Select Driver -> Feedbacks -> Players.

- Add 2 buttons to the popup for grouping and ungrouping devices. Drag the respective commands onto them: Group and Ungroup , sending any value to the channel.
