Audio Buffering

Audio Buffering

Since different IP systems have different latency and jitter it is important to set the correct buffer delay.

On this page you can read about when the audio needs buffering and how to set up the SoftRadio system for best performance.

Mimer SoftRadio

Setting of the audio buffer delay

Background
In IP networks it takes some amount of time to transfer a data message from one point to another. This time is usually very short for local networks, but can be quite long and vary a lot for long connections over internet or over 4G connections.

Such variations in the time, called jitter, may be a problem in a system transferring audio, because if an audio message gets a bit extra delayed there will be a drop-out in the audio.

The solution for this is to have a buffer that captures some extra messages before the audio starts playing in the speaker. Then if messages are a bit delayed there will be spare data in the buffer to use  in the meantime.

How much data to capture in this buffer in order to get a smooth audio depends on how much jitter there is on the connection. The disadvantage of a large buffer is that the audio gets a bit delayed, but a delay of up to a few hundred milliseconds is seldom a problem.

Audio Data Buffering
Audio data buffering is used where audio data is received and shall produce analog audio. This is done in the SoftRadio Client where audio is produced for the PC speaker. It is also done in the Network Interface where microphone audio data shall modulate the radio transmitter.

Therefore there are settings for this in both Connections Setup for the SoftRadio client and in the Network Interface Setup program. Typically both of these shall be set to the same values.

Principle view of the audio in a SoftRadio system

Principle view of the audio in a SoftRadio system. Buffering is done at the end points before conversion to analogue audio

Buffer length setting
The default buffer length in SoftRadio is 3 packets (of 32ms each) and this works very well for most local networks and good quality WAN connections. This setting can handle a jitter of up to 96ms without dropouts.

However for connections with a considerable amount of jitter you may need to increase this setting. If you encounter problems with drop-outs on potentially unstable connections we recommend that you increase it in steps of 2 or 3 units until the problem disappears.

Doing the settings
You set the value in both the network interface and in the SoftRadio client, or just use the default.

If you find out that the value was to low, you need only change the value in the SoftRadio client. This higher setting will then override the setting in the network interface.

If the system has a NetworkRepeater, a setting there will override the setting in the network interface. And the setting in the SoftRadio client will only be used for buffering incomming audio.

Setting of audio buffer delay in "Interface setup"

Setting of audio buffer delay in
the Network Interface´s “Interface setup”

Setting of audio buffer delay in "Connections setup"

Setting of audio buffer delay
in SoftRadio´s “Connections setup”.
The NetworkRepeater has a
similar setting.

System examples

Simple system all connected in a local LAN subnet

Simple system all connected in a local LAN subnet.

Most LAN systems have minimal jitter and latency.

Set the buffer length to a low value in both ends. 2-3 is usually correct.

Only one operator connected to the radio over WAN or the Internet, no servers needed

Only one operator connected to the radio over WAN or the Internet, no servers needed.
For a good internet connection, set the value low, at both ends, 3-5 is mostly sufficient. If the connection goes over a link or over 3G/4G mobile internet, you might need a higher value.

The value set in the client will override the setting in the network interface.

Using a NetworkRepeater to allow connection of several operators to one or more radios over WAN or the Internet

Using a NetworkRepeater to allow connection of several operators to one or more radios over WAN or the Internet.
For a good internet connection, set the value low, at both ends, 3-5 is mostly sufficient. If the connection goes over a link or over 3G/4G mobile internet, you might need a higher value.

Be sure that you set the value both in the NetworkRepeater and in all SoftRadio clients.
The value set in the NetworkRepeater will override the value in the Interface.

Connection over a satellite, a special version of the RadioServer is needed along with a NetworkRepeater

Connection over a satellite, a special version of the RadioServer is needed along with a NetworkRepeater.
This will be the hardest case when it comes to jitter. You may test with a low value, but most likely you will need to go up to a value over 10.

Be sure that you set the value both in the NetworkRepeater and in all SoftRadio clients.
The value set in the NetworkRepeater will override the value in the Interface.

More details
Jitter is the variation in the time needed to transfer the audio between the endpoints. If the transfer time varies between 5ms and 55ms the jitter is 50ms If the transfer time varies between 205ms and 255ms the jitter is also 50ms

SoftRadio creates new audio packets every 32 milliseconds. Over a good connection these packets are transferred at a steady pace. But on certain network connections the transfer time is not stable and can vary more or less.

The buffer length value determines how many 32ms audio packets that shall be received and stored in a buffer before the audio starts to play. This buffer contains audio data that can be played while waiting for the next packet to arrive.

If the buffer length is set to 3 this means that audio for 96ms (3×32) is buffered.

In this case, if the next audio packet is late by less than 96ms the buffered audio will be used in the meantime and the audio will bee smooth. However, if it is later (more than 96ms), the buffer will not be enough and SoftRadio then stops the playback of audio and fills up the buffer again before it resumes playing

For a local network a value of 2 or 3 is what we normally recommend. 3 is the default value. For a high quality TCP connection it is usually sufficient with a value between 3 and 5.

The maximum value is 48 which is equivalent to a buffer containing over 2048ms of audio, in other words a data packet can arrive 2 seconds late, and the audio would still not be interrupted.

Special cases
RadioServer
In setups with many SoftRadio clients connected through a RadioServer to the radio (no NetworkRepeater), the connected SoftRadio clients might have different buffer settings. The RadioServer will then select the highest value and send that as an override command to the network interfaces buffer.

Satellite connection
When using SoftRadio over a satellite connection, you always have a combination of a RadioServerin satellite mode at the radio end and a NetworkRepeater at the operator end. In this case the setting in the NetworkRepeater will pass through the RadioServer and override the setting in the network interface by the radio.

Mimer SoftLine
In SoftLine setups, two interfaces back-to-back without PC operators, you need only to set the buffer at the client end. The server will use the same value after the connection is established.

Scroll to Top