Hi Drew,
Thanks for your suggestion.
I was about to try your script verbatim, but I have realised that my issue
may be specific to the use of the requests queue, which your script doesn't
appear to use.
The problem doesn't appear to be related to the input, but rather the use
of the queue itself. In particular, if I have the following:
---
requests = request.queue(id="queue")
melb_source = requests
output.icecast(%mp3(stereo=false, bitrate=96,samplerate=32000),
host = "127.0.0.1", port = 8000,
url="http://www.2me.com.au",
public=false,
password = "<removed>", mount = "2me-melbads",
description = "Radio 2ME",
mean(melb_source),
fallible=true)
---
The queue remains empty initially, but LiquidSoap quits when the queue is
emptied:
---
2015/07/06 09:35:05 [2me-melbads:3] Connecting mount 2me-melbads for
[email protected]...
2015/07/06 09:35:05 [2me-melbads:3] Connection setup was successful.
2015/07/06 09:35:08 [decoder.ogg:5] Reached last page of logical stream
5069a2ff
2015/07/06 09:35:10 [decoder.ogg:5] All data from stream 5069a2ff has been
decoded
2015/07/06 09:35:10 [decoder:4] Decoding "/tmp/test.ogg" ended:
Ogg.End_of_stream.
2015/07/06 09:35:10 [clock.wallclock_main:2] Source dummy failed while
streaming: Ogg.End_of_stream!
2015/07/06 09:35:10 [dummy:4] Activations changed: static=[], dynamic=[].
2015/07/06 09:35:10 [source:4] Source dummy gets down.
2015/07/06 09:35:10 [queue:4] Activations changed:
static=[mean_6046:2me-melbads:2me-melbads], dynamic=[].
2015/07/06 09:35:10 [queue:4] Disabling caching mode.
2015/07/06 09:35:10 [main:3] Shutdown started!
---
I'm starting to wonder if this is the decoder.ogg that's killing
LiquidSoap, which is terminating with:
---
Source dummy failed while streaming: Ogg.End_of_stream!
---
Thoughts anyone?
Kind Regards,
Jonathan
> Hey Jonathan,
>
> On Fri, Jul 3, 2015 at 3:46 AM, Jonathan Thorpe <[email protected]> wrote:
>
> > Hi Drew,
> >
> > Try sending the streamed source to a dummy output at all times no matter
> > where else you send it. Let me know the results.
> >
> >
> > Many thanks for your suggestion.
> >
> > I've just tried this with an output.dummy as below and it doesn't appear
> > to have any effect.
> >
>
> OK, here is something that works for me. Try running it unchanged and see
> if it works for you as is. If it does, try adding requests as late in the
> script as possible. Try and only add requests after the dummystream is
> defined so that there will be no requests affecting the dummystream.
>
> #!/usr/bin/liquidsoap
> # here is what I have cobbled together that works in the absence
> # of requests.
> # Try adding requests near the end of you game.
>
>
>
> # define transitions to and from stream
> default_dj_fade = ref 0.
>
> def to_break(a,b) =
> log("transition TO_BREAK called...")
> source.skip(b)
> add(normalize=false,
> [ sequence([ blank(duration=0.01),
> fade.initial(duration=!default_dj_fade, b) ]),
> a ])
> end
>
>
> def to_stream(a,b) =
> log("transition TO_STREAM called...")
> add(normalize=false,
> [ sequence([ blank(duration=0.01),
> b ]),
> fade.final(duration=!default_dj_fade, a) ])
> end
>
>
> # set up for metadata switching
> breakz = ref ["COOLZ"]
>
> #specify the icecast stream as an input
> stream = input.http("http://192.184.9.158:8240/stream")
>
>
>
> #specify the fail over file (could change this to be a template or
> directory of files)
> failover = mksafe(single("/var/audio/emergency/BahamianMix1.mp3"))
>
>
> def f(x) =
> (snd(x))
> end
>
> def on_meta (meta)
> breakz := list.map(f,meta)
> print (!breakz)
> end
>
>
> stream = on_metadata(on_meta, stream)
>
> radiostream = stream
>
> #Specify what to switch to when silence is detected
> radiostream = fallback(track_sensitive=false, [radiostream, failover])
>
> dummystream = fallback(track_sensitive=false, [stream, failover])
>
> # Output to ALSA (the pi's audio)
> #output.alsa(device="hw:1,0", radiostream)
> output.alsa(radiostream)
>
> # try this to keep stream checking metadata
> output.dummy(dummystream)
>
>
------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users