Usbradio driver low Rx audio level going out over IAX

I’ve been testing Rx audio by connecting to a node I’m testing with the iaxRpt PC app and then recording the output directly (software loopback) from iaxRpt into Audacity, thereby recording in the exact PCM audio data sent over IAX.

I’ve been seeing some big differences in levels (particularly peak vs. average levels) when using the usbradio vs. simpleusb driver. Part of this is because simpleusb is not bandpassing the Rx audio, so whatever you put in to the ADC (after the CM1xx 0~45dB gain section), seems to be exactly what goes out IAX – as it should be. But there’s something else going on also as usbradio simply will not put out any higher than about -10dBFS.

In testing audio performance of a radio-less node vs. a radio node I was surprised to find the radioless node sounds better, since that node just has a basic hand mic with not much gain and no limiting. After some tests I narrowed down the difference to usbradio driver. It seems the Rx audio peak levels going to other nodes from usbradio is always about 10dB lower than with simpleusb. That seems strange and hard-to-believe, and it would be great if anyone could try the same test and LMK what you see. It’s as if usbradio has a 10dB hard limiter (with -10dBFS threshold), which I suppose would help keep levels consistent, but would put it at a significant dynamic range disadvantage compared to simpleusb.

The issue may just be that the mic on the radio-less node doesn’t have enough gain, and with more gain I could get the rms levels higher in usbradio, but it has plenty of gain for simpleusb, and my other node with radios has plenty of gain and in that case I can get the rms levels about the same from usbradio but it just does not want to let any peaks through that are higher than about -10 dBFS, whereas simpleusb driver goes as high as 0dBFS just fine. (The only reason I use usbradio on this node is I don’t (yet) have a COS line from the receiver on this node so I use carrierfrom=vox mode which works quite well for detecting the presence of even quiet audio.)

I have usbradio set up with the same general settings that simpleusb uses (speaker audio, no emphasis or limiting, no CTCSS encode/decode in the driver). Tx audio would need bandpass filtering and limiting if going direct into an FM modulator and Rx audio may need filtering or at least deemphasis if from a discriminator input, but when rxdemod=speaker and txprelim=no, I don’t see why usbradio would need to do any filtering on Rx or Tx.

With usbradio, even if I turn up the rxmixerset gain and audio input level as loud as possible (receiver volume cranked), I can’t get the audio peak level to go above about -6dB in iaxRpt, and for normal voice levels it’s more like -10dB max, -16dB average. Both nodes I’m testing have CM108AH interfaces and I’ve tried both drivers on the radio-less node (with max possible rx gain settings in usbradio, rxboost on in rpt.conf), and simpleusb sounds great, usbradio won’t go above -10dB, with the exact same hardware.

Ideally, a properly configured node should be using the full 16-bit dynamic range, or close to it, while sounding good and not overdriven. I have connected to numerous other nodes/repeaters/hubs also and their levels are as expected, typically around -6dB average levels, good volume, peaks within a couple dB of FS, no clipping/distortion.

If anyone is getting good audio from usbradio going out over IAX without this mysterious 10dB of limiting I’d be interested to know what settings you have in usbradio.conf. But unless I’m missing something my guess is that most people don’t use usbradio in anything but carrierfrom=dsp mode and maybe it works great for that, but it seems to have a definite limited range of outgoing (Rx) audio level when configured in other carrierfrom modes. In reality it’s not a major difference, after some adjustment you end up with typical highly compressed audio from usbradio that sounds like a radio, but the difference in dynamic range vs. simpleusb is pretty surprising.

As best as I remember, I had no issues with USBRadio using the ACID version of the software.
I went from that to ASL1.01 and switched to SimpleUSB and stopped using DSP services.

I believe if you look through the forum posts, you will find some complaints here and there.
Perhaps something to be learned ?

Likely this needs looked at but it’s not my cup of tea.
Something may be found by comparing the version used with that ACID version to ASL 1.01
There was a version in between known as DIAL that I never used as I was trying to stay on my Centos system until it broke with future upgrades to what was was trying to achieve overall in my entire PBX systems. I needed a later version of asterisk that was not happy with centos5. App_rpt was not happy with centos6 at the time.

Anyway, just some thought on paths to investigate…I agree that something is not quite right.

Update: Did a recent node build using an Alinco DR-735T and am now getting normal outgoing IAX audio levels (peaks well above -10dBFS). This node uses the discriminator output from the radio and usbradio=dsp mode whereas on most previous nodes (using HTs or radio-less nodes) I was using carrierfrom=usbinvert mode. So maybe this issue only occurs in certain usbradio carrierfrom modes. Which is not really an issue since simpleusb works fine for nodes where you don’t need DSP carrier detect and CTCSS decode.