Sonos Button Controller Errors

Hello. I just tried to set up a button controller for a lutron pico device that I have to control a sonos zone. I did this before a few months ago with no issues, but I've since moved into a new home, started over with a large sonos installation, and started from scratch on my now two hubitat hub installation. The Pico is working fine. All button pushes are registered in hubitat just fine on the device page.

That said, when I try to set the button controller to have buttons do volume up or volume down, as well as toggle pause/play, I get errors in the logs. The button pushes are registered, but then the error is thrown. Interestingly, the buttons that I've set up for next track and previous track work fine...but the other sonos commands throw the errors. Below are some of them as an example. Any help would be appreciated.

app:262019-07-15 05:37:43.880 pm errorjava.lang.IllegalArgumentException: Command 'currentValue' is not supported by device. (buttonHandler)

app:262019-07-15 05:37:43.860 pm infoAction: Office Sonos: Lower volume for button 4 pushed

dev:342019-07-15 05:37:43.815 pm infoOffice Desk Pico button 4 was pushed

dev:352019-07-15 05:37:43.799 pm inforcvd: DEVICE,2,6,4

dev:352019-07-15 05:37:43.654 pm inforcvd: DEVICE,2,6,3

app:262019-07-15 05:37:41.328 pm errorjava.lang.IllegalArgumentException: Command 'currentValue' is not supported by device. (buttonHandler)

app:262019-07-15 05:37:41.302 pm infoAction: Office Sonos: Raise volume for button 2 pushed

dev:342019-07-15 05:37:41.254 pm infoOffice Desk Pico button 2 was pushed

dev:352019-07-15 05:37:41.226 pm inforcvd: DEVICE,2,5,4

dev:352019-07-15 05:37:41.011 pm inforcvd: DEVICE,2,5,3

I did some more checking, and it looks like this is some sort of problem with the button controller as controlling the sonos devices from the device page works. When I get a few minutes I'll try to set up the pico to control it using some other app other than the button controller. I am pretty sure this worked before, but I'm only 99% sure I used the button controller before and not something else. In any case, I think someone should look into a problem with the arguments in some methods in the button controller as there could be bug there. Can anyone duplicate this problem? Is there a known issue or a workaround? Thanks.

Okay, well, since it appears Button Controller must be implemented using Rule Machine, just a specific instance of it (since the setup screens are exactly the same), I get very similar errors when I try to do this with Rule Machine.

I don't really know how else to try to set this up beyond rule machine and button controller, so any help would sure be appreciated.

Okay, I've tried setting this up with a Wallmote that I have and got the same thing (just to make sure it wasn't something quirky with the Pico), and also tried using Rule Machine 3.0 instead of 4.0 and got the same result. I'm completely stuck...please help. Positing that the device driver is not accepting a "currentValue" argument and Rule Machine/Button Controller are trying to pass one. Could be way off, but either way I could use some help.

Thanks.
Bill~

Appears as if you are having a good conversation with yourself here. So, tagging @mike.maxwell and @bravenel.

This is being fixed.

2 Likes

@mike.maxwell I am running into this also. I used to have sonos units controlled from a push button to toggle play / pause, now it is throwing the same error and not functioning. It seems it worked with BC 1.6, not working in BC 3.0 and RM 4. Error is java.lang.IllegalArgumentException: Command 'currentValue' is not supported by device. (allHandler).

Edit - I did a work around by using RM and if-then else rule to pause or play.

Is this a RM issue then? My buttons no longer work as expected too. Play/pause also (still) doesn't work. When I press "play" sonos resumes from the start of the track (source is pocket cast, which needs to remember position).

Hopefully this is a bug in RM(?) and not a hubitat issue. Not sure of a workaround tho. I do run a sonos docker service---maybe I can use RM to send URL commands instead of relying on RM for this.

Can you explain what your workaround was? I got the impression the bug is with the action in RM to pause/play, etc., so how would if-then rules help? More detail here would be helpful. Thanks.

Here is the rule for the Samsung button in my son's room. It controls a Philips Hue strip under his bed as a night light, the overhead light, and the Sonos in his room. It also sets the nighttime volume and pauses it after a delay -

Thank you, @jdjmailbox . I'll experiment with it.

On a side note, @mike.maxwell, it looks like this fix you spoke of did not make it into the latest release ( 2.1.3.120). Do you have some sort of guidance on the time-frame we're looking at for a fix? Thx.

@mike.maxwell, any word on this? It's been a while, and even with several updates this bug is still there. Please advise.

Could you refresh for me what is the error you are seeing in what context?

Sorry we haven't fixed this. I just discovered the true underlying cause. Fix will be in the next release.

As you discovered, the same bug was in both Button Controller and Rule Machine. Fixed now.

Thank you. When working it really simplifies the rules (not having to do if/then/else statements for every button action). Really appreciate the update.