Audio Streaming from Raspberry with UV4L and USB Audio Card

885 views
Skip to first unread message

Davide Caldelari

unread,
Jul 4, 2017, 3:12:33 AM7/4/17
to meetecho-janus
Hi everybody,

I just started learning WebRTC and Janus and, well, I can say that putting all the informations together is not that easy.

My problem is the following: I have a raspberry Pi with UV4L and Janus installed and an external USB audio card. I configured the Raspberry so that the audio card is the default device.

I used the dummy driver (I don't need any video) and I got it to work:



I can hear the audio. Now, the problems:

1) The audio is awful. I have no control on it, I don't know what kind of codec is used (Opus is what I would like). Is there a way to control the quality? Any idea why it is so bad?

2) I would like to use Janus (the streaming plugin or any other plugin) to get that audio. Do you know maybe how I can do it?

If you just could give me some hints, I would appreciate it.

Thank for you suggestions!
Davide



Alessandro Amirante

unread,
Jul 4, 2017, 3:55:49 AM7/4/17
to Davide Caldelari, meetecho-janus
Why don't you just feed the Janus Streaming plugin with a gstreamer pipeline? There are plenty of examples about this in the group, just try to search for "gstreamer".

A.

--
You received this message because you are subscribed to the Google Groups "meetecho-janus" group.
To unsubscribe from this group and stop receiving emails from it, send an email to meetecho-janus+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Davide Caldelari

unread,
Jul 4, 2017, 4:15:59 AM7/4/17
to meetecho-janus, davide.c...@gmail.com
Hi Alessandro,

thank you very much for your answer. I will check that immediately. May I ask you a question? What exactly is the relationship between UV4L, gstreamer and Janus? I mean, for my purpose do I need them all? Gstreamer needs UV4L?

Thanks!
D.
To unsubscribe from this group and stop receiving emails from it, send an email to meetecho-janu...@googlegroups.com.

Lorenzo Miniero

unread,
Jul 4, 2017, 4:19:04 AM7/4/17
to meetecho-janus, davide.c...@gmail.com
Il giorno martedì 4 luglio 2017 10:15:59 UTC+2, Davide Caldelari ha scritto:
Hi Alessandro,

thank you very much for your answer. I will check that immediately. May I ask you a question? What exactly is the relationship between UV4L, gstreamer and Janus? I mean, for my purpose do I need them all? Gstreamer needs UV4L?



There is no relationship, Janus doesn't need any of them strictly speaking. If you use the Streaming plugin, you need something to feed the mountpoint, and both gstreamer and UV4L (or ffmpeg, for that matter) allow you to do that. I'm not familiar with how UV4L works and if it depends on gstreamer or not, you'll have to ask the authors.

L.

Webmaster Webmaster

unread,
Jul 4, 2017, 5:01:56 AM7/4/17
to meetecho-janus
The offered codec is Opus from UV4L. If you are talking about analog audio quality from the Rpi, then, yes, it's awful. Use HDMI out by default and/or tweak the rpi configuration to improve the default quality. There is plenty of informations on how to do this on google.

Davide Caldelari

unread,
Jul 4, 2017, 5:41:31 AM7/4/17
to meetecho-janus
I'm sorry, but I don't understand very well. For "quality", I mean that of the audio from the webpage of the screenshot above, I mean that out from my PC speakers/headphones not from the Raspberry. Or there's something I'm missing? 

Webmaster Webmaster

unread,
Jul 4, 2017, 5:47:38 AM7/4/17
to meetecho-janus
Sorry, I misunderstood your question. As I said the codec is Opus, check your recording device settings..e.g. the sample rate or volume
Reply all
Reply to author
Forward
0 new messages