-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathradio-nodialog.sh
103 lines (95 loc) · 1.98 KB
/
radio-nodialog.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
#!/bin/bash
export PLAYER="ffplay"
export PLAYERARGS="-nodisp -hide_banner -loglevel error"
while true
do
if [ -z "$prchan" ]
then
prdisp="Playback stopped."
else
prdisp="Now playing: $prchan"
fi
clear
echo "$prdisp"
echo "Input number to switch station."
echo ' 0 "Stop playback"
1 "80s80s"
2 "80s80s In the mix"
3 "100,5"
4 "100,5 In the mix"
5 "1Live"
6 "WDR 2"
7 "Antenne AC"
8 "WDR Cosmo"
9 "Radio21"
a "XMAS Radio"
x "Exit"'
read -n 1 channel
clear
kill $PLAYERID
case $channel in
0)
prchan=
;;
1)
prchan="80s80s"
"$PLAYER" "https://streams.80s80s.de/web/mp3-192/" $PLAYERARGS &
PLAYERID=$!
;;
2)
prchan="80s80s In the mix"
"$PLAYER" "https://regiocast.streamabc.net/regc-80s80smix8012507-mp3-192-3015055" $PLAYERARGS &
PLAYERID=$!
;;
3)
prchan="100,5"
"$PLAYER" "https://stream.dashitradio.de/dashitradio/mp3-128/stream.mp3" $PLAYERARGS &
PLAYERID=$!
;;
4)
prchan="100,5 In the mix"
"$PLAYER" "https://stream.dashitradio.de/in_the_mix/mp3-128" $PLAYERARGS &
PLAYERID=$!
;;
5)
prchan="1Live"
"$PLAYER" "http://wdr-1live-live.icecast.wdr.de/wdr/1live/live/mp3/128/stream.mp3" $PLAYERARGS &
PLAYERID=$!
;;
6)
prchan="WDR 2"
"$PLAYER" "http://wdr-wdr2-aachenundregion.icecast.wdr.de/wdr/wdr2/aachenundregion/mp3/128/stream.mp3" $PLAYERARGS &
PLAYERID=$!
;;
7)
prchan="Antenne AC"
"$PLAYER" "http://mp3.antenneac.c.nmdn.net/ps-antenneac/livestream.mp3" $PLAYERARGS &
PLAYERID=$!
;;
8)
prchan="WDR Cosmo"
"$PLAYER" "http://wdr-cosmo-live.icecast.wdr.de/wdr/cosmo/live/mp3/128/stream.mp3" $PLAYERARGS &
PLAYERID=$!
;;
9)
prchan="Radio21"
"$PLAYER" "https://radio21.streamabc.net/radio21-hannover-mp3-192-3735655" $PLAYERARGS &
PLAYERID=$!
;;
a)
prchan="XMAS Radio"
"$PLAYER" "https://regiocast.streamabc.net/regc-80s80sevent014441101-mp3-192-8841017" $PLAYERARGS &
PLAYERID=$!
;;
x)
killall $PLAYER
echo "Exiting..."
exit 0
;;
*)
killall $PLAYER
echo "Not a valid channel."
exit 1
;;
esac
done