When you are listening to Radio FIP and don't want to open the web site in a browser to know the title of the current song, download this little command-line script to show the title, artist, album and year in a terminal window.
You just leave it running and it refreshes itself when a new song starts.
It is written in Bash and requires curl and jshon to be installed. The former to download the data from the Radio France server, the latter to parse the data in JSON.
The script works like the FIP web site itself: It requests data
from the Radio France web server in JSON, parses it and displays
it. The JSON data also contains the delay until the next update
of the data, so the script knows when to ask for new data. The
data is currently at this URL: https://www.radiofrance.fr/fip/api/live/webradios/fip
https://www.radiofrance.fr/fip/api/live https://www.radiofrance.fr/_app/remote/di23tz/getLive?payload=W3siYnJhbmROYW1lIjoxfSwiZmlwIl0
(The payload parameter contain the name of the radio station in
‘base64’, in this case fip. There are similar URLs for fip-jazz,
fip-metal, etc,)
If you use Lyrion (a.k.a. Logitech Media Server or LMS), there is a plugin for it called ‘Radio France’ by Paul Webster.
The current URLs for listening to Radio FIP on the web are as
follows (source: https://www.radiofrance.fr/data/streams https://www.radiofrance.fr/comment-ecouter-radio-france)
| URL | format | bitrate |
|---|---|---|
| https://stream.radiofrance.fr/fip/fip_hifi.m3u8?id=radiofrance | HLS | ~ 268 KB/s |
| https://stream.radiofrance.fr/fip/fip_midfi.m3u8?id=radiofrance | HLS | ~ 178 KB/s |
| https://stream.radiofrance.fr/fip/fip_lofi.m3u8?id=radiofrance | HLS | ~ 105 KB/s |
| https://icecast.radiofrance.fr/fip-hifi.aac?id=radiofrance | AAC | ~ 192 KB/s |
| https://icecast.radiofrance.fr/fip-midfi.aac?id=radiofrance | AAC | ~ 128 kb/s |
| https://icecast.radiofrance.fr/fip-midfi.mp3?id=radiofrance | MP3 | 128 kb/s |
| https://icecast.radiofrance.fr/fip-lofi.aac?id=radiofrance | AAC | ~ 32 kb/s |
| https://icecast.radiofrance.fr/fip-lofi.mp3?id=radiofrance | MP3 | 32 kb/s |
| https://direct.fipradio.fr/live/fip-hifi.aac | AAC | ~ 192 kb/s |
Often, the stream starts with a commercial before the actual stream from FIP starts.
Bert Bos <bert at phonk.net>