OP25 Missing metadata in Icecast2

ntrlsur

Newbie
Premium Subscriber
Joined
Jan 14, 2018
Messages
18
Reaction score
4
Location
Glen Ellyn,IL
Good evening wise ones. Hoping someone can point me in the right direction. Currently running OP25 on ubuntu 22.04.5 LTS icecast2 version 2.4.4 and Liquidsoap 2.0.2.
I can see the metadata in op25 but its not passing through liquidsoap to my icecast local broadcast

op25 json
Code:
{
    "channels": [
        {
            "name": "STARCOM21",
            "device": "sdr0",
            "trunking_sysname": "STARCOM21",
            "meta_stream_name": "STARCOM21",
            "demod_type": "cqpsk",
            "cqpsk_tracking": true,
            "tracking_threshold": 120,
            "tracking_feedback": 0.75,
            "destination": "udp://127.0.0.1:23456",
            "excess_bw": 0.2,
            "filter_type": "rc",
            "if_rate": 24000,
            "plot": "",
            "symbol_rate": 4800,
            "enable_analog": "off",
            "blacklist": "",
            "whitelist": "trunkPD.whitelist"
        }
    ],
    "devices": [
        {
            "args": "rtl=0",
            "gains": "LNA:39",
            "gain_mode": false,
            "name": "sdr0",
            "offset": 0,
            "ppm": 0.0,
            "rate": 1000000,
            "usable_bw_pct": 0.85,
            "tunable": true
        }
    ],
    "trunking": {
        "module": "tk_p25.py",
        "chans": [
            {
                "nac": "0x145",
                "sysname": "STARCOM21",
                "control_channel_list": "770.95625,773.84375,774.18125,774.43125",
                "whitelist": "",
                "blacklist": "",
                "tgid_tags_file": "tgidall.tags",
                "rid_tags_file": "",
                "tdma_cc": false,
                "crypt_behavior": 2
            }
        ]
    },
    "metadata": {
        "module": "icemeta.py",
        "streams": [
            {
                "stream_name": "stream_0",
                "meta_format_idle": "Scanning...",
                "meta_format_tgid": "[%TGID%]",
                "meta_format_tag":  "[%TGID%] %TAG%",
                "icecastServerAddress": "192.168.2.103",
                "icecastMountpoint": "/STARCOM21",
                "icecastMountExt": "m3u",
                "icecastPass": "password",
                "delay": 0.0
            }
        ]
    },
    "audio": {
        "module": "sockaudio.py",
        "instances": [
            {
                "instance_name": "",
                "device_name": "default",
                "udp_port": 23456,
                "audio_gain": 1.0,
                "number_channels": 1
            },
            {
                "instance_name": "",
                "device_name": "default",
                "udp_port": 23466,
                "audio_gain": 1.0,
                "number_channels": 1
            }
        ]
    },
    "terminal": {
        "module": "terminal.py",
        "#terminal_type": "curses",
        "terminal_type": "http:0.0.0.0:8080",
        "curses_plot_interval": 0.1,
        "http_plot_interval": 1.0,
        "http_plot_directory": "../www/images",
        "tuning_step_large": 1200,
        "tuning_step_small": 100
    }
}

Icecast2 config
Code:
<icecast>
    <!-- location and admin are two arbitrary strings that are e.g. visible
         on the server info page of the icecast web interface
         (server_version.xsl). -->
    <location>Earth</location>
    <admin>icemaster@localhost</admin>

    <!-- IMPORTANT!
         Especially for inexperienced users:
         Start out by ONLY changing all passwords and restarting Icecast.
         For detailed setup instructions please refer to the documentation.
         It's also available here: http://icecast.org/docs/
    -->

    <limits>
        <clients>100</clients>
        <sources>2</sources>
        <queue-size>524288</queue-size>
        <client-timeout>30</client-timeout>
        <header-timeout>15</header-timeout>
        <source-timeout>10</source-timeout>
        <!-- If enabled, this will provide a burst of data when a client
             first connects, thereby significantly reducing the startup
             time for listeners that do substantial buffering. However,
             it also significantly increases latency between the source
             client and listening client.  For low-latency setups, you
             might want to disable this. -->
        <burst-on-connect>1</burst-on-connect>
        <!-- same as burst-on-connect, but this allows for being more
             specific on how much to burst. Most people won't need to
             change from the default 64k. Applies to all mountpoints  -->
        <burst-size>65535</burst-size>
    </limits>

    <authentication>
        <!-- Sources log in with username 'source' -->
        <source-password>password</source-password>
        <!-- Relays log in with username 'relay' -->
        <relay-password>password</relay-password>

        <!-- Admin logs in with the username given below -->
        <admin-user>admin</admin-user>
        <admin-password>password</admin-password>
    </authentication>

    <!--set the mountpoint for a shoutcast source to use, the default if not
         specified is /stream but you can change it here if an alternative is
         wanted or an extension is required -->
       <shoutcast-mount>/STARCOM21</shoutcast-mount>
        <stream-name>Starcom25 Feed</stream-name>
        <stream-description>Illinois Starcom25 public saftey stream</stream-description>
 

    <!-- Uncomment this if you want directory listings -->
    <!--
    <directory>
        <yp-url-timeout>15</yp-url-timeout>
        <yp-url>http://dir.xiph.org/cgi-bin/yp-cgi</yp-url>
    </directory>
    -->

    <!-- This is the hostname other people will use to connect to your server.
         It affects mainly the urls generated by Icecast for playlists and yp
         listings. You MUST configure it properly for YP listings to work!
    -->
    <hostname>op25.ad.carter-black.org</hostname>

    <!-- You may have multiple <listen-socket> elements -->
    <listen-socket>
        <port>8000</port>
        <bind-address>192.168.2.103</bind-address>
    </listen-socket>
    <!--
    <listen-socket>
        <port>8080</port>
    </listen-socket>
    -->
    <!--
    <listen-socket>
        <port>8443</port>
        <ssl>1</ssl>
    </listen-socket>
    -->


    <!-- Global header settings
         Headers defined here will be returned for every HTTP request to Icecast.

         The ACAO header makes Icecast public content/API by default
         This will make streams easier embeddable (some HTML5 functionality needs it).
         Also it allows direct access to e.g. /status-json.xsl from other sites.
         If you don't want this, comment out the following line or read up on CORS.
    -->
    <http-headers>
        <header name="Access-Control-Allow-Origin" value="*" />
    </http-headers>


    <!-- Relaying
         You don't need this if you only have one server.
         Please refer to the documentation for a detailed explanation.
    -->
    <!--<master-server>127.0.0.1</master-server>-->
    <!--<master-server-port>8001</master-server-port>-->
    <!--<master-update-interval>120</master-update-interval>-->
    <!--<master-password>password</master-password>-->

    <!-- setting this makes all relays on-demand unless overridden, this is
         useful for master relays which do not have <relay> definitions here.
         The default is 0 -->
    <!--<relays-on-demand>1</relays-on-demand>-->

    <!--
    <relay>
        <server>127.0.0.1</server>
        <port>8080</port>
        <mount>/example.ogg</mount>
        <local-mount>/different.ogg</local-mount>
        <on-demand>0</on-demand>

        <relay-shoutcast-metadata>0</relay-shoutcast-metadata>
    </relay>
    -->


    <!-- Mountpoints
         Only define <mount> sections if you want to use advanced options,
         like alternative usernames or passwords
    -->

    <!-- Default settings for all mounts that don't have a specific <mount type="normal">.
    -->
    <!--
    <mount type="default">
        <public>0</public>
        <intro>/server-wide-intro.ogg</intro>
        <max-listener-duration>3600</max-listener-duration>
        <authentication type="url">
                <option name="mount_add" value="http://auth.example.org/stream_start.php"/>
        </authentication>
        <http-headers>
                <header name="foo" value="bar" />
        </http-headers>
    </mount>
    -->

    <!-- Normal mounts -->
    <!--
    <mount type="normal">
        <mount-name>/example-complex.ogg</mount-name>

        <username>othersource</username>
        <password>password</password>

        <max-listeners>1</max-listeners>
        <dump-file>/tmp/dump-example1.ogg</dump-file>
        <burst-size>65536</burst-size>
        <fallback-mount>/example2.ogg</fallback-mount>
        <fallback-override>1</fallback-override>
        <fallback-when-full>1</fallback-when-full>
        <intro>/example_intro.ogg</intro>
        <hidden>1</hidden>
        <public>1</public>
        <authentication type="htpasswd">
                <option name="filename" value="myauth"/>
                <option name="allow_duplicate_users" value="0"/>
        </authentication>
        <http-headers>
                <header name="Access-Control-Allow-Origin" value="http://webplayer.example.org" />
                <header name="baz" value="quux" />
        </http-headers>
        <on-connect>/home/icecast/bin/stream-start</on-connect>
        <on-disconnect>/home/icecast/bin/stream-stop</on-disconnect>
    </mount>
    -->

    <!--
    <mount type="normal">
        <mount-name>/auth_example.ogg</mount-name>
        <authentication type="url">
            <option name="mount_add"       value="http://myauthserver.net/notify_mount.php"/>
            <option name="mount_remove"    value="http://myauthserver.net/notify_mount.php"/>
            <option name="listener_add"    value="http://myauthserver.net/notify_listener.php"/>
            <option name="listener_remove" value="http://myauthserver.net/notify_listener.php"/>
            <option name="headers"         value="x-pragma,x-token"/>
            <option name="header_prefix"   value="ClientHeader."/>
        </authentication>
    </mount>
    -->

    <fileserve>1</fileserve>

    <paths>
        <!-- basedir is only used if chroot is enabled -->
        <basedir>/usr/share/icecast2</basedir>

        <!-- Note that if <chroot> is turned on below, these paths must both
             be relative to the new root, not the original root -->
        <logdir>/var/log/icecast2</logdir>
        <webroot>/usr/share/icecast2/web</webroot>
        <adminroot>/usr/share/icecast2/admin</adminroot>
        <!-- <pidfile>/usr/share/icecast2/icecast.pid</pidfile> -->

        <!-- Aliases: treat requests for 'source' path as being for 'dest' path
             May be made specific to a port or bound address using the "port"
             and "bind-address" attributes.
          -->
        <!--
        <alias source="/foo" destination="/bar"/>
        -->
        <!-- Aliases: can also be used for simple redirections as well,
             this example will redirect all requests for http://server:port/ to
             the status page
        -->
        <alias source="/" destination="/status.xsl"/>
        <!-- The certificate file needs to contain both public and private part.
             Both should be PEM encoded.
        <ssl-certificate>/usr/share/icecast2/icecast.pem</ssl-certificate>
        -->
    </paths>

    <logging>
        <accesslog>access.log</accesslog>
        <errorlog>error.log</errorlog>
        <!-- <playlistlog>playlist.log</playlistlog> -->
        <loglevel>3</loglevel> <!-- 4 Debug, 3 Info, 2 Warn, 1 Error -->
        <logsize>10000</logsize> <!-- Max size of a logfile -->
        <!-- If logarchive is enabled (1), then when logsize is reached
             the logfile will be moved to [error|access|playlist].log.DATESTAMP,
             otherwise it will be moved to [error|access|playlist].log.old.
             Default is non-archive mode (i.e. overwrite)
        -->
        <!-- <logarchive>1</logarchive> -->
    </logging>

    <security>
        <chroot>0</chroot>
        <!--
        <changeowner>
            <user>nobody</user>
            <group>nogroup</group>
        </changeowner>
        -->
    </security>
</icecast>

Code:
#!/usr/bin/liquidsoap

# Example liquidsoap streaming from op25 to icecast
# (c) 2019-2021 gnorbury@bondcar.com, wllmbecks@gmail.com
#

set("log.stdout", false)
set("log.file", true)
set("log.level", 3)

# Make the native sample rate compatible with op25
set("frame.audio.samplerate", 8000)

input = mksafe(input.external(buffer=0.25, channels=2, samplerate=8000, restart_on_error=false, "./audio.py -x 1.5 -s"))
# Consider increasing the buffer value on slow systems such as RPi3. e.g. buffer=0.25
# Longer buffer results in less choppy audio but at the expense of increased latency.



# OPTIONAL AUDIO SIGNAL PROCESSING BLOCKS
# Uncomment to enable
#
# High pass filter
#input = filter.iir.butterworth.high(frequency = 200.0, order = 4, input)

# Low pass filter
#input = filter.iir.butterworth.low(frequency = 3250.0, order = 4, input)

# Compression
input = compress(input, attack = 2.0, gain = 0.0, knee = 13.0, ratio = 2.0, release = 12.3, threshold = -18.0)

# Normalization
input = normalize(input, gain_max = 6.0, gain_min = -6.0, target = -16.0, threshold = -65.0)



# LOCAL AUDIO OUTPUT
# Uncomment the appropriate line below to enable local sound
#
# Default audio subsystem
out (input)
#
# PulseAudio
#output.pulseaudio(input)
#
# ALSA
#output.alsa(input)



# ICECAST STREAMING
# Uncomment to enable output to an icecast server
# Change the "host", "password", and "mount" strings appropriately first!
# For metadata to work properly, the host address given here MUST MATCH the address in op25's meta.json file
#
output.icecast(%mp3(bitrate=16, samplerate=22050, stereo=false), description="STARCOM21", genre="Public Safety", url="", fallible=false, icy_metadata="true", host="192.168.2.103", port=8000, mount="STARCOM21", password="password", mean(input))

Everything stands up properly. Viewing the op25 site I can see the meta data and everything looks fine. The icecast doesn't show the metadata coming in. I know I am missing something but I can't figure out what it is I am missing.. Can someone provide me a second set of eyes to show me what I am missing?
 

ntrlsur

Newbie
Premium Subscriber
Joined
Jan 14, 2018
Messages
18
Reaction score
4
Location
Glen Ellyn,IL
Wrong stream name
Thanks. I updated the stream_name and restarted but still nothing. My Broadcastify boxes work great with no issue sending the alphatags as metadata. But for some reason I can't seem to get it working for my personal / dev setup. Is there anyway to see if the data is actually being sent? my liquid soap log is just filled with this crap
Code:
2026/02/28 15:12:24 [mksafe:3] Switch to input.external.rawaudio_0 with transition.
2026/02/28 15:12:25 [clock.pulseaudio:2] We must catchup 1.66 seconds!
2026/02/28 15:12:26 [clock.pulseaudio:2] We must catchup 1.67 seconds!
2026/02/28 15:12:27 [mksafe:3] Switch to safe_blank with transition.
2026/02/28 15:12:27 [clock.pulseaudio:2] We must catchup 1.68 seconds!
2026/02/28 15:12:28 [clock.pulseaudio:2] We must catchup 1.70 seconds!
2026/02/28 15:12:29 [clock.pulseaudio:2] We must catchup 1.67 seconds!
2026/02/28 15:12:30 [clock.pulseaudio:2] We must catchup 1.68 seconds!
 

wgbecks

Active Member
Joined
Jan 17, 2005
Messages
1,172
Reaction score
422
Location
NE Wisconsin
Thanks. I updated the stream_name and restarted but still nothing. My Broadcastify boxes work great with no issue sending the alphatags as metadata. But for some reason I can't seem to get it working for my personal / dev setup. Is there anyway to see if the data is actually being sent? my liquid soap log is just filled with this crap
Code:
2026/02/28 15:12:24 [mksafe:3] Switch to input.external.rawaudio_0 with transition.
2026/02/28 15:12:25 [clock.pulseaudio:2] We must catchup 1.66 seconds!
2026/02/28 15:12:26 [clock.pulseaudio:2] We must catchup 1.67 seconds!
2026/02/28 15:12:27 [mksafe:3] Switch to safe_blank with transition.
2026/02/28 15:12:27 [clock.pulseaudio:2] We must catchup 1.68 seconds!
2026/02/28 15:12:28 [clock.pulseaudio:2] We must catchup 1.70 seconds!
2026/02/28 15:12:29 [clock.pulseaudio:2] We must catchup 1.67 seconds!
2026/02/28 15:12:30 [clock.pulseaudio:2] We must catchup 1.68 seconds!
Liquidsoap does not pass the metadata to the Icecast server. This is a function of icemeta.py. You'll need to make a couple of
edits as explained below....

(1) Remove the forward slash ("/") from the icecastMounpoint text.
(2) Correct the icecastSeverAddress to include the port number that your Icecast server is listening on.

Note that you might possibly need to substitute "192.168.2.103" with "localhost" in both your op25.liq and cfg.json scripts
and assuming that Icecast2 is running on the same host as op25 and Liqidsoap.

IE:


JSON:
    },
    "metadata": {
        "module": "icemeta.py",
        "streams": [
            {
                "stream_name": "stream_0",
                "meta_format_idle": "Scanning...",
                "meta_format_tgid": "[%TGID%]",
                "meta_format_tag":  "[%TGID%] %TAG%",
                [B][COLOR=rgb(184, 49, 47)]"icecastServerAddress": "192.168.2.103:8000",
                "icecastMountpoint": "STARCOM21",[/COLOR][/B]
                "icecastMountExt": "m3u",
                "icecastPass": "password",
                "delay": 0.0
            }
 

ntrlsur

Newbie
Premium Subscriber
Joined
Jan 14, 2018
Messages
18
Reaction score
4
Location
Glen Ellyn,IL
So as it turns out. I was digging and digging through my log files and noticed that liquidsoap is trying to login to update the metadata using the username "source". The username "source" by default doesn't have permissions to update the metadata. I ended modifying the icecast.xml file and adding "source" as an admin. A quick reboot of icecast and metadata is working. I looked back in my notes for icecast setups and I didn't see anything about making sure the "source" user had admin to update metadata. I wanted to close the loop on this to make sure that if anyone else ran into the same issue then there is at least a breadcumb out here.
 

wgbecks

Active Member
Joined
Jan 17, 2005
Messages
1,172
Reaction score
422
Location
NE Wisconsin
So as it turns out. I was digging and digging through my log files and noticed that liquidsoap is trying to login to update the metadata using the username "source". The username "source" by default doesn't have permissions to update the metadata. I ended modifying the icecast.xml file and adding "source" as an admin. A quick reboot of icecast and metadata is working. I looked back in my notes for icecast setups and I didn't see anything about making sure the "source" user had admin to update metadata. I wanted to close the loop on this to make sure that if anyone else ran into the same issue then there is at least a breadcumb out here.
Not correct. I missed it in your original post, but in looking back, I see that you added the icy_metadata="true" parameter into your output.icecast line that was responsible for what you were seeing seen in the log. OP25 does not provide a vehicle to pass metadata to Liquidsoap, but instead, it uses icemeta.py to pass the metadata directly to the Icecast server and whereby user configuration is done within
the icemeta.py module of your cfg.json file.

New installations of op25 supply an example op25.liq file into the /apps folder that's intended to be used as a template that does include
the icy_metada="true" parameter. Regarding Icecast2, nothing special needs to be done upon installation other than to change the default "hackme" passwords, or unless you desire to permit more sources and to add or change ports.
 

ntrlsur

Newbie
Premium Subscriber
Joined
Jan 14, 2018
Messages
18
Reaction score
4
Location
Glen Ellyn,IL
I hate to have to disagree with you. When I configure my icecast.xml with an admin username of admin what shows up in the logs is
Code:
[2026-03-01  00:19:05] INFO admin/admin_handle_request Bad or missing password on mount modification admin request (command: metadata)
When I configure my icecast.xml with an admin user of source I get
Code:
[2026-03-01  00:22:19] INFO admin/command_metadata Metadata on mountpoint /STARCOM21 changed to "[2619] Dispatch [DU DPSO F1] "

Which shows that the admin user needs to be source at least for my configuration.

This is the full configuration for everything.
icecast.xml

Code:
<icecast>
    <!-- location and admin are two arbitrary strings that are e.g. visible
         on the server info page of the icecast web interface
         (server_version.xsl). -->
    <location>Illinois</location>
    <admin>me@who.com</admin>

    <!-- IMPORTANT!
         Especially for inexperienced users:
         Start out by ONLY changing all passwords and restarting Icecast.
         For detailed setup instructions please refer to the documentation.
         It's also available here: http://icecast.org/docs/
    -->

    <limits>
        <clients>100</clients>
        <sources>4</sources>
        <queue-size>524288</queue-size>
        <client-timeout>30</client-timeout>
        <header-timeout>15</header-timeout>
        <source-timeout>10</source-timeout>
        <!-- If enabled, this will provide a burst of data when a client
             first connects, thereby significantly reducing the startup
             time for listeners that do substantial buffering. However,
             it also significantly increases latency between the source
             client and listening client.  For low-latency setups, you
             might want to disable this. -->
        <burst-on-connect>1</burst-on-connect>
        <!-- same as burst-on-connect, but this allows for being more
             specific on how much to burst. Most people won't need to
             change from the default 64k. Applies to all mountpoints  -->
        <burst-size>65535</burst-size>
    </limits>

    <authentication>
        <!-- Sources log in with username 'source' -->
        <source-password>password</source-password>
        <!-- Relays log in with username 'relay' -->
        <relay-password>password</relay-password>

        <!-- Admin logs in with the username given below -->
        <admin-user>source</admin-user>
        <admin-password>password</admin-password>
    </authentication>

    <!--set the mountpoint for a shoutcast source to use, the default if not
         specified is /stream but you can change it here if an alternative is
         wanted or an extension is required -->
       <shoutcast-mount>/STARCOM21</shoutcast-mount>
        <stream-name>Starcom25 Feed</stream-name>
        <stream-description>Illinois Starcom25 public saftey stream</stream-description>
 

    <!-- Uncomment this if you want directory listings -->
    <!--
    <directory>
        <yp-url-timeout>15</yp-url-timeout>
        <yp-url>http://dir.xiph.org/cgi-bin/yp-cgi</yp-url>
    </directory>
    -->

    <!-- This is the hostname other people will use to connect to your server.
         It affects mainly the urls generated by Icecast for playlists and yp
         listings. You MUST configure it properly for YP listings to work!
    -->
    <hostname>192.168.2.103</hostname>

    <!-- You may have multiple <listen-socket> elements -->
    <listen-socket>
        <port>8000</port>
        <bind-address>0.0.0.0</bind-address>
    </listen-socket>
    <!--
    <listen-socket>
        <port>8080</port>
    </listen-socket>
    -->
    <!--
    <listen-socket>
        <port>8443</port>
        <ssl>1</ssl>
    </listen-socket>
    -->


    <!-- Global header settings
         Headers defined here will be returned for every HTTP request to Icecast.

         The ACAO header makes Icecast public content/API by default
         This will make streams easier embeddable (some HTML5 functionality needs it).
         Also it allows direct access to e.g. /status-json.xsl from other sites.
         If you don't want this, comment out the following line or read up on CORS.
    -->
    <http-headers>
        <header name="Access-Control-Allow-Origin" value="*" />
    </http-headers>


    <!-- Relaying
         You don't need this if you only have one server.
         Please refer to the documentation for a detailed explanation.
    -->
    <!--<master-server>127.0.0.1</master-server>-->
    <!--<master-server-port>8001</master-server-port>-->
    <!--<master-update-interval>120</master-update-interval>-->
    <!--<master-password>password</master-password>-->

    <!-- setting this makes all relays on-demand unless overridden, this is
         useful for master relays which do not have <relay> definitions here.
         The default is 0 -->
    <!--<relays-on-demand>1</relays-on-demand>-->

    <!--
    <relay>
        <server>127.0.0.1</server>
        <port>8080</port>
        <mount>/example.ogg</mount>
        <local-mount>/different.ogg</local-mount>
        <on-demand>0</on-demand>

        <relay-shoutcast-metadata>0</relay-shoutcast-metadata>
    </relay>
    -->


    <!-- Mountpoints
         Only define <mount> sections if you want to use advanced options,
         like alternative usernames or passwords
    -->

    <!-- Default settings for all mounts that don't have a specific <mount type="normal">.
    -->
    <!--
    <mount type="default">
        <public>0</public>
        <intro>/server-wide-intro.ogg</intro>
        <max-listener-duration>3600</max-listener-duration>
        <authentication type="url">
                <option name="mount_add" value="http://auth.example.org/stream_start.php"/>
        </authentication>
        <http-headers>
                <header name="foo" value="bar" />
        </http-headers>
    </mount>
    -->

    <!-- Normal mounts -->
    <!--
    <mount type="normal">
        <mount-name>/example-complex.ogg</mount-name>

        <username>othersource</username>
        <password>password</password>

        <max-listeners>1</max-listeners>
        <dump-file>/tmp/dump-example1.ogg</dump-file>
        <burst-size>65536</burst-size>
        <fallback-mount>/example2.ogg</fallback-mount>
        <fallback-override>1</fallback-override>
        <fallback-when-full>1</fallback-when-full>
        <intro>/example_intro.ogg</intro>
        <hidden>1</hidden>
        <public>1</public>
        <authentication type="htpasswd">
                <option name="filename" value="myauth"/>
                <option name="allow_duplicate_users" value="0"/>
        </authentication>
        <http-headers>
                <header name="Access-Control-Allow-Origin" value="http://webplayer.example.org" />
                <header name="baz" value="quux" />
        </http-headers>
        <on-connect>/home/icecast/bin/stream-start</on-connect>
        <on-disconnect>/home/icecast/bin/stream-stop</on-disconnect>
    </mount>
    -->

    <!--
    <mount type="normal">
        <mount-name>/auth_example.ogg</mount-name>
        <authentication type="url">
            <option name="mount_add"       value="http://myauthserver.net/notify_mount.php"/>
            <option name="mount_remove"    value="http://myauthserver.net/notify_mount.php"/>
            <option name="listener_add"    value="http://myauthserver.net/notify_listener.php"/>
            <option name="listener_remove" value="http://myauthserver.net/notify_listener.php"/>
            <option name="headers"         value="x-pragma,x-token"/>
            <option name="header_prefix"   value="ClientHeader."/>
        </authentication>
    </mount>
    -->

    <fileserve>1</fileserve>

    <paths>
        <!-- basedir is only used if chroot is enabled -->
        <basedir>/usr/share/icecast2</basedir>

        <!-- Note that if <chroot> is turned on below, these paths must both
             be relative to the new root, not the original root -->
        <logdir>/var/log/icecast2</logdir>
        <webroot>/usr/share/icecast2/web</webroot>
        <adminroot>/usr/share/icecast2/admin</adminroot>
        <!-- <pidfile>/usr/share/icecast2/icecast.pid</pidfile> -->

        <!-- Aliases: treat requests for 'source' path as being for 'dest' path
             May be made specific to a port or bound address using the "port"
             and "bind-address" attributes.
          -->
        <!--
        <alias source="/foo" destination="/bar"/>
        -->
        <!-- Aliases: can also be used for simple redirections as well,
             this example will redirect all requests for http://server:port/ to
             the status page
        -->
        <alias source="/" destination="/status.xsl"/>
        <!-- The certificate file needs to contain both public and private part.
             Both should be PEM encoded.
        <ssl-certificate>/usr/share/icecast2/icecast.pem</ssl-certificate>
        -->
    </paths>

    <logging>
        <accesslog>access.log</accesslog>
        <errorlog>error.log</errorlog>
        <!-- <playlistlog>playlist.log</playlistlog> -->
        <loglevel>3</loglevel> <!-- 4 Debug, 3 Info, 2 Warn, 1 Error -->
        <logsize>10000</logsize> <!-- Max size of a logfile -->
        <!-- If logarchive is enabled (1), then when logsize is reached
             the logfile will be moved to [error|access|playlist].log.DATESTAMP,
             otherwise it will be moved to [error|access|playlist].log.old.
             Default is non-archive mode (i.e. overwrite)
        -->
        <!-- <logarchive>1</logarchive> -->
    </logging>

    <security>
        <chroot>0</chroot>
        <!--
        <changeowner>
            <user>nobody</user>
            <group>nogroup</group>
        </changeowner>
        -->
    </security>
</icecast>

op25.json
Code:
{
    "channels": [
        {
            "name": "STARCOM21",
            "device": "sdr0",
            "trunking_sysname": "STARCOM21",
            "meta_stream_name": "STARCOM21",
            "demod_type": "cqpsk",
            "cqpsk_tracking": true,
            "tracking_threshold": 120,
            "tracking_feedback": 0.75,
            "destination": "udp://127.0.0.1:23456",
            "excess_bw": 0.2,
            "filter_type": "rc",
            "if_rate": 24000,
            "plot": "",
            "symbol_rate": 4800,
            "enable_analog": "off",
            "blacklist": "",
            "whitelist": "trunkPD.whitelist"
        }
    ],
    "devices": [
        {
            "args": "rtl=0",
            "gains": "LNA:39",
            "gain_mode": false,
            "name": "sdr0",
            "offset": 0,
            "ppm": 0.0,
            "rate": 1000000,
            "usable_bw_pct": 0.85,
            "tunable": true
        }
    ],
    "trunking": {
        "module": "tk_p25.py",
        "chans": [
            {
                "nac": "0x145",
                "sysname": "STARCOM21",
                "control_channel_list": "770.95625,773.84375,774.18125,774.43125",
                "whitelist": "",
                "blacklist": "",
                "tgid_tags_file": "tgidall.tags",
                "rid_tags_file": "",
                "tdma_cc": false,
                "crypt_behavior": 2
            }
        ]
    },
    "metadata": {
        "module": "icemeta.py",
        "streams": [
            {
                "stream_name": "STARCOM21",
                "meta_format_idle": "Scanning...",
                "meta_format_tgid": "[%TGID%]",
                "meta_format_tag":  "[%TGID%] %TAG%",
                "icecastServerAddress": "localhost:8000",
                "icecastMountpoint": "STARCOM21",
                "icecastMountExt": "m3u",
                "icecastPass": "password",
                "delay": 0.0
            }
        ]
    },
    "audio": {
        "module": "sockaudio.py",
        "instances": [
            {
                "instance_name": "",
                "device_name": "default",
                "udp_port": 23456,
                "audio_gain": 1.0,
                "number_channels": 1
            },
            {
                "instance_name": "",
                "device_name": "default",
                "udp_port": 23466,
                "audio_gain": 1.0,
                "number_channels": 1
            }
        ]
    },
    "terminal": {
        "module": "terminal.py",
        "#terminal_type": "curses",
        "terminal_type": "http:0.0.0.0:8080",
        "curses_plot_interval": 0.1,
        "http_plot_interval": 1.0,
        "http_plot_directory": "../www/images",
        "tuning_step_large": 1200,
        "tuning_step_small": 100
    }
}
 

boatbod

Member
Joined
Mar 3, 2007
Messages
3,668
Reaction score
1,063
Location
Talbot Co, MD
If you want to see what op25 is outputting for metadata you can turn logging up to "-v 11" and then look in stderr.2 for "metadata update:" and "metadata result:"
 
Top