Periodic 2-second dropouts on harbor
  • I've noticed a persistent problem with one station. When streaming with master or dj harbor, at various points, roughly every half hour or so but not on any particular schedule, sometimes more often, audio will cut over to silence. However, I've looked at packet transfer statistics, and the internet IS NOT cutting out at that time, the TCP connection to the harbor is pure and clear and is not dropped. I also have analyzed the TCP stream and there does not appear to be any packet loss, out of sequence packets, retransmissions, or RTT anomalies. It's a perfectly good connection for the whole show. Also, the occurence varies with DJs: some have it more than others.

    Here's an example log:

     
    	 2014/08/03 11:59:59 [master_show_schedule_noise_switch:3] Switch to audio_to_stereo_5690 with transition.

    2014/08/03 12:07:47 [master_show_schedule_noise_switch:3] Switch to show_schedule_noise_switch with forgetful transition.
    2014/08/03 12:07:49 [master_show_schedule_noise_switch:3] Switch to audio_to_stereo_5690 with transition.

    2014/08/03 12:12:35 [master_show_schedule_noise_switch:3] Switch to show_schedule_noise_switch with forgetful transition.
    2014/08/03 12:12:37 [master_show_schedule_noise_switch:3] Switch to audio_to_stereo_5690 with transition.

    2014/08/03 12:20:05 [master_show_schedule_noise_switch:3] Switch to show_schedule_noise_switch with forgetful transition.
    2014/08/03 12:20:07 [master_show_schedule_noise_switch:3] Switch to audio_to_stereo_5690 with transition.

    2014/08/03 12:26:57 [master_show_schedule_noise_switch:3] Switch to show_schedule_noise_switch with forgetful transition.
    2014/08/03 12:26:59 [master_show_schedule_noise_switch:3] Switch to audio_to_stereo_5690 with transition.

    2014/08/03 12:49:58 [master_show_schedule_noise_switch:3] Switch to show_schedule_noise_switch with forgetful transition.
    2014/08/03 12:50:00 [master_show_schedule_noise_switch:3] Switch to audio_to_stereo_5690 with transition.

    2014/08/03 12:56:26 [master_show_schedule_noise_switch:3] Switch to show_schedule_noise_switch with forgetful transition.
    2014/08/03 12:56:28 [master_show_schedule_noise_switch:3] Switch to audio_to_stereo_5690 with transition.

    2014/08/03 12:58:57 [master_show_schedule_noise_switch:3] Switch to show_schedule_noise_switch with forgetful transition.
    2014/08/03 12:58:58 [master_show_schedule_noise_switch:3] Switch to audio_to_stereo_5690 with transition.

    2014/08/03 13:11:50 [master_show_schedule_noise_switch:3] Switch to show_schedule_noise_switch with forgetful transition.
    2014/08/03 13:11:52 [master_show_schedule_noise_switch:3] Switch to audio_to_stereo_5690 with transition.


    Now, it may be the case that certain DJs who tend to have silence and dead air in their shows are seeing these switchovers. I'm looking in the liquidsoap source for master show and ths noise_switch, and can't seem to find if perhaps there's some 2-second timeout implicit there, or how I'd set the threshold and time so that perhaps I can allow a few seconds of silence before switching. Any ideas how that'd be done? The relevant section of code appears to be:




    s = if master_live_stream_port != 0 and master_live_stream_mp != "" then
    master_dj =
    audio_to_stereo(
    input.harbor(id="master_harbor",
    master_live_stream_mp,
    port=master_live_stream_port,
    auth=check_master_dj_client,
    max=40.,
    on_connect=master_dj_connect,
    on_disconnect=master_dj_disconnect))

    ignore(output.dummy(master_dj, fallible=true))

    switch(id="master_show_schedule_noise_switch",
    track_sensitive=false,
    transitions=[transition, transition],
    [({!master_dj_enabled}, master_dj), ({true}, s)]
    )
    else
    s
    end
  • 5 Comments sorted by
  • do not know if this will help but put beside the max=40.,buffer=5.,
    The default buffer is 2 sec for input harbour and the
    •  ignore statement should have take care of that
    • and the transistions transition should let it check twice before moving to next action smoothly


    Anyone reading this a find it funny about my grammar , I make no apology ,Go get a translator.
    "The Problem with education today is that it takes a university degree to switch on a light bulb"
    "You learn from your mistakes but wise people learn from others mistakes avoid Making mistakes there is not sufficient rooms to make them"
    "Innuendo","If's","Assumptions" and "Fear" are for politician.Who,What,where,When and How are for those seeking knowledge and care about Humanity.
    "I might be in Mud but that does not Make me a Wild Hog(pig)"
    “Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius — and a lot of courage to move in the opposite direction.”
    "The only thing that remains constant is change itself"
    May the force be with you,until our path or destiny bring us in tandem.
  • Interesting... :-B
  • Wow guys, that's not terribly helpful. But then I realized, nobody else probably has this problem. The only reason I even notice this bug is because my "silence" is a jukebox. So when it switches over to "silence" I get two seconds of crap before it comes back in to the live stream again.

    I dunno. Maybe I'll try removing that transition. A buffer is not going to help me in this case, but the two-second glitch might indicate a buffer overrun of some kind, since 2 seconds is the default buffer, but that's unlikely because the network trace shows no such thing. Setting the buffer to a larger number would just cause a longer glitch. I might try setting buffer to 0 and see if that helps. Or setting the logfile and maybe there is in fact some buffer problem and it'll show in the log, who knows.

    The deeply frustrating thing is that I cannot duplicate this problem in any kind of test environment, so all this thrashing and experimenting has to happen on a live radio station. That's why I wish someone would be able to explain to me what is happening and what to do to fix it; just guessing and thrashing kind of sucks.
  • So I think this is the solution to all who have the break and then it run right in the Auto Playlist.

    • We all recommend that you try and comment out the noise like this

                  #default = amplify(id="silence_src", 0.00001, noise())

                 well stop doing that as now.Yes stop

    • Conquer the noise to suit your self like this

              default = amplify(id="silence_src", 0.00001, noise())

             autodj=mksafe(playlist(mode="random","myplaylist"))
           default = fallback(track_sensitive=false,[strip_blank(max_blank=30.,threshold=-45.,default),autodj])

    • What this does it will
    1.  will wait 30 seconds before the playlist chips in
    2. the silence will have to be greater than 45db before it chips in  
    make these value how you want them (if say you have classical musics etc.)

    The benefits

    you are doing minimal change to the ls-script so if you read my previous instructions on how to minimize the impact of upgrades then just do this


    • default = amplify(id="silence_src", 0.00001, noise())

      %include "fallback/autodj.liq" #this is the only line you need


    now create any autodj.liq (that is any script you want) in any folder you want link it to the ls_script but you must put this fall back

    default = fallback(track_sensitive=false,[strip_blank(max_blank=30.,threshold=-45.,default),autodj])

    so using this script #from here http://savonet.sourceforge.net/doc-svn/quick_start.html

    ######################################Start##################################

    # Music
    myplaylist = playlist("~/radio/music.m3u")
    # Some jingles
    jingles = playlist("~/radio/jingles.m3u")
    # If something goes wrong, we'll play this
    security = single("~/radio/sounds/default.ogg")

    # Start building the feed with music
    radio = myplaylist
    # Now add some jingles
    radio = random(weights = [1, 4],[jingles, radio])
    # And finally the security


    #please watch for the period behind the numbers below they are float

    default = fallback(track_sensitive=false,[strip_blank(max_blank=30.,threshold=-45.,default),radio])

    #########################################END#####################################

    put this in any folder and link like this

    sudo ln -s /path-to-my-folder/  /path-to-airtime-script-folder/







                
    Post edited by Voisses Tech at 2014-09-08 16:37:12
    Anyone reading this a find it funny about my grammar , I make no apology ,Go get a translator.
    "The Problem with education today is that it takes a university degree to switch on a light bulb"
    "You learn from your mistakes but wise people learn from others mistakes avoid Making mistakes there is not sufficient rooms to make them"
    "Innuendo","If's","Assumptions" and "Fear" are for politician.Who,What,where,When and How are for those seeking knowledge and care about Humanity.
    "I might be in Mud but that does not Make me a Wild Hog(pig)"
    “Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius — and a lot of courage to move in the opposite direction.”
    "The only thing that remains constant is change itself"
    May the force be with you,until our path or destiny bring us in tandem.
  • Where's the buffer setting go?