rtvb
(Robert)
June 10, 2016, 12:46pm
1
I am currently testing the notificationsound
channel for the new Sonos binding. This is working well so far. The only issue I have left is, that I’d like to host the sound file on my local machine. I currently host it at Dropbox, but only want it to be that way for the time being.
The question is, where in my openHAB folder to put my sound files (wav, mp3), so that I can provide a URI (like http://locahost/path/to/whatever.mp3 or http://192.168.1.2/path/to/whatever.mp3 ) from the openHAB Jetty server.
I have already tried (without success)
Cross-posted from:
Nice demo. I especially liked the hair blower trick.
@kai Do you have/know of of a working example how to play a notification to a Sonos device?
I’m trying to find the proper syntax for the URI for the notificationsound channel.
EDIT: more explicitly: where in my openHAB folder should I put the .mp3 file to have it opened through the Jetty server. I have already tried (without success)
{openhab2home}/extra => http://localhost:8080/doorbell.mp3
{openhab2home}/conf/icons => h…
rtvb
(Robert)
June 10, 2016, 4:19pm
2
In the meantime I read this thread:
I want to serve files in a folder. For that I followed this to configure my jetty.xml (bundles/io/org.openhab.io.jetty/jettyhome/etc)
But I was unable to access the folder.
Is this the right file I am changing? Or is there any other better way to accomplish this?
I guess I need to edit the {openhab home}/userdata/etc/jetty.xml
file?
rtvb
(Robert)
June 11, 2016, 6:51am
3
I read that file, noticed a reference to /static
that is referring to an html
folder.
I added my doorbell.mp3
to the {openhab home}/conf/html
folder and that did the trick.
I can now play a doorbell notification from the Sonos using this command:
sendCommand(Sonos_Living_NotificationSound, "http://<oh server ip>/static/doorbell.mp3")
Fwiw, .wav
files work as well.