Add the ability to set the status (LED) light on a Sonos speaker

I’d like to be able to schedule the state of the status light of a Sonos speaker so that the LED can be turned off in the evening and turned on during the day.

Investigations led me to this blog post which demonstrates how to achieve the goal using a PowerShell script to call the Sonos API.

Further digging, revealed that the capability to read and set the Status Light via the Python package used by the Sonos integration already exists - see line 1275 in core.py of pysonos

So I’ve modified media_player.py so the status_light attribute is added to the Sonos media player devices and the set_option service can be used to turn on/off the status light.

Here’s a link to the pull request

However, I’m open to advice and suggestions for a better approach

Thanks

I know this may be a long shot, especially since this is an old topic, but I see that the code is merged, yet I can’t seem to find a way to change the LED status. I too have a “Night mode” in my home office/guest bedroom, where all the power lights from everything go off, except the Sonos light.

Therefor it’s now off by default, but it would be awesome if I could integrate this.

Go to the Sonos speaker’s device page and look at the bottom of the Configuration panel.

There are two additional controls and they are disabled by default. You simply need to enable it.

1 Like

Thank you, it’s that simple :sweat_smile: I completely missed that I could enable the unavailable entity.