I’m more and more using Last.FM these days to find fresh artists, track gigs in the city I live in and find people with similar music tastes as me. The Last.FM webradio streaming service is really nice, but not (yet) well documented. So I digged existing clients source code and made mine using Python and GStreamer :-)
The protocol is really simple, relying on HTTP GET requests, hard to do simpler! So I hacked a LastFMSource GStreamer Element which allows to tune station uris and perform commands (love, skip, ban,…) to the current stream. The element is smart enough to update the current track metadatas if it find the "SYNC" string in the input stream. The code is simple enough (I hope!) to be understandable and reusable, so enjoy!
Now I just need some more time to polish the Elisa plugin coming along and using this new Element. The basis is there: a "Last.FM radios" menu listing some stations, press enter to play, you can access commands in another menu… Quite simple no? :)