Italian Radio Stations List for Radio.py

Fabio, an Italian user of radio.py, wrote to me the other day with a couple of suggestions and a huge radio.py configuration file with 150 Italian radio stations.

According to Fabio, the list contains 40 of the most popular Italian radio stations, along with radio stations from where he used to live in northern Italy.

In his post, Fabio also describes a useful tip he uses. He used the radio.py configuration file to number his favorite stations, thus allowing him an even easier way to listen to them. E.g.

radio.py 1
radio.py 3

Previously, Henrikan compiled a .radiopy file containing some 58 Swedish radio stations.

If you’re a radio.py reader and you’ve compiled a .radiopy file you would like to share, send a link along with a short description and I’ll gladly publish it.

radio.py Station List Patch

Some of the stations in radio.py-0.5 changed their URLs or streams. The patch updates the stream URLs of three stations: Galgalatz, Galatz, and Radius.

To apply the patch and update radio.py, open a terminal and cd to the directory where you installed it. Type the following commands in the terminal (if you installed it as root, you’ll need to run the commands as root too).

$ wget "http://www.guyrutenberg.com/wp-content/uploads/2008/11/radio.py.patch"
$ patch radio.py < radio.py.patch
$ rm radio.py.patch

radio.py-0.5 – An Easy Interface for Listening to Radio under Linux

This new release of radio.py brings more predefined stations and the much wanted recording feature. radio.py is a Python wrapper for mplayer, designed to provide an easy-to-use interface for listening to radio from the command line. And indeed, using radio.py is very easy; just pass the station name.

radio.py Classic FM

To read more about radio.py and the existing features, go to radio.py – a Wrapper Script for Listening to Radio in Linux.

New stations in this release include Ram FM, Classic FM, Radio Caroline, and updates to all the radioIO stations. So overall, this version of radio.py comes with 81 predefined stations. To see the full list of recognized stations, run radio.py --list. If your favorite station is still missing, you can add it via configuration files, as described here. If you send a comment with the names of the stations and their websites, I’ll add them to the next release.

The other important new feature is the ability to record radio streams to mp3 directly from radio.py. This is done using the --record command-line switch. For example, the following

radio.py CNN --record cnn.mp3

will record the radio stream of CNN to a file called cnn.mp3. To stop recording, just press ‘q’. This option can also be used with --sleep and --wake-up to time your recordings. For example, if you want to record a show that starts in 30 minutes and is 60 minutes long, you should do

radio.py BBC1 --record bbc1.mp3 --wake-up 30 --sleep 60

You can download the new version from here. Installation is pretty straightforward: just untar the archive and put radio.py somewhere in your path (e.g. /usr/local/bin/), and the package is installed.

As always, if you want new stations added to the next release, send a comment with the station details (at least the name and website).

UPDATE 14/12/2008: I’ve changed the download link to point to radio.py‘s SourceForge project page.

radio.py-0.4 – Listening to Radio the Easy Way

Update: radio.py 0.5 is available.

radio.py is a little script that makes it very easy to listen to radio under Linux (and maybe other OSs too) with mplayer. All you need to do is call radio.py with the name of the station you want to listen to. For example:

radio.py Radio Paradise
or
radio.py BBC3
To read more about radio.py, go to the first post discussing radio.py.

What’s New

Here are some of the things that have changed in radio.py-0.4 compared to the previous release (0.3). Continue reading radio.py-0.4 – Listening to Radio the Easy Way

radio.py – a Wrapper Script for Listening to Radio in Linux

Download radio-0.3.tar.gz.

Update: radio.py-0.4 is now available.

I like listening to music and radio while working, and fortunately there are numerous ways to do that. Unfortunately, most ways that allow you to listen to radio are very resource-consuming memory hogs (such as listening to streaming media via web browsers) or very unfriendly to users (listening via mplayer, for example). So, I set out to find a way that would use as few system resources as possible while keeping it user-friendly. One other requirement I had was being able to do all that from the command line, so it would work great with GNU Screen and wouldn’t require an X server (if I worked without one).

I used mplayer for some time for listening to radio. I had a file with a list of web radio stream URLs, which I would copy and pass to mplayer -playlist. This method met two of the requirements (minimal resources and command-line interface), but wasn’t really user-friendly. So, I wrote a little wrapper script in Python around mplayer – radio.py. After a quick installation (download and extract the tar archive and copy radio.py somewhere in your PATH), radio.py will allow you to listen to stations easily, and it will also do a couple more things for you.

To listen to a station, just call radio.py with the station’s name; e.g., in the command line enter radio.py BBC1 to listen to BBC Radio 1. To view a list of known stations, run radio.py --list. Currently there aren’t many stations (just stations I thought were needed or that I listen to). You can easily edit radio.py to add new stations (the script is documented and very clear). If you do so, please write a comment or email me so I will be able to add those stations to the next release by default.

So, as you’ve seen, radio.py allows you to easily listen to radio, as easily as writing the station’s name. But, as I said, it can do more things that I thought should be in a radio script. It has both a sleep feature (that turns off the radio after a specified amount of time) and a wake-up feature (that starts the radio after a specified amount of time). These two features can be used together, and practically allow you to use radio.py as an alarm clock.

You can find more information about radio.py options by calling radio.py --help. I hope you will find this script as useful as I do.

Download:
radio-0.3.tar.gz.