Selection menu Yamaha MusicCast PlayURI

Hi all,

I did my first trails with openHAB and HAB panel implementing Yamaha MusicCast speaker. I’m trying to implement a selection menu for Yamaha Musiccast with “play URI” for playing different radio stations. After setup of favorites with Yamaha API, a recall is done via following direct-URI (each “num” is reperesenting a different radio station).

Using a unique “button” for each channel with playURI-item and direkt http://… is working well. Channel switching between radio stations is possible. If implement the different http-calls from favorites into a selection menu in a widget is not possible because of the “=” signs in the direct http-call.

Is there any solution to hide the “=” signs in the selection menu for sending the full http-request?


I’d advise you to keep only the station number rather than the full URL in a proxy item, and set up a rule to perform the HTTP request accordingly when a command like ‘1’ or ‘2’ is received.

Thank you for the idea!

1st: create a proxy item called “ProxyRadio”
2nd: create a rule with following code:

rule “ProxyRadio”
Item ProxyRadio changed
if (ProxyRadio.state == “1”) {
sendCommand (“YamahaMusicCastSpeakerWX021room_PlayURI”, “http://IP-adresse/YamahaExtendedControl/v1/netusb/recallPreset?zone=main&num=3”)
else if (ProxyRadio.state == “2”) {
sendCommand (“YamahaMusicCastSpeakerWX021room_PlayURI”, “http://IP-adresse/YamahaExtendedControl/v1/netusb/recallPreset?zone=main&num=1”)
else if (ProxyRadio.state == “3”) {
sendCommand (“YamahaMusicCastSpeakerWX021room_PlayURI”, “http://IP-adresse/YamahaExtendedControl/v1/netusb/recallPreset?zone=main&num=2”)

Any more elegant idea for the code?

I had the same problem and solved it the following way:

Number Yamaha_Kitchen_presets “Preset [%d]” (GF_Kitchen) {http=">[*:GET:http://IP-adresse/YamahaExtendedControl/v1/netusb/recallPreset?zone=main&num=%2$s]"}


Selection item=Yamaha_Kitchen_presets label=“Sender [%s]” mappings=[1=“Ö1”, 2=“Superfly”] visibility=[Yamaha_Kitchen_Power == ON]

works fine, I can select no the stations in the UI with a pull down menu and don’t need a rule.

What would be interesting is how to start a playlist from a DLNA server, but I think there is no command for that in YAMAHA API and I need to push that from the DLNA (Twonkey) server to the YAMAHA speaker.