I need help getting audio recording to work

Forum for questions and support relating to the 1.34.x releases only.
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

I need help getting audio recording to work

Post by user671 »

Ok so I have zoneminder version 1.34.12 I think and I have this one camera that is capable of recording audio. It's a cheap IP camera I got off amazon called Alptop AT-500PE. it's a ptz 2k camera. When I connect to it through vlc I can hear through its speakers. But in zoneminder recordings I don't get the audio.
I really like zoneminder; For the most part it's worked like a charm. I just really want to get this audio recording working and I'm open to any any tips on how to get that working. Any help would be greatly appreciated. Thank you. :D
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

Re: I need help getting audio recording to work

Post by user671 »

Does anyone know what I should do? Or can anyone point me somewhere I should look if this sort of question has already been answered?
User avatar
iconnor
Posts: 2879
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: I need help getting audio recording to work

Post by iconnor »

Have you checked the box on the storage tab next to
Whether to store the audio stream when saving an event.:
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

Re: I need help getting audio recording to work

Post by user671 »

Yes I have the box ticked. This box correct?
https://imgur.com/a/Yx6PEsu
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

Re: I need help getting audio recording to work

Post by user671 »

Also I made a mistake in my first post. I have zoneminder 1.34.15 not .12
User avatar
iconnor
Posts: 2879
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: I need help getting audio recording to work

Post by iconnor »

Some cameras don't encode the audio in the rtsp stream. (Like by dbell).

So the thing is if the audio is present in the stream, it should be present in the .mp4.

If it isn't, then we need to figure out where to get it from.

The best thing to do at this point is turn on debug logging and see what streams are present.

Edit: I just noticed that you said vlc plays it fine. Which tells me that there may be a problem with our handling of the audio.

So turn on debug and let's see what we get.
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

Re: I need help getting audio recording to work

Post by user671 »

Thank you for the replies. Where do I find the option to turn on debugging for this camera in zoneminder?
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

Re: I need help getting audio recording to work

Post by user671 »

Is this the error that is preventing the audio stream from being recorded?
https://imgur.com/a/eC8L3Tq
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

Re: I need help getting audio recording to work

Post by user671 »

It says error parsing AU headers... What does that mean?
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

Re: I need help getting audio recording to work

Post by user671 »

Where is zm_ffmpeg.cpp located in a standard zoneminder install? I was gonna investigate line 70 of that file to see what's up with it.
User avatar
iconnor
Posts: 2879
Joined: Fri Oct 29, 2010 1:43 am
Location: Toronto
Contact:

Re: I need help getting audio recording to work

Post by iconnor »

The error could be it. I don't know what it means. That error is coming from the ffmpeg libraries, not zm source.
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

Re: I need help getting audio recording to work

Post by user671 »

What should I do?
mikb
Posts: 585
Joined: Mon Mar 25, 2013 12:34 pm

Re: I need help getting audio recording to work

Post by mikb »

user671 wrote: Mon Jun 08, 2020 7:08 pm Where is zm_ffmpeg.cpp located in a standard zoneminder install? I was gonna investigate line 70 of that file to see what's up with it.
For future general Unix reference ... if you have locate or slocate installed, you can do this :-

# locate "zm_ffmpeg.cpp"
/usr/local/src/zoneminder/ZoneMinder-1.25.0/src/zm_ffmpeg.cpp

I know, I really should upgrade :(

For the error message from FFMPEG, always instructive to paste it exactly into Google and see what comes up :-

https://www.google.co.uk/search?q=ffmpe ... AU+headers"
user671
Posts: 18
Joined: Fri Dec 06, 2019 6:55 am

Re: I need help getting audio recording to work

Post by user671 »

Thank you all for the replies. I can't seem to figure out what the issue is. I think maybe it might be related to the fact that I was previously running zoneminder version 1.32.3 I think... a version of zoneminder that did not support audio recording and I upgraded to version 1.34.5 and subsequently have upgraded every time since then.

I think I'll try a fresh install of Zoneminder with 1.34.16 from the get go and see if that allows me to have audio in my recordings from that camera. I'm probably gonna do the fresh install when I have the time next week. I'll let you all know if that fixes anything.

Somewhat related, I had another question about about hardware acceleration in zoneminder. I was wondering if using something like a 980ti would help significantly in lightening the load on the server that has mutliple 4k cameras. I won't be attempting that until I do my fresh install. But I want to lighten the load on the server so I can add a doorbell camera and right now there's no way the machine will handle it with how much workload it has just to keep up with the existing cameras. Maybe a strong graphics card can reduce the stress on the cpu enough to let me get one more camera in.
User avatar
burger
Posts: 390
Joined: Mon May 11, 2020 4:32 pm

Re: I need help getting audio recording to work

Post by burger »

GPU isn't used by ZM (except by advanced users).

If you need lower load on 4K cameras see: viewtopic.php?f=9&t=27537
fastest way to test streams:
ffmpeg -i rtsp://<user>:<pass>@<ipaddress>:554/path ./output.mp4 (if terminal only)
ffplay rtsp://<user>:<pass>@<ipaddress>:554/path (gui)
find paths on ispydb or in zm hcl

If you are new to security software, read:
https://wiki.zoneminder.com/Dummies_Guide
Post Reply