GQRX in a VM having audio issues

157 views
Skip to first unread message

Jon Zeolla

unread,
Feb 1, 2016, 9:55:55 AM2/1/16
to Gqrx SDR
I'm running gqrx on an Ubuntu 14.04 VM and I'm getting intermittent audio output when tuning to FM stations.  Sometimes it sounds good, other times it's so garbled that I can't tell if it's music or someone speaking.  However, when I record the garbled mess and play it, it comes out clear.  Also, when I run gqrx on my host machine (Mac OS X) I have no issues listening to the audio live.  

I'm testing using two different RTL-SDRs (different versions of the RTL2832U R820T2) and seeing similar issues between the two (sometimes it outputs correctly, sometimes it doesn't).  

I've played with the filters, mode, gain, fft settings, etc.  Attached is a screenshot.  Any ideas as to why this would happen?
Screen Shot 2016-02-01 at 9.20.56 AM.png

David Ranch

unread,
Feb 1, 2016, 12:00:09 PM2/1/16
to Gqrx SDR

Per the subject line,.. it seems like virtualization is the crux of your issue, not Gqrx.  You didn't mention which VM system you're using (Vmware Fusion, Parallels, VirtualBox, etc) but you need to focus there be it a CPU load issue, USB performance issues, etc.  I would recommend to join some support groups for your chosen VM system and see if they can help you.

--David
KI6ZHD

Robin Gape

unread,
Feb 1, 2016, 12:26:22 PM2/1/16
to gq...@googlegroups.com
Jon,

picking up on David's comments, the key issue is that one is using a VM, along with USB connected peripherals. A VM is fine in and of itself, but when it has to connect to the outside world a lot of processing is required to virtualise that outside world connection. Specifically, the USB by which your dongles are connected will take a lot of double handling.

One suspects, but you haven't told us, that performance will be better at low sample rates from the dongle.

Cutting to the chase, you may find it quicker and easier to run native Ubuntu 14.04, either on a cheap box of some sort or using a USB flash drive or hard disk to boot your Mac from. Some instructions may be helpful (caveat emptor): http://www.ubuntu.com/download/desktop/create-a-usb-stick-on-mac-osx (But it's a very long time since I last used a Mac!)

HTH, 73,

Robin, G8DQX

PS: None of us are mind readers. If we're not told what VM, technical parameters &c. are in use it's rather more difficult to offer directed advice.
--
You received this message because you are subscribed to the Google Groups "Gqrx SDR" group.
To unsubscribe from this group and stop receiving emails from it, send an email to gqrx+uns...@googlegroups.com.
To post to this group, send email to gq...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/gqrx/ff247ffb-42aa-4180-8bf9-2e558ed4fe92%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Jon Zeolla

unread,
Feb 1, 2016, 12:49:55 PM2/1/16
to Gqrx SDR
Thanks - this was my initial assumption as well (hence the title), but I wanted to check in with the gqrx community to see if it was a known/common issue that I just wasn't able to find when I searched around.  I'm currently running it on VMWare Fusion.  

Jon

Jon Zeolla

unread,
Feb 1, 2016, 1:08:23 PM2/1/16
to Gqrx SDR
Hi Robin, that was partly why I provided the screenshot.  I'm not familiar enough to know the full list of relevant parameters - is there a list of information which should be provided when attempting to troubleshoot an issue?  I'd be more than happy to comply, but I didn't see anything like that.  I'm currently running this on VMWare Fusion.  

I'm helping to put together a simple SDR lab (hence this needs to work consistently, cheaply, and easily across many different host platforms) and I'm encountering this issue when I test the OVA that I've prepared in VMWare, but I will play around a bit and try it in VirtualBox as well (Currently having an issue importing the OVA).  

I wasn't able to find any better performance while playing with the different settings, but if you could suggest something to try, I'd be more than happy to give it a shot.  Here are two more screenshots which should provide all of the parameters that I'm currently using.  I did alter the FFT size/rate and that didn't help.  

Jon
Screen Shot 2016-02-01 at 1.03.58 PM.png
Screen Shot 2016-02-01 at 1.04.08 PM.png

Robin Gape

unread,
Feb 1, 2016, 7:43:59 PM2/1/16
to gq...@googlegroups.com
Jon,

1) my understanding is that the class of dongle that you are using allows the user to set the sample rate in use. For least stress, I'd suggest using the lowest sample rate. The sample rate is set on the input controls tab

2) Are you using the latest version of VMware Fusion? I suspect that the free—cheapskate—version of Fusion will not perform as well for USB as later—paid for—versions

3) As a thought, you could try running VMware on a native Linux host on an x86 machine, with the emulated OS & applications on top. If that set up can't be got to work, then it's unlikely that the VMware Fusion approach would work

4) For a lab, one could also provide an Ubuntu image for a USB memory stick. For most of your likely customers, unless it's an all Mac shop, that could be an attractive approach. Ubuntu includes most things that a lab requires: LibreOffice, Octave, LaTex (cough!) and lots of other stuff

5) Desktop Ubuntu is not optimised to run under a VM. As a general principle, you might consider turning off all unnecessary services, such as the checks for updated software. You will probably find Xubuntu less resource intensive and easier to use as an engineering platform than the Unity desktop, which includes all sorts of flim-flam which is irrelevant to your declared tasks

Good luck,

Robin, G8DQX

Jon Zeolla

unread,
Feb 2, 2016, 1:59:01 PM2/2/16
to Gqrx SDR
1) Thanks.  I tried pretty much every combination of settings on that tab that I could figure out with no success.  =\
2) I am using the latest paid version of VMware Fusion - 8.1.0.  
3) Hmm I don't have an extra box laying around but if I come into one I'll give it a shot.
4) Yeah, I've considered that but I have over 40 people planning to participate in the lab, and don't have nearly enough USB drives at this point to do that.  I'm pretty sure after the live USB is loaded into memory you can remove the stick, but even then that would be a lot of passing around and waiting before we could get the lab started.  
5) Yeah I was actually looking into Lubuntu as well.  I may give it a shot - my script to set up the environment should work on any Debian based system so I can just set it and forget it.  

Thanks for the feedback.  I also noticed that the version of gqrx was pulled down via the package manager instead of compiling from source, so it's pretty outdated.  I'm going to modify the pybombs recipe to compile from source and see if that's better.  

Jon

Robin Gape

unread,
Feb 2, 2016, 6:54:37 PM2/2/16
to gq...@googlegroups.com
Jon,

to save you some pain, there's a very recent version of GQRX available under Ubuntu in a PPA, which avoids the pain—the time to compile and the fragility in specific requirements for compilation, including scrupulously cleaning out the old stuff—of using pybombs.

My tried and tested recipe is attached. Note that it is best do this on a clean install that has never had gnuradio or GQRX installed: one instant advantage of using a VM!


73,

Robin, G8DQX
2015 Change of GQRX PPAs.pdf

David Ranch

unread,
Feb 3, 2016, 12:07:43 AM2/3/16
to Gqrx SDR
Hello Jon,


4) Yeah, I've considered that but I have over 40 people planning to participate in the lab, and don't have nearly enough USB drives at this point to do that.  I'm pretty sure after the live USB is loaded into memory you can remove the stick, but even then that would be a lot of passing around and waiting before we could get the lab started.  

That's not true.  Most live Linux systems don't load everything into RAM like that.  I suppose they could if the host has enough RAM, it copies the entire OS to a RAM drive, and does a chroot but... none of them do this today.

--David

Jon Zeolla

unread,
Feb 9, 2016, 7:17:21 PM2/9/16
to Gqrx SDR
I just wanted to follow up and say that I rebuilt my VM on Ubuntu 15.10 and the only time I was ever able to reproduce the issue was when I unplugged the RTL-SDR without safely disconnecting it, closing gqrx, plugging it back in, and then opening gqrx.  If I were to then safely disconnect it, unplug it, and re-plug it, it worked again.  

Thanks for your help!

Jon

Robin Gape

unread,
Feb 10, 2016, 7:14:37 AM2/10/16
to gq...@googlegroups.com
Jon,

delighted that you got there. Good luck with the lab tomorrow!

Robin, G8DQX
Reply all
Reply to author
Forward
0 new messages