Page 1 of 1

web alarm sound

Posted: Thu Sep 10, 2015 9:50 am
by mattionline

i wanted to play a sound when a alarm is detected.
In the options i leaved the DIR_SOUNDS by the standard folder "sounds", i activated the WEB_SOUND_ON_ALARM and set the WEB_ALARM_SOUND to the soundfile "door.wav" which i uploaded in the folder /usr/share/zoneminder/sounds .
Then i changed the owner of the soundfiles to www-data and the chmod to 755.
After that i restarted zm but no sound appears when im in the montage view.
Then i uploaded a few other soundfiles (5-6 files) which are mp3 and wav files, set the owner to root to test if it needs the user and group root, but nothing happens.
Furthermore i tried to use chrome instead of firefox, but there is also no sound played.
When i go to http://IP/zm/sounds/ i can easily play all of the sounds.

If you can help me id be very thankful

Re: web alarm sound

Posted: Thu Sep 10, 2015 1:11 pm
by bbunge

Re: web alarm sound

Posted: Tue Sep 15, 2015 9:29 am
by mattionline
I downloaded your Doorbell.ogg, copied it to /usr/share/zoneminder/sounds, chmodded it to 755, checked WEB_SOUND_ON_ALARM, changed WEB_ALARM_SOUND to Doorbell.ogg and restarted zoneminder.
I have also watched if i have installed the vlc plugin and i have it with the version vlc media player web plugin 2.1.3, but when the alarm is triggered there is no sound and also not an window where i must accept, because i set it to allow always in the firefox settings.
Under Firefox, Chrome and Edge i still dont get the sound.

Re: web alarm sound

Posted: Sat Sep 19, 2015 5:33 pm
by mattionline
FYI: I think that the sound is just played when youre in the single monitor view. In the montage view there isnt a sound played.

Re: web alarm sound

Posted: Wed Mar 02, 2016 8:16 pm
by davidma
I figured I would add some help about this as I just struggled through it.

1. Click view source in the browser you are using.
2. do a search for the sound file you think it should be.
3. Click or copy and past the url to the sound file and verify that it doesn't come up as 404 or forbidden, etc. If it's just not found double check the paths in options -> web and make sure you have it enabled. Also check your zm.conf to see where the zoneminder www path is as your sound directory is probably relative to that and sometimes some bogus sound directories are installed even though they aren't the one actually used.

I ended up being able to get it working in Chrome but oddly it isn't working yet in Firefox for me even though I have the vlc web plugin installed. Also as suspected I noticed it does NOT work in montage view at all whether it is compact, not compact, scaled or default. It has to be the live stream for an individual monitor/camera.