scheduler-card
scheduler-card copied to clipboard
Support Sonos speakers as media_player
Checklist
- [X] I checked for similar existing requests (both open and closed) before posting.
- [X] My request is generic, other users may benefit from it too.
- [X] I will participate in further discussion about this feature and can test it (if requested) once it's done.
Proposal
There was 4 years ago a bug open for the same thing #155 I understand that without having access to these devices it's hard to see what is possible and what needs to be done. There is an official integration with HA https://www.home-assistant.io/integrations/sonos. I'm not sure if you are something with it, but I exported a json of one of the sonos speakers their device info. I removed a few unrelated other integrations it showed and redacted some internal IP's. but I've put it in Additional Info.
If there are things that I can do for you on the installation itself, or test something, please ask. Hopefully I can give you enough details so you have the possibility to make this possible.
Additional info
{ "home_assistant": { "installation_type": "Home Assistant OS", "version": "2024.9.2", "dev": false, "hassio": true, "virtualenv": false, "python_version": "3.12.4", "docker": true, "arch": "x86_64", "timezone": "Europe/Brussels", "os_name": "Linux", "os_version": "6.6.46-haos", "supervisor": "2024.09.1", "host_os": "Home Assistant OS 13.1", "docker_version": "26.1.4", "chassis": "vm", "run_as_root": true }, "custom_components": { "scheduler": { "documentation": "https://github.com/nielsfaber/scheduler-component", "version": "v0.0.0", "requirements": [] }, "hacs": { "documentation": "https://hacs.xyz/docs/configuration/start", "version": "2.0.1", "requirements": [ "aiogithubapi>=22.10.1" ] } }, "integration_manifest": { "domain": "sonos", "name": "Sonos", "after_dependencies": [ "plex", "spotify", "zeroconf", "media_source" ], "codeowners": [ "jjlawren", "peterager" ], "config_flow": true, "dependencies": [ "ssdp" ], "documentation": "https://www.home-assistant.io/integrations/sonos", "iot_class": "local_push", "loggers": [ "soco" ], "requirements": [ "soco==0.30.4", "sonos-websocket==0.1.3" ], "ssdp": [ { "st": "urn:schemas-upnp-org:device:ZonePlayer:1" } ], "zeroconf": [ "_sonos._tcp.local." ], "is_built_in": true }, "setup_times": { "null": { "setup": 7.213093340396881e-05 }, "70c13c4b53b082ff0af807a309967ed5": { "wait_import_platforms": -2.1568876849487424, "config_entry_setup": 2.161036165896803 } }, "data": { "available": true, "battery_info": {}, "hardware_version": "1.34.3.9-2.2", "household_id": "Sonos_pVvvtu1zS1Qf4WptTWaPmA1CvW", "is_coordinator": true, "model_name": "SYMFONISK Bookshelf", "model_number": "S33", "software_version": "80.1-56190", "sonos_group_entities": [ "media_player.sonos_ouders" ], "subscription_address": "[internalHAIP]:1400", "subscriptions_failed": false, "version": "16.3.3", "zone_name": "Slaapkamer", "_group_members_missing": [], "_last_activity": 2611977.772848165, "_last_event_cache": { "ContentDirectory": { "system_update_id": "5", "container_update_i_ds": "R:0,2,FV:2,2", "share_index_in_progress": "0", "share_index_last_error": null, "favorites_update_id": "RINCON_38420B9DBCD001400,51", "radio_favorites_update_id": "RINCON_38420B9DBCD001400,51", "radio_location_update_id": "RINCON_7828CAB4535C01400,1216", "saved_queues_update_id": "RINCON_38420B9DB9FA01400,1", "share_list_update_id": "RINCON_7828CAB4535C01400,93" }, "AlarmClock": { "time_zone": "ffc40a000503000003000502ffc4", "time_server": "0.sonostime.pool.ntp.org,1.sonostime.pool.ntp.org,2.sonostime.pool.ntp.org,3.sonostime.pool.ntp.org", "time_generation": "20000001", "alarm_list_version": "RINCON_38420B9DBCD001400:29", "time_format": "INV", "date_format": "INV", "daily_index_refresh_time": "02:00:00" }, "RenderingControl": { "volume": { "Master": "10", "LF": "100", "RF": "100" } }, "AVTransport": { "transport_state": "STOPPED", "current_play_mode": "NORMAL", "current_crossfade_mode": "0", "number_of_tracks": "4", "current_track": "1", "current_section": "0", "current_track_uri": "aac://http://vrt.streamabc.net/vrt-stubrutijdloze-aac-128-6442755?sABC=66rrqs29%230%23o6qq9p3p6q03r2oo8861982sqrpr47s2%23gharva&aw_0_1st.playerid=tunein&amsparams=playerid:tunein;skey:1726930729", "current_track_duration": "0:00:00", "current_track_meta_data": { "title": "", "parent_id": "-1", "item_id": "-1", "restricted": true, "resources": [ { "_type": "<class 'soco.data_structures.DidlResource'>", "repr": "<DidlResource 'x-sonosapi-stream:tunein%3a95991?sid=303&flags=8232&sn=3' at 0x7f94ee2d9ac0>" } ], "desc": null, "stream_content": "", "radio_show": "", "album_art_uri": "/getaa?s=1&u=x-sonosapi-stream%3atunein%253a95991%3fsid%3d303%26flags%3d8232%26sn%3d3" }, "next_track_uri": "", "next_track_meta_data": "", "enqueued_transport_uri": "x-sonosapi-stream:tunein%3a95991?sid=303&flags=8232&sn=3", "enqueued_transport_uri_meta_data": { "title": "VRT De Tijdloze", "parent_id": "-1", "item_id": "-1", "restricted": true, "resources": [], "desc": "SA_RINCON77575_X#Svc77575-6f34ce0b-Token" }, "sleep_timer_generation": "0" }, "DeviceProperties": { "zone_name": "Slaapkamer", "icon": null, "configuration": "1", "invisible": "0", "wireless_mode": "1", "wireless_leaf_only": "0", "channel_freq": "2412", "behind_wifi_extender": "0", "wifi_enabled": "1", "eth_link": "0", "settings_replication_state": "RINCON_38420B9DBCD001400,51,RINCON_FFFFFFFFFFFF99999,0,RINCON_7828CAB4535C01400,1,RINCON_7828CAB4535C01400,93,RINCON_7828CAB4535C01400,1216,RINCON_38420B9DBCD001400,35,RINCON_38420B9DBCD001400,1261,RINCON_FFFFFFFFFFFF99999,0,RINCON_38420B9DB9FA01400,9,RINCON_38420B9DB9FA01400,0,RINCON_7828CAB450E401400,36,RINCON_7828CAB4535C01400,2209,RINCON_7828CAB44BC801400,7,RINCON_7828CAB4535C01400,45,RINCON_38420B9DB9FA01400,0,RINCON_7828CAB4535C01400,119,RINCON_38420B9DB9FA01400,517,RINCON_38420B9DB9FA01400,0", "secure_reg_state": "3", "is_idle": "1", "more_info": "TargetRoomName:Slaapkamer", "channel_map_set": null, "active_zone_id": null, "ht_sat_chan_map_set": null, "ht_bonded_zone_commit_state": "0", "orientation": "0", "last_changed_play_state": "STOPPED,,,", "available_room_calibration": "trueplay_38420B9DB9FA01400_6.0.2.0_2024-09-21_16-56-36", "room_calibration_state": "1", "config_mode": null, "air_play_enabled": "1", "supports_audio_in": "0", "supports_audio_clip": "1" }, "ZoneGroupTopology": { "zone_group_state": "<ZoneGroupState><ZoneGroups><ZoneGroup Coordinator="RINCON_38420B9DB9FA01400" ID="RINCON_38420B9DB9FA01400:1517625262"><ZoneGroupMember UUID="RINCON_38420B9DB9FA01400" Location="http://[SONOSINTERNALIP]:1400/xml/device_description.xml" ZoneName="Slaapkamer" Icon="" Configuration="1" SoftwareVersion="80.1-56190" SWGen="2" MinCompatibleVersion="79.0-00000" LegacyCompatibleVersion="58.0-00000" BootSeq="3" TVConfigurationError="0" HdmiCecAvailable="0" WirelessMode="1" WirelessLeafOnly="0" ChannelFreq="2412" BehindWifiExtender="0" WifiEnabled="1" EthLink="0" Orientation="0" RoomCalibrationState="1" SecureRegState="3" VoiceConfigState="0" MicEnabled="0" HeadphoneSwapActive="0" AirPlayEnabled="1" IdleState="1" MoreInfo="TargetRoomName:Slaapkamer" SSLPort="1443" HHSSLPort="1843"/></ZoneGroup><ZoneGroup Coordinator="RINCON_7828CAB450E401400" ID="RINCON_7828CAB450E401400:1847747921"><ZoneGroupMember UUID="RINCON_7828CAB450E401400" Location="http://[OTHERSONOSIP]:1400/xml/device_description.xml" ZoneName="Eetkamer" Icon="x-rincon-roomicon:dining" Configuration="1" SoftwareVersion="80.1-56190" SWGen="2" MinCompatibleVersion="79.0-00000" LegacyCompatibleVersion="58.0-00000" BootSeq="155" TVConfigurationError="0" HdmiCecAvailable="0" WirelessMode="1" WirelessLeafOnly="0" ChannelFreq="2412" BehindWifiExtender="0" WifiEnabled="1" EthLink="0" Orientation="0" RoomCalibrationState="1" SecureRegState="3" VoiceConfigState="0" MicEnabled="0" HeadphoneSwapActive="0" AirPlayEnabled="1" IdleState="1" MoreInfo="" SSLPort="1443" HHSSLPort="1843"/></ZoneGroup><ZoneGroup Coordinator="RINCON_7828CAB44AC201400" ID="RINCON_7828CAB44AC201400:3303667209"><ZoneGroupMember UUID="RINCON_7828CAB44AC201400" Location="http://[OTHERSONOSIP]:1400/xml/device_description.xml" ZoneName="Kantoor" Icon="x-rincon-roomicon:office" Configuration="1" SoftwareVersion="80.1-56190" SWGen="2" MinCompatibleVersion="79.0-00000" LegacyCompatibleVersion="58.0-00000" BootSeq="140" TVConfigurationError="0" HdmiCecAvailable="0" WirelessMode="1" WirelessLeafOnly="0" ChannelFreq="2412" BehindWifiExtender="0" WifiEnabled="1" EthLink="0" Orientation="0" RoomCalibrationState="1" SecureRegState="3" VoiceConfigState="0" MicEnabled="0" HeadphoneSwapActive="0" AirPlayEnabled="1" IdleState="1" MoreInfo="" SSLPort="1443" HHSSLPort="1843"/></ZoneGroup><ZoneGroup Coordinator="RINCON_7828CAB44BC801400" ID="RINCON_7828CAB450E401400:1847747920"><ZoneGroupMember UUID="RINCON_7828CAB44BC801400" Location="http://[OTHERSONOSIP]:1400/xml/device_description.xml" ZoneName="Keuken" Icon="x-rincon-roomicon:kitchen" Configuration="1" SoftwareVersion="80.1-56190" SWGen="2" MinCompatibleVersion="79.0-00000" LegacyCompatibleVersion="58.0-00000" BootSeq="160" TVConfigurationError="0" HdmiCecAvailable="0" WirelessMode="1" WirelessLeafOnly="0" ChannelFreq="2412" BehindWifiExtender="0" WifiEnabled="1" EthLink="0" Orientation="0" RoomCalibrationState="1" SecureRegState="3" VoiceConfigState="0" MicEnabled="0" HeadphoneSwapActive="0" AirPlayEnabled="1" IdleState="1" MoreInfo="" SSLPort="1443" HHSSLPort="1843"/><ZoneGroupMember UUID="RINCON_7828CAB4535C01400" Location="http://[OTHERSONOSIP]:1400/xml/device_description.xml" ZoneName="Speelkamer" Icon="x-rincon-roomicon:playroom" Configuration="1" SoftwareVersion="80.1-56190" SWGen="2" MinCompatibleVersion="79.0-00000" LegacyCompatibleVersion="58.0-00000" BootSeq="168" TVConfigurationError="0" HdmiCecAvailable="0" WirelessMode="1" WirelessLeafOnly="0" ChannelFreq="2412" BehindWifiExtender="0" WifiEnabled="1" EthLink="0" Orientation="0" RoomCalibrationState="1" SecureRegState="3" VoiceConfigState="0" MicEnabled="0" HeadphoneSwapActive="0" AirPlayEnabled="1" IdleState="1" MoreInfo="" SSLPort="1443" HHSSLPort="1843"/></ZoneGroup><ZoneGroup Coordinator="RINCON_38420B9DBCD001400" ID="RINCON_38420B9DBCD001400:138278859"><ZoneGroupMember UUID="RINCON_38420B9DBCD001400" Location="http://[OTHERSONOSIP]:1400/xml/device_description.xml" ZoneName="Slaapkamer Xander" Icon="" Configuration="1" SoftwareVersion="80.1-56190" SWGen="2" MinCompatibleVersion="79.0-00000" LegacyCompatibleVersion="58.0-00000" BootSeq="3" TVConfigurationError="0" HdmiCecAvailable="0" WirelessMode="1" WirelessLeafOnly="0" ChannelFreq="2412" BehindWifiExtender="0" WifiEnabled="1" EthLink="0" Orientation="0" RoomCalibrationState="1" SecureRegState="3" VoiceConfigState="0" MicEnabled="0" HeadphoneSwapActive="0" AirPlayEnabled="1" IdleState="1" MoreInfo="" SSLPort="1443" HHSSLPort="1843"/></ZoneGroup></ZoneGroups><VanishedDevices></VanishedDevices></ZoneGroupState>" } }, "enabled_entities": [ "switch.sonos_ouders_loudness", "media_player.sonos_ouders", "number.sonos_ouders_balans", "number.sonos_ouders_hoge_tonen", "switch.sonos_ouders_crossfade", "number.sonos_ouders_bas" ], "media": { "album_name": "", "artist": "", "channel": "VRT De Tijdloze", "duration": null, "image_url": "http://[SONOSINTERNALIP]:1400/getaa?s=1&u=x-sonosapi-stream%3atunein%253a95991%3fsid%3d303%26flags%3d8232%26sn%3d3", "queue_position": 1, "playlist_name": null, "source_name": null, "title": "VRT De Tijdloze", "uri": "aac://http://vrt.streamabc.net/vrt-stubrutijdloze-aac-128-6442755?sABC=66rrqs29%230%23o6qq9p3p6q03r2oo8861982sqrpr47s2%23gharva&aw_0_1st.playerid=tunein&amsparams=playerid:tunein;skey:1726930729", "current_track_poll": { "Track": "1", "TrackDuration": "0:00:00", "TrackMetaData": "<DIDL-Lite xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:upnp="urn:schemas-upnp-org:metadata-1-0/upnp/" xmlns:r="urn:schemas-rinconnetworks-com:metadata-1-0/" xmlns="urn:schemas-upnp-org:metadata-1-0/DIDL-Lite/"><item id="-1" parentID="-1" restricted="true"><res protocolInfo="aac::application/octet-stream:">aac://http://vrt.streamabc.net/vrt-stubrutijdloze-aac-128-6442755?sABC=66rrqs29%230%23o6qq9p3p6q03r2oo8861982sqrpr47s2%23gharva&aw_0_1st.playerid=tunein&amsparams=playerid:tunein;skey:1726930729<r:streamContent></r:streamContent>dc:titlevrt-stubrutijdloze-aac-128-6442755?sABC=66rrqs29#0#o6qq9p3p6q03r2oo8861982sqrpr47s2#gharva&aw_0_1st.playerid=tunein&amsparams=playerid:tunein;skey:1726930729</dc:title>upnp:classobject.item</upnp:class></DIDL-Lite>", "TrackURI": "aac://http://vrt.streamabc.net/vrt-stubrutijdloze-aac-128-6442755?sABC=66rrqs29%230%23o6qq9p3p6q03r2oo8861982sqrpr47s2%23gharva&aw_0_1st.playerid=tunein&amsparams=playerid:tunein;skey:1726930729", "RelTime": "0:00:00", "AbsTime": "NOT_IMPLEMENTED", "RelCount": "2147483647", "AbsCount": "2147483647" } }, "activity_stats": { "ContentDirectory subscription": { "count": 2, "last_seen": 2598586.758378543 }, "AlarmClock subscription": { "count": 2, "last_seen": 2598586.773535367 }, "RenderingControl subscription": { "count": 13, "last_seen": 2599435.979355039 }, "AVTransport subscription": { "count": 44, "last_seen": 2599435.956971418 }, "SonosMedia.poll_track_info": { "count": 28, "last_seen": 2599435.97062105 }, "DeviceProperties subscription": { "count": 5, "last_seen": 2599466.281287419 }, "ZoneGroupTopology subscription": { "count": 5, "last_seen": 2599465.999265254 }, "discovery": { "count": 44, "last_seen": 2611977.772848165 }, "SonosSpeaker.ping": { "count": 30, "last_seen": 2611479.096796754 } }, "event_stats": { "ContentDirectory": { "received": 2, "duplicates": 0, "processed": 0 }, "AlarmClock": { "received": 2, "duplicates": 0, "processed": 0 }, "RenderingControl": { "received": 13, "duplicates": 0, "processed": 13 }, "AVTransport": { "received": 44, "duplicates": 9, "processed": 28 }, "DeviceProperties": { "received": 5, "duplicates": 0, "processed": 5 }, "ZoneGroupTopology": { "received": 5, "duplicates": 0, "processed": 5 }, "soco:from_didl_string": [ 205, 43, 128, 43 ], "soco:parse_event_xml": [ 219, 380, 128, 128 ] }, "zone_group_state_stats": { "processed": 56, "total_requests": 855 } } }