Hi !

2012/11/12  <[email protected]>:
> First of all, thank you heaps for all the work you guys put into liquidsoap.
> It really is amazing and "game changing"...
> Brilliant idea and great implementation...

Thanks you very much!

> Now to my problem...
> I'm having a strange situation when trying to stream more than
> one output if one of them is AAC+
>
> This is my basic script (hostname and password commented out):
>
> If run like below, it hangs on startup, with no useful output.
> (Requiring a kill -9)

Ok. I've been trying to reproduce here without luck so far. However,
before we go on, have you tried the script without the buffer()
operator?

This operator does much more than add a buffer, in this case, it will
create two clocks, one for the ALSA input and one for all the icecast
output (I think). In your case, this does not make sense I think.. :-)

> #!/usr/bin/liquidsoap
> set("log.file.path","/tmp/basic-radio.log")
> radio = mksafe(buffer(input.alsa(device="pcm.liquidsoap")))
> output.icecast(
>   %aacplus(channels=2, samplerate=44100, bitrate=28),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio28.aac", radio)
> output.icecast(
>   %aacplus(channels=2, samplerate=44100, bitrate=22),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio.aac", radio)
> output.icecast(
>   %vorbis(samplerate=44100, channels=1, quality=-0.1),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio.ogg", radio)
> output.icecast(
>   %mp3.vbr(quality=9, mono=true, samplerate=44100),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio.mp3", radio)
>
> If commenting out like the examples below, it runs fine.
>
> #!/usr/bin/liquidsoap
> set("log.file.path","/tmp/basic-radio.log")
> radio = mksafe(buffer(input.alsa(device="pcm.liquidsoap")))
> #output.icecast(
> #  %aacplus(channels=2, samplerate=44100, bitrate=28),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio28.aac", radio)
> #output.icecast(
> #  %aacplus(channels=2, samplerate=44100, bitrate=22),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio.aac", radio)
> output.icecast(
>   %vorbis(samplerate=44100, channels=1, quality=-0.1),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio.ogg", radio)
> output.icecast(
>   %mp3.vbr(quality=9, mono=true, samplerate=44100),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio.mp3", radio)
>
> #!/usr/bin/liquidsoap
> set("log.file.path","/tmp/basic-radio.log")
> radio = mksafe(buffer(input.alsa(device="pcm.liquidsoap")))
> output.icecast(
>   %aacplus(channels=2, samplerate=44100, bitrate=28),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio28.aac", radio)
> #output.icecast(
> #  %aacplus(channels=2, samplerate=44100, bitrate=22),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio.aac", radio)
> #output.icecast(
> #  %vorbis(samplerate=44100, channels=1, quality=-0.1),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio.ogg", radio)
> #output.icecast(
> #  %mp3.vbr(quality=9, mono=true, samplerate=44100),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio.mp3", radio)
>
> #!/usr/bin/liquidsoap
> set("log.file.path","/tmp/basic-radio.log")
> radio = mksafe(buffer(input.alsa(device="pcm.liquidsoap")))
> #output.icecast(
> #  %aacplus(channels=2, samplerate=44100, bitrate=28),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio28.aac", radio)
> output.icecast(
>   %aacplus(channels=2, samplerate=44100, bitrate=22),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio.aac", radio)
> #output.icecast(
> #  %vorbis(samplerate=44100, channels=1, quality=-0.1),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio.ogg", radio)
> #output.icecast(
> #  %mp3.vbr(quality=9, mono=true, samplerate=44100),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio.mp3", radio)
>
> Most other combinations with at least an ACC+ stream will hang...
> But the following combination doesn't hang and gives the output below...
>
> #!/usr/bin/liquidsoap
> set("log.file.path","/tmp/basic-radio.log")
> radio = mksafe(buffer(input.alsa(device="pcm.liquidsoap")))
> output.icecast(
>   %aacplus(channels=2, samplerate=44100, bitrate=28),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio28.aac", radio)
> #output.icecast(
> #  %aacplus(channels=2, samplerate=44100, bitrate=22),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio.aac", radio)
> output.icecast(
>   %vorbis(samplerate=44100, channels=1, quality=-0.1),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio.ogg", radio)
> #output.icecast(
> #  %mp3.vbr(quality=9, mono=true, samplerate=44100),
> #  host = "hostname", port = 7900,
> #  password = "hackme",
> #  mount = "radio.mp3", radio)
>
> $ liquidsoap -v --debug test1
> At line 18, char 29:
>   this value has type
>     source(audio=2+_,...) (infered at
> /usr/lib/liquidsoap/1.0.1/utils.liq, line 7, char 11-72)
>   but it should be a subtype of
>     source(audio=1,...)

Yes, this one is to be expected. The mono output expects a mono source
but your radio source is stereo. You need to use the mean operator
here:

output.icecast(
  %vorbis(samplerate=44100, channels=1, quality=-0.1),
  host = "hostname", port = 7900,
  password = "hackme",
  mount = "radio.ogg",
  mean(radio))

> So basically, if I have an AAC stream I cannot have any others.
> It either hangs requiring a kill -9 or it gives the error above.
>
> Funny enough, it worked OK in a previous versions of the script.
> But with this version, I used to get lots of buffering problems.
>
> #!/usr/bin/liquidsoap
> set("log.file.path","/tmp/basic-radio.log")
> output.icecast(
>   %aacplus(channels=2, samplerate=44100, bitrate=28),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio28.aac",
>   input.alsa())
> output.icecast(
>   %aacplus(channels=2, samplerate=44100, bitrate=22),
>   host = "hostname", port = 7900,
>   password = "hackme",
>   mount = "radio.aac",
>   input.alsa())
>
> 2012/11/12 22:55:46 [clock.wallclock_alsa:3] Streaming loop starts,
> synchronized by active sources.
> 2012/11/12 22:55:46 [clock:4] Main phase starts.
> 2012/11/12 22:55:46 [input.alsa_4733:2] Overrun!
> 2012/11/12 22:55:46 [input.alsa_4733:2] Trying to recover..
> 2012/11/12 22:55:46 [input.alsa_4738:2] Overrun!
> 2012/11/12 22:55:46 [input.alsa_4738:2] Trying to recover..
>
> The "improved" version doesn't give me these errors,
> but then I cannot run more than one AAC+ stream...
>
> Any ideas?
>
> I am running Debian sid, with the following dmo libs hand installed
> (did not add repo to sources.list):
>
> libaacplus2_2.0.2-dmo1_i386.deb
> libaacplus-ocaml_0.2.0-dmo1_i386.deb
> libaacplus-ocaml-dynlink_0.2.0-dmo1_i386.deb
>
> liquidsoap is straight from the debian sid repos, no compile...
>
> Thanks!
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
> _______________________________________________
> Savonet-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/savonet-users

------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users

Reply via email to