Encoder Connections

This section explains how to add and configure server connections for the built-in encoder.

Management of connections is done on the Connections tab of the Encoder configuration page in either the standalone configuration app or the live configuration.

In addition to regular connections to Shoutcast or Icecast servers, mAirList supports some additional (virtual) connection types, which are covered at the end of this section.

Shoutcast/Icecast

To add a new connection to a Shoutcast or Icecast server, click Add and select the appropriate type. The configuration dialog for the new connection will appear.

Server

On the first tab, we configure the server connection and stream format.

Connection Parameters

These are the general server connection parameters. You should have received this information from your streaming provider; or enter your own values in case of a self-hosted server.

  • Host name or IP and Port: Enter the correct host name or IP address (not a URL!), and port number, for your server.
  • User: Some servers require you to specify a user name. Most of the time this field can be left blank, in which case the default user source wil be used.
  • Password: Enter the source password as configured in your server.
  • Stream ID: (Shoutcast V2 only) When using a Shoutcast V2 server, enter the Stream ID, or leave this field blank to use the default Stream ID (1).
  • Moint Point: (Icecast only) For Icecast servers, enter the mount point for your stream.

Stream Format

In the section section of the Server tab, the format, bitrate and stereo mode of your stream can be adjusted.

For Shoutcast servers, the only supported format is MP3.

For Icecast servers, the following formats are supported: MP3, Ogg Vorbis, Opus, FLAC.

The actual encoding is done with the help of a command line encoder. The appropriate encoders (lame.exe, oggenc.exe, opusenc.exe, flac.exe) are included in the distribution.

mAirList will call these encoders with the correct parameters to receive PCM data on STDIN, encode it according to the bitrate/mode settings, and send back encoded data on STDOUT.

For example, for MP3 (using lame.exe), 128kbit, joint stereo, and the encoder running at a samplerate of 48000, the command line will be:

lame.exe -r -s 48000 -b 128 -m j - -

If you want to tweak this command line with additional parameters, you can enter these into the Encoder options field. mAirList will insert the parameters just before the - - part of the command line.

For example, if you want to force LAME to create a high quality stream, enter -h into the Encoder options field, and the resulting command line will be:

lame.exe -r -s 48000 -b 128 -m j -h - -

The Encoder options field can also be used to use 3rd party command line encoders, even for stream formats not supported out of the box (e.g. AAC, using the 3rd party enc_aacplus.exe encoder).

To use a custom 3rd part command line encoder, proceed as follows:

  • In the Audio Format dropdown, select “Custom” from the list.
  • An empty text field will appear next to the dropdown. Enter the correct MIME type for your audio format, e.g. audio/aacp.
  • In the Encoder options field, enter the full filename and parameters for your command line options; the parameters must be set up in a way so that raw PCM data (at 16bit, stereo, and the sample rate at which the encoder is running, see the Advanced tab below) is received via STDIN, and encoded data is returned via STDOUT.
  • The Bit rate and Stereo mode fields will be ignored.

Settings

On the bottom of the Server page, the behavior of the server connection can be adjusted:

  • Seconds between connect attempts and checks: As soon as the encoder master switch is set to “Connected”, a loop will be started that attempts to establish the server connection, retries if that fails (e.g. because the server is unreachable or the stream is busy), and then periodically check if the connection is still alive. The number entered here is the time between any of these checks/attempts. Note that, due to the nature of TCP, a failed connection may only be detected later than in the period specified here.
  • Seconds before trying to re-establish a list connection: When the server connection is lost, mAirList will wait for the specified number of seconds before trying to reconnect. This setting can be tweaked to enlarge the time window before an (unattended) mAirList process tries to reconnect after purposely “kicking” it from the server.
  • Retrieve listener count: If enabled, mAirList will periodically request the current number of listeners, and display it in the Encoder Status screen object. These requests use the regular XML APIs from Shoutcast/Icecast, so they will only work if the server supports them. This should be the case for the stock Shoutcast and Icecast servers; however some providers use their own implementation of the Shoutcast/Icecast protocols which may not support listener count retrieval.
  • Do not stream, only count listeners: If you are using a network of relayed servers, and you want to include listeners numbers of the relay servers, you can add connections to these servers and check this box – mAirList will not actually send a stream to these servers then, but only use the XML API to retrieve the number of listeners.

Metadata

The settings on the second tab control the transmission of metadata to the streaming server.

Stream Metadata

Enter the stream title and optional other metadata (URL, description, etc.) that should be displayed to the user and in optional directories.

Title Update

Whenever an audio item is started in mAirList, the encoder can update the stream title with the artist, title etc. This is similar to to the Logging feature, but it is built into the encoder connection and does not require setup of a separate logging interface.

Shoutcast and Icecast only support a single text field for the current stream title, so you will want to merge the artist name and the song title into it. This is specified in the Log Format which defaults to %a - %b (“artist - title”). You can use any of the available logging variables.

If a Delay is set, mAirList will wait for the specified number of seconds before sending the new title to the server. This can be used to synchronize the title update with a possible delay due to buffering.

The Character Set will be determined automatically based on your connection type and matches the default configuration of the server types:

  • Shoutcast V1: latin1
  • Shoutcast V2: UTF-8
  • Icecast: latin1 for MP3, UTF-8 for Ogg Vorbis, Opus and FLAC

If, for any reason, your server is configured to expect metadata in a different character set, you can set it manually in the dropdown.

The Item Type Filter determines which items, based on the type set in their properties, should be transmitted at all. For example, you can choose only to display “Music” items, but no jingles etc. Hint: Use the right-click menu to select all or no entries at once.

If the Forward song title updates of relayed streams option is checked, and you are playing a stream through a “Stream” playlist item, or the Stream Monitor, mAirList will transmit all incoming title updates “as is” to the connection.

Regions

If Regionalization is enabled for the encoder, this tab provides control over the downmix sent to this connection. See the Encoder Regionalization chapter for more information.

Sound Processing

In addition to the central sound processing of the encoder module, each encoder connection provides its own DSP chain that you can add DSP plugins to.

See the Sound Processing chapter for a list of supported (built-in or external) DSP plugins and their configuration.

The DSP plugins registered here will be applied after the central DSP plugins, and after region downmix. The signal will always be stereo.

Advanced

The last tab contains the following settings:

  • Custom caption: Enter an optional caption under which this connection should appear in the configuration, System Log, etc.
  • Sample rate: This setting provides optional sample rate conversion for this particular connection, in case it needs to run at a different sample rate than the one specified in the main encoder configuration. The sample rate will both be used for the raw PCM data fed into the command line encoder, as well as the DSP plugins. To disable sample rate conversion and use the default sample rate, leave this field empty.

Integrated Streaming Server

The Integrated Streaming Server provides a Shoutcast (V1) compatible streaming server.

To set up a new server, click Add and select Integrated Streaming Server.

In the connection properties, specify an optional local IP address (if you want have multiple network interfaces and only want the stream to be available on one of them), and the port number. Note that in the Shoutcast V1 protocol, there can only be one stream per port.

The Stream Format settings are similar to those of the regular Shoutcast/Icecast connections, see above.

If Retrieve listener count is checked, the number of listeners will be displayed in the Encoder Status screen object.

For the settings on the Regions, Sound Processing and Advanced tabs, see the Shoutcast/Icecast section above.

Record to File

Additional Local Audio Output