Hello all,
Wanted to share some information I have been struggling with for the
last day or so which now seems to work reliably and well.
You will need the following to replicate but should work for other OS
Ubuntu 12.04 32 or 64bit (or some 12.04 derivitive Linux Mint perhaps)
sudo apt-get install liquidsoap liquidsoap-plugin-all
Make your script file and define in the code to match you icecast settings
<username> = Icecast username usually "source"
<password> = Icecast password usually "password"
These settings can be changed to whatever you wish on streaming server
via "/etc/icecast.xml" which you can edit.
Below is a Liquidsoap script which with the exception of <username>
and <password> does work but you will need to make a number of
additional changes to address your own icecast server etc.
###########################################
#!/usr/bin/liquidsoap
# Define a Log file to monitor output
set("log.file.path","./soslug_flow.log")
# Not used but this would define audio file to record a stream
recording = "./soslug_flow.mp3"
# Define the stream input source
stream = mksafe(audio_to_stereo(input.alsa()))
# Register your stream on http://flow.liquidsoap.fm (heres how)
stream = register_flow(
radio="My Radio",
website="http://soslug.org",
description = "Liquid Soap application Streaming by Southend
on Sea Linux User Group",
genre = "Visit us at http://soslug.org",
streams=[("mp3/128k","http://soslug.org:8008/soslug_alsa.mp3")],
stream)
# Define the icecast output format etc..
output.icecast(%mp3(bitrate=128),
host = "soslug.org", port = 8008,
user = "<username>", password = "<password>", mount = "soslug_alsa.mp3",
description = "Liquid Soap application Streaming by Southend on
Sea Linux User Group",
url = "http://soslug.org:8008/soslug_alsa.mp3",
stream)
# Defines output format for stream to be recorded
# Record a high quality 192 kbit were "recording" is a variable for
the filename # and stream is the variable for linein recording.
output.file(%mp3(bitrate=192), recording,
fallible=true,
on_stop=shutdown, stream)
# A rolling graphical display output of signal levels
output.dummy(visu.volume(smooth_add(special=delay(3.,blank(duration=4.)),normal=stream)))
I am chuffed to bits with this I am not a programmer and ok I took
snippets of code from what I could find in mailing list, web and
called on my own experience, but what the hell it works. If anyone has
any ideas to make the above better please let me know.
One big problem I have noticed is that I can not use "Control-C" to
terminate the stream killing the process does not kill the application
to default console prompt however "Control-C" does kill the stream
itself and graphics display output. Would like a clean way to kill
this script please.
Derek
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users