Nice discovery! I’ll have to check this out. I have two speakers set to stereo, so connected to Smartthings as a single device. Sounds similar to what you’re describing with surround speakers. I have a separate speaker that I’ll test to see if it has the same problem.
James,
I am trying to add media tile as described above with my own artwork.
Can you confirm where you get the rule ID from?
I have tried to create a tile and when I click on it I get an error page dashboard not found, can you help, please?
Thank you,
Paul.
Hi @Paul_Starkey, you can get the rule id from the rule editor page when editing the specific rule. See the screenshot below. And you can follow the instructions as shown in the screenshot below and replace rule id in the Hyperlink
field with your rule id.
That works great thank you, James. Is there a way to do the same for a normal tile on a dashboard, say for a light switch with a custom image? Cheers.
You can surely use a media tile with custom image, and have it run a rule when tapped, and add the logic in the rule to determine if it should turn the switch on or off based on the switch’s current condition (using IF condition). But the down side is you cannot display different images based on the switch status at this point. (The regular Switch Tile may glow or show different style when on
.)
Got it thanks! You and the team are a big help.
Hi All, lots of great content in this thread, much appreciated!!
I found a few references to Sonos Shuffle, but either missed the solution or maybe there is not one yet?
In the event there is not one yet, has anyone played with the Sonos API, you can shuffle using playback mode → https://developer.sonos.com/reference/control-api/playback/set-play-modes/
I was wondering if an HTML tile might work to do this…
Thanks everyone for the help and time!
Walt
Just posted my workaround/hack and some thoughts on a fresh post (given there is a potential solution)
Good luck all, I hope it helps.
Walt
I have Sonos, with Hubitat that I would like to make a button to play a playlist from Pandora.
I went into Hubitat and pulled the uri and created a rule. Then I created a button to trigger that rule. But it’s not working.
I verified the uri is correct by pasting it in the Hubitat button for PlayTrack and it works great. I just can’t get it to work with Sharp Tools.
It says “executing rule” and nothing happens
Welcome to the community and thanks for posting! What are you seeing in the SharpTools Rule Logs (for that rule) and in the Hubitat logs when you run the rule?
Edit: I’m also wondering if the encoding could be part of the problem. The %3a
after x-sonosapi-radio:ST
is equal to :
Sharp tools has a rule log?
Here’s what Hubitat says for the time I clicked the rule button
So strange it says “Kitchen Sonos is stopped”
Yes, you can find details here: Rule Execution Logs
I don’t have a Sonos device with me over the holidays to test with, so I would need more detail to be able to help troubleshoot.
Are there volume control actions in your rule? Otherwise I don’t understand why the logs are showing volume control responses.
I’m not seeing the action coming across from SharpTools being logged, so you would want to flip the Enable Logging switch on in the SharpTools ‘app’ in Hubitat so you can see the commands come across:
Similarly, can you enable further debugging details for the device? It doesn’t seem like it’s showing attempted commands, just the resulting state change.
Just wanted to reiterate that this part seems odd to me. If you try the unencoded value, does it work in the Hubitat device details screen (for PlayTrack) and in your rule?
x-sonosapi-radio:ST:4255090724220561921?sid=236&flags=8300&sn=8
I got frustrated, uninstalled sonos integration in hubitat, and reconnected hubitat to sharp things. And bam it’s working. I didn’t change the rule machine or anything.
I’ve recently integrated the juke box idea, but was trying to modify the rule to start playback at a certain point during the media. I am linked to my plex server through sonos, and have added the song that I want and can play the song successfully. However I am trying to get it to start about a minute into the song as the opening has a build up that I am trying to skip. Any ideas on way to achieve this?
@James I’ve had this running for some time flawlessly. I went back and looked at the methodology after a comment from @josh in the SmartThings community. As of right now, the Sonos preset is identified from the Current States data in the IDE. Any idea how to identify the preset after the IDE deprecates? You can probably wing it by trying different numbers but wondering if there will be a better way.
Does that information show up under your SharpTools User Page > Location > Thing?
It might be stale since it probably won’t have an event subscription, but you can reauthorize your devices to sync it over fresh.
It sure does. Didn’t realize it would be there. Perfect!
Hi
I have a playlist with songs from various sources added in the Sonos application, can I play such a playlist using sharptools? I was able to start radio stations with PlayPresent, how do I start a playlist?
The playlist might show up under the presets in ST if you can add it as a favorite in Sonos.