[FIXED] [2.0.3] Play music from a folder on silence won't work anymore
  • Hi there,

    sadly i had to reinstall Airtime last week (hardware faulty), old version was 2.0.1 i think.
    After installing, i recognized that the change in the ls_script.liq wont work anymore to play some music from a folder on silence.

    What i found until now:
    [ls_script.liq]
    default = amplify(0.1, noise()) <- works
    default = playlist(mode='random', "/srv/allmusic/") <- wont work
    default = playlist("/srv/allmusic/") <- wont work
    default = single("/srv/allmusic/01-somesong.mp3") <- work
    default = playlist("/srv/allmusic/aplaylist.m3u") <- wont work
    default = playlist(mode='random', "/srv/airtime/stor/imported/someband/somealbum/") <- wont work
    default = single("/srv/airtime/stor/imported/someband/somealbum/02-anothersong.mp3") <- work

    Also i noticed if default = playlist, the ls_script.log stays empty (no new entrys) - if default=single or amplify, the log file looks normal

    airtime system check when playing single on silence
    -----------------------------------------
    # airtime-check-system 
    AIRTIME_SERVER_RESPONDING      = OK
    KERNEL_VERSION                 = 2.6.32-38-generic
    MACHINE_ARCHITECTURE           = x86_64
    TOTAL_MEMORY_MBYTES            = 16461884
    TOTAL_SWAP_MBYTES              = UNKNOWN
    AIRTIME_VERSION                = 2.0.3
    OS                             = Ubuntu 10.04.4 LTS x86_64
    CPU                            = Intel(R) Xeon(R) CPU           X3430  @ 2.40GHz
    WEB_SERVER                     = Apache/2.2.14 (Ubuntu)
    PLAYOUT_ENGINE_PROCESS_ID      = 16683
    PLAYOUT_ENGINE_RUNNING_SECONDS = 10
    PLAYOUT_ENGINE_MEM_PERC        = 0.0%
    PLAYOUT_ENGINE_CPU_PERC        = 0.0%
    LIQUIDSOAP_PROCESS_ID          = 16688
    LIQUIDSOAP_RUNNING_SECONDS     = 10
    LIQUIDSOAP_MEM_PERC            = 0.1%
    LIQUIDSOAP_CPU_PERC            = 0.0%
    MEDIA_MONITOR_PROCESS_ID       = 1201
    MEDIA_MONITOR_RUNNING_SECONDS  = 59480
    MEDIA_MONITOR_MEM_PERC         = 0.0%
    MEDIA_MONITOR_CPU_PERC         = 0.0%
    RABBITMQ_PROCESS_ID            = 1433
    RABBITMQ_RUNNING_SECONDS       = 59478
    RABBITMQ_MEM_PERC              = 0.1%
    RABBITMQ_CPU_PERC              = 0.0%
    -- Your installation of Airtime looks OK!


    airtime system check when playing playlist on silence
    -----------------------------------------
    AIRTIME_SERVER_RESPONDING      = OK
    KERNEL_VERSION                 = 2.6.32-38-generic
    MACHINE_ARCHITECTURE           = x86_64
    TOTAL_MEMORY_MBYTES            = 16461884
    TOTAL_SWAP_MBYTES              = UNKNOWN
    AIRTIME_VERSION                = 2.0.3
    OS                             = Ubuntu 10.04.4 LTS x86_64
    CPU                            = Intel(R) Xeon(R) CPU           X3430  @ 2.40GHz
    WEB_SERVER                     = Apache/2.2.14 (Ubuntu)
    PLAYOUT_ENGINE_PROCESS_ID      = 16860
    PLAYOUT_ENGINE_RUNNING_SECONDS = 15
    PLAYOUT_ENGINE_MEM_PERC        = 0.0%
    PLAYOUT_ENGINE_CPU_PERC        = 0.0%
    LIQUIDSOAP_PROCESS_ID          = FAILED
    LIQUIDSOAP_RUNNING_SECONDS     = -1
    LIQUIDSOAP_MEM_PERC            = 0%
    LIQUIDSOAP_CPU_PERC            = 0%
    MEDIA_MONITOR_PROCESS_ID       = 1201
    MEDIA_MONITOR_RUNNING_SECONDS  = 59701
    MEDIA_MONITOR_MEM_PERC         = 0.0%
    MEDIA_MONITOR_CPU_PERC         = 0.1%
    RABBITMQ_PROCESS_ID            = 1433
    RABBITMQ_RUNNING_SECONDS       = 59699
    RABBITMQ_MEM_PERC              = 0.1%
    RABBITMQ_CPU_PERC              = 0.0%

    -- There appears to be a problem with your Airtime installation.





    Any ideas what i did wrong?

    Regards,
    Andreas


    Post edited by Andreas Bosl at 2012-05-08 10:21:25
  • 7 Comments sorted by
  • Vote Up0Vote Down Albert FRAlbert FR
    Posts: 1,978Member, Airtime Moderator
    that's seems to be normal ;)
    your ls_script is bugged
    search ls_scrip on this forum you can see a lot of examples who explain how to do that correctly
  • Hi Albert,

    thanks for your reply.

    only thing i did is adding one of the lines above and commenting the original lines.
    As i remember i did the same with the old version of Airtime.

    Regards

    EDIT:
    Only usefull i found is http://forum.sourcefabric.org/discussion/13909 where it reads
    default = playlist(mode='random', "/srv/airtime/stor/") :-( - also dont work

    i don't get the idea where the error inside the ls_script should be... i only changed inside line 37/38
    working:
    .....
    server.register(namespace="vars", "bootup_time", fun (s) -> begin time := s s end)
    server.register(namespace="streams", "connection_status", fun (s) -> begin "1:#{!s1_connected},2:#{!s2_connected},3:#{!s3_connected}" end)

    #default = amplify(0.1, noise())
    default = single("/srv/music/01-Pirates-216kbps.mp3")
    default = rewrite_metadata([("artist","Airtime"), ("title", "offline")],default)

    s = fallback(track_sensitive=true, [queue, default])
    s = on_metadata(notify, s)
    ....

    not working:
    ....
    server.register(namespace="vars", "bootup_time", fun (s) -> begin time := s s end)
    server.register(namespace="streams", "connection_status", fun (s) -> begin "1:#{!s1_connected},2:#{!s2_connected},3:#{!s3_connected}" end)


    #default = amplify(0.1, noise())
    default = playlist(mode='random', "/srv/music/")
    default = rewrite_metadata([("artist","Airtime"), ("title", "offline")],default)

    s = fallback(track_sensitive=true, [queue, default])
    s = on_metadata(notify, s)
    .....





    Post edited by Andreas Bosl at 2012-05-03 07:10:30
  • Here's what I use, Andreas:

    ls_script.liq before modifications:
    default = amplify(0.00001, noise())
    default = rewrite_metadata([("artist","Airtime"), ("title", "offline")],default)

    After modification:
    #default = amplify(0.00001, noise())

    #default = rewrite_metadata([("artist","Airtime"), ("title", "offline")],default)
    default = playlist(mode='randomize', "/srv/airtime/stor")

    Hope this helps.
  • Hi Wade,

    sorry for the late reply - was out of the office.
    Also tested your line - same result :( nothing is on air...
    I remember i did the change exactly as you before we had the hardware problem and everything worked...
    What version of Airtime you re using?

    Regards
  • Vote Up0Vote Down Albert FRAlbert FR
    Posts: 1,978Member, Airtime Moderator
    my ls_script correct (with hard crossfade) :

    #default = amplify(0.00001, noise())
    #default = rewrite_metadata([("artist","Airtime"), ("title", "offline")],default)

    #s = fallback(track_sensitive=false, [queue, default])

    drops = playlist(mode='randomize',reload=1,reload_mode="rounds", "/srv/airtime/Drops/")
    music = playlist(mode='randomize',reload=1,reload_mode="rounds", "/srv/airtime/Musiques/")
    jingles = playlist(mode='randomize',reload=1,reload_mode="rounds", "/srv/airtime/Jingles/")
    default = rotate(weights=[1,3,1,3], [jingles, music,drops,music])

    def crossfade(s)
      #duration is automatically overwritten by metadata fields passed in
      #with audio
      s = fade.in(type="log", duration=0., s)
      s = fade.out(type="log", duration=0., s)
      fader = fun (a,b) -> add(normalize=false,[b,a])
      cross(fader,s)
    end

    s = fallback(track_sensitive=false, [queue, default])
    enable_replaygain_metadata ()
    s = amplify(1.,override="replay_gain",s)

    s = on_metadata(notify, s)
    s = crossfade(s)
    Post edited by Albert FR at 2012-05-08 05:38:35
  • FIXED!!!
    dont know why your code wont work for me :(
    BUT when i m using
    default = playlist.safe(mode='randomize', "/srv/airtime/stor")

    everything works... strange - didnt have to use .safe it before. Maybe i missed some changelog.

    Thanks for all the help!!

    Best regards,
    Andreas
  • Reply to @Andreas+Bosl:I'm using 2.0.3 on my production server - the one from which I listed the modified script.