Is here anyone using Volumio?

Perfect! Im new in domotic/openhab world… and its fantastic! Ill try your great tips… tomorrow! Thanks Stefan :slight_smile:

1 Like

YES! Stefan (of course) works like a charm!! Im happy :smiley:
Could i ask for another simply (for you maybe) question?
I was thinking…how stop music when the switch go from ON to OFF ?
Maybe with a rule like this

rule "RockStop"
when 
    Item PlayRock changed to OFF
then
   Volumio_Player.sendCommand("stop")
 end

but…of course dont works…where im wrong??
Thanks again :slight_smile:

Hi
I was thinking to create a playlist called “stop” with only one second sound.
Is not the best solution, but the only one I could think of…

SOLVED
the correct rule is

rule "RockSTOP"
when 
Item PlayRock changed to OFF
then
Volumio_State.sendCommand("PAUSE")
end

this works well, i hope this helps any newbie like me :slight_smile:

Hi Bud,
sorry, I didn’t received notifcations for your questions and so missed them. But cool that you found the right solution yourself. :sunglasses:

Is the Volumio working fine for you?
I have sometimes the issue that it is kind of freezed and so not possible to control it. Even with the browser there is no reaction. After a while it is back working.

Because of this I created my rule a bit more complex. It will try 20 times to start the stream (Until “the stream is playing” doesn’t work because the Volumio might response never. I had it once). Here my current version:

rule "Switch Raspberry Radio on"
when 
    Item volumioRaspberry changed to ON
then

    logInfo("rules", "Raspberry Player Status: " + Volumio_Raspberry_Player.state) 
    var Integer triggerLoop = 20    // Just try it 20 times
    while(Volumio_Raspberry_Player.state==PAUSE && triggerLoop>=1) {
        logInfo("rules", "Raspberry Player Status: " + Volumio_Raspberry_Player.state) 
        logInfo("rules", "Next try to start a radio stream on Raspberry Volumio. " + triggerLoop + " tries left.")                             Volumio_Raspberry_playRadioStream.sendCommand("http://www.wdr.de/wdrlive/media/kiraka.m3u")
        Thread::sleep(10000)
        triggerLoop = triggerLoop -1
    }
    if (Volumio_Raspberry_Player.state==PLAY ) {
        logInfo("rules","Raspberry Radio started.")
    }
    if (Volumio_Raspberry_Player.state==NULL ) {
        postUpdate(volumioRaspberry, OFF)
    }

end


rule "Switch Raspberry Radio off"
when 
    Item volumioRaspberry changed to OFF
then

    logInfo("rules", "Raspberry Player Status: " + Volumio_Raspberry_Player.state) 
    var Integer triggerLoop = 20    // Just try it 20 times
    while(Volumio_Raspberry_Player.state==PLAY && triggerLoop>=1) {
        logInfo("rules", "Raspberry Player Status: " + Volumio_Raspberry_Player.state) 
        logInfo("rules", "Next try to stop Raspberry radio. " + triggerLoop + " tries left.") 
        Volumio_Raspberry_Player.sendCommand("PAUSE")
        Thread::sleep(10000)
        triggerLoop = triggerLoop -1
    }
    if (Volumio_Raspberry_Player.state==PAUSE ) {
        logInfo("rules","Raspberry Radio stopped.")
    }

end

Hi Stefan… :smiley:
I have not issues with volumio (my configuration is rpi2 and audiophoncs sabre dac) and i have updated Volumio to the last distro…
But i can try your rule…this w.e. i hope :slight_smile:
After that i will tell you something about…
Stay tuned
Thanks again for your support :raised_hands:

Hi,
great work on this binding!
I have a little issue though, I am trying to control Volumio on raspi via the knx binding.

So I used a dimmer and tried the to get the volume control working with INCREASE / DECREASE but it returns me “Command not handled”.
With a number 10 it works fine.(sendCommand(Bad1etVolumio_Volume, 10))
It also returns:
command type which item ‘Bad1etVolumio_Volume’ accepts: [PercentType, OnOffType, IncreaseDecreaseType, RefreshType].
Is the “IncreaseDecreaseType” not handled in the binding or am I doing something wrong.
Via the PaperUI Control I can use the slider for volume control and that works fine.

Thanks !!!

Hello, thanks for this binding!
it works perfect, but i had one Problem.

i want to catch the Title in a Rule and send it over http to another device, but i doesn’t work

String kI_Volumio_Title “Title: [%s]” { channel=“volumio2:player:xxx:title” }
Player kI_Volumio_Player “Player” { channel=“volumio2:player:xxx:player” }

rule “Track Volumio”
when
Item kI_Volumio_Title changed
then{
sendHttpGetRequest(“http://192.168.1.52/or.asp?set=.stMulti.sTitle:” + kI_Volumio_Title.state)
}
end

i also want to catch the Player Buttons State when it changed from Pause to Play then i want trigger a var…

rule “Volumio Ein”
when
Item kI_Volumio_Player changed from PAUSE to PLAY
then{
sendCommand(HarmonyWohnzimmerActivity,“Radio”)
}
end

Thanks
Markus

hi patrck, there’s the 0.0.11 jar file somewhere? i don’t know how to compile it from source and the 0.0.10 version give me this kind of problem

[ERROR] [ing.volumio2.handler.Volumio2Handler] - Could not refresh channel

org.json.JSONException: JSONObject[“random”] is not a Boolean.

thanks in advance hoping you don’t stop coding this wonderful binding… :slight_smile:

Hey guys,

I’ve got everything set up with volumio except playlists, do I need a myvolumio paid account to be able to use playlists with openhab?

Cheers
Matt

i cannot compile the source… i’ve recevied this error

[INFO] Fetching p2.index from https://openhab.jfrog.io/openhab/eclipse-smarthome-stable/ (172B)
[INFO] Fetching p2.index from https://openhab.jfrog.io/openhab/eclipse-smarthome-stable/ (172B)
[INFO] Adding repository https://openhab.jfrog.io/openhab/eclipse-smarthome-stable
[INFO] Fetching content.xml.xz from https://openhab.jfrog.io/openhab/eclipse-smarthome-stable/ (28.75kB)
[INFO] Fetching content.xml.xz from https://openhab.jfrog.io/openhab/eclipse-smarthome-stable/ (28.75kB)
[INFO] Adding repository https://dl.bintray.com/openhab/p2/openhab-deps-repo/1.0.12
[INFO] Fetching content.jar from https://dl.bintray.com/openhab/p2/openhab-deps-repo/1.0.12/ (29.04kB)
[INFO] Fetching content.jar from https://dl.bintray.com/openhab/p2/openhab-deps-repo/1.0.12/ (29.04kB)
[INFO] Resolving dependencies of MavenProject: org.openhab.binding:org.openhab.binding.volumio2:2.1.0 @ /home/openhabian/org.openhab.binding.volumio2/pom.xml
[INFO] {osgi.os=linux, osgi.ws=gtk, org.eclipse.update.install.features=true, osgi.arch=x86}
[ERROR] Cannot resolve project dependencies:
[ERROR] Software being installed: org.openhab.binding.volumio2 2.1.0.qualifier
[ERROR] Missing requirement: org.eclipse.smarthome.core 0.10.0.201811100937 requires ‘package javax.measure 0.0.0’ but it could not be found
[ERROR] Cannot satisfy dependency: org.eclipse.smarthome.config.core 0.10.0.201811100937 depends on: package org.eclipse.smarthome.core.common 0.0.0
[ERROR] Cannot satisfy dependency: org.openhab.binding.volumio2 2.1.0.qualifier depends on: package org.eclipse.smarthome.config.core 0.0.0
[ERROR]
[ERROR] See http://wiki.eclipse.org/Tycho/Dependency_Resolution_Troubleshooting for help.
[ERROR] Cannot resolve dependencies of MavenProject: org.openhab.binding:org.openhab.binding.volumio2:2.1.0 @ /home/openhabian/org.openhab.binding.volumio2/pom.xml: See log for details -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MavenExecutionException

I´ve build the last 0.0.11 version against Openhab 2.1.0. I´ve never tried to build it against a newer release and it looks like there are some problems with dependencies delivered by esh.

May i do something, for example try to compile with some more parameters, helping you to find the problem? or is better to downgrade and go on? :slight_smile:
thanks in advance
Marcello

I just need some time to test-build-it. I guess there´s some import missing that was present in the old days and now is gone or replaced.

ok, thanks… if i could be more usefull let me know :slight_smile:

Ok … I think it´s a missing depdency from eclipse SmartHome…

Found this in the forum Fragile build environment -- maven build fails. I will try update the dependencies tonight.

I´ve pushed a new version on branch 0.0.12 (https://github.com/patrickse/org.openhab.binding.volumio2/tree/0.0.12). It actually compiles… but:

  • I cannot test it today… can´t get my test volumio vm to start
  • CI fails… because of some style checks … need to have a look…

It should be possible to get the source of 0.0.12 and create a jar with mvn package.

I will try to find some time to have a look on these open issues…

1 Like

I´ve fixed the style check problems… You can find the current pre-build jar at https://github.com/patrickse/org.openhab.binding.volumio2/releases/tag/0.0.12

hi patrick, sorry for the delay, but i was out for job.
Thanks, now it works that is a marvel.
I managed to compile directly from the source, i use openhabian distro with openhab 2.3.0. but I have this error in the log, even the previous version did it. I’ve configured something wrong?

2018-11-24 16:54:28.970 [ERROR] [ing.volumio2.handler.Volumio2Handler] - Could not refresh channel

org.json.JSONException: JSONObject[“random”] is not a Boolean.

at org.json.JSONObject.getBoolean(JSONObject.java:524) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at org.openhab.binding.volumio2.internal.mapping.Volumio2Data.update(Volumio2Data.java:113) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at org.openhab.binding.volumio2.handler.Volumio2Handler$4.call(Volumio2Handler.java:372) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.emitter.Emitter.emit(Emitter.java:117) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Socket.onevent(Socket.java:340) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Socket.onpacket(Socket.java:293) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Socket.access$100(Socket.java:19) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Socket$2$2.call(Socket.java:111) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.emitter.Emitter.emit(Emitter.java:117) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Manager.ondecoded(Manager.java:407) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Manager.access$1600(Manager.java:20) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Manager$7.call(Manager.java:383) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.emitter.Emitter.emit(Emitter.java:117) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.parser.Parser$Decoder.add(Parser.java:157) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Manager.ondata(Manager.java:399) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Manager.access$1000(Manager.java:20) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.client.Manager$2.call(Manager.java:350) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.emitter.Emitter.emit(Emitter.java:117) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.engineio.client.Socket.onPacket(Socket.java:511) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.engineio.client.Socket.access$1000(Socket.java:31) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.engineio.client.Socket$5.call(Socket.java:313) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.emitter.Emitter.emit(Emitter.java:117) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.engineio.client.Transport.onPacket(Transport.java:134) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.engineio.client.Transport.onData(Transport.java:126) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.engineio.client.transports.WebSocket.access$300(WebSocket.java:28) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.engineio.client.transports.WebSocket$2$3.run(WebSocket.java:122) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at io.socket.thread.EventThread$2.run(EventThread.java:80) [225:org.openhab.binding.volumio2:2.4.0.201811241526]

at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:?]

at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:?]

at java.lang.Thread.run(Thread.java:748) [?:?]

Hi Patrick i’ve made some tests.
I’ve enable “playlist random command” in my volumio gui interface and all error are disappeared.
I’ve also reboot openhab but the error, after the first command “initialization”, even though before rebooting i’ve unchecked it, no more appear!. Fantastic! :slight_smile: