Update 08-06-2010: the last.fm gadget does not work anymore. Last.fm changed their client server protocols and therefore the gadget is not working anymore. I’m not using Last.fm anymore so i’m not planning on updating the gadget in the future
Last week my mailbox was flooded by mails of people who were telling me my Windows Vista Sidebar gadget to play Last.fm radio was broken.
I tested it myself and concluded that this was indeed the case. Last.fm changed their website last week and my guess is that they also changed their streaming service.
After a full night of debugging I found out what was the problem and I fixed it in a new version which can be now downloaded from the download area.
If you are interested in what was changed read on. The change was fairly simple, the protocol uses 2 handshakes to connect to the service. The first handshake is to connect to the scrobbling service. The second handshake is used to connect to the streaming service. Before last week requesting the mp3 stream was done by sending the sessionid of the first handshake. Now… it seems you have to send the sessionid you get with the second handshake. It took some time to figure this out but now everything seems to work fine again.
Handshake 1 request:
Handshake 1 response from last.fm:
session=bbe5e763d1e1deb988595cecf1c21e9d stream_url=http://220.127.116.11:80/last.mp3?Session=bbe5e763d1e1deb988595cecf1c21e9d subscriber=0 framehack=0base_url=ws.audioscrobbler.com base_path=/radio info_message= fingerprint_upload_url=http://ws.audioscrobbler.com/fingerprint/upload.php permit_bootstrap=0
Handshake 2 request:
Handshake 2 response from last.fm:
OK 7e5b82460d2a45e382b81c437ae6a87a http://post.audioscrobbler.com:80/np_1.2 http://18.104.22.168:80/protocol_1.2
Tune to the right radio channel:
Response to channel change request from last.fm:
response=OK url=lastfm://artist/muse stationname= Muse’s Similar Artists discovery=true
Request metadata of stream:
I was happy to receive the mails of complaints because this is proof people are actually using my gadget Hopefully all problems are fixed now so happy listening!
Geert van der Cruijsen