Auto-Reconnect of Streaming Radio

  • I use Kodi to stream and play a radio station, on occasions there's a hiccup on either the streaming server or brief internet outage,

    This results in Kodi stopping the audio,

    Is there a way to get it to auto re-connect.. or replay the .STRM file when this happens,?

  • Im running, on a raspberry Pi 3b+ on ethernet, and the source is a .STRM file of the radio stations source, at the moment it is

    LibreElec 8.9.005

    LibreELEC:~ # uname -a

    Linux LibreELEC 4.14.69 #1 SMP Thu Sep 13 16:58:47 BST 2018 armv7l GNU/Linux

    My startup file is as follows

    1. import xbmc
    2. import time
    3. xbmc.executebuiltin("PlayMedia(/storage/.kodi/userdata/playlists/music/Hot919FM.m3u)")
    4. xbmc.executebuiltin("PlayerControl(repeat)")
    5. time.sleep(15)
    6. xbmc.executebuiltin("ActivateScreensaver")

    I was hoping the PlayerControl Repeat would repeat the player to play the radio station again and again,

    but perhaps I should put it in a never ending loop ?