mirror of
https://github.com/migatu/conjurer.git
synced 2026-07-14 21:38:38 +00:00
d27b477db8
Adding playlists, various bufixes and installation scripts Fixing Rename KUUUURWA Install script music bot fx Fix ? fix Synchro test test Undo tst test tst Undo changes test fx tst fx Test commit of two files priority queue.
49 lines
1.7 KiB
Plaintext
49 lines
1.7 KiB
Plaintext
let json.parse credentials = file.contents("/home/pi/Conjurer/icecast_credentials.json")
|
|
enable_replaygain_metadata()
|
|
|
|
s1 = replaygain(playlist(reload_mode="watch", "/home/pi/Conjurer/all_playlist.playlist"))
|
|
s2 = replaygain(playlist(reload_mode="watch", "/home/pi/Conjurer/priority_queue.playlist"))
|
|
|
|
s = random(id="randomizer", weights=[7000, 100], [s2, s1])
|
|
|
|
interactive.harbor(port = 9999)
|
|
f = interactive.float("f", description="Frequency", min=0., max=1000.,unit="Hz", 200.)
|
|
g = interactive.float("g", description="Gain", min=0., max=20.,unit="dB", 8.)
|
|
b = bass_boost(frequency=f, gain=g, s)
|
|
s = add([s, b])
|
|
a = interactive.float("main_volume", min=0., max=20., 1.)
|
|
s = compress.multiband.interactive(bands=3, s)
|
|
|
|
s = nrj(normalize (s))
|
|
s = crossfade(fade_out=3., fade_in=3., duration=5., s)
|
|
s = amplify(a,s)
|
|
|
|
s = blank.skip(max_blank=2., s)
|
|
|
|
emergency = single("/home/pi/RetroPie/mp3/Youtube/Dr. Peacock - Trip to Ireland [GvrvQTUbUcA].mp3")
|
|
radio = fallback(id="switcher",track_sensitive = false, [s, emergency])
|
|
|
|
handle_metadata = fun (m) -> begin
|
|
print(m["title"])
|
|
print(m["artist"])
|
|
print(m["filename"])
|
|
end
|
|
radio.on_metadata(handle_metadata)
|
|
interactive.persistent("script.params")
|
|
|
|
log_to_stdout = true
|
|
log_to_file = true
|
|
logpath = "/home/pi/Conjurer/radio_log.log"
|
|
loglevel = 3
|
|
|
|
# Enable logging on Standard Output and set logging level.
|
|
set("log.stdout",log_to_stdout)
|
|
set("log.level",loglevel)
|
|
|
|
# Enable logging to file. See variable: logpath
|
|
set("log.file",log_to_file)
|
|
set("log.file.path",logpath)
|
|
|
|
output.file.hls("/tmp/hls",[("mp3-low", %mp3(bitrate=96)), ("mp3-hi", %mp3(bitrate=160))],radio)
|
|
output.icecast(%mp3, host="retropie", port=8000,password=credentials.password, icy_metadata="true", mount="mp3-stream", radio)
|