Saturday, December 22, 2007

Never miss the bus again with Plasma

On Thursday I had a meeting with my classmates from the advanced chemistry course, some of them I haven't seen since 6 years, that was real fun! What has this information to do with KDE? Well, on the way to the Irish pub we used the bus of our local public transport (DVB). They have nice info screens (running windows, so you often see just a bluescreen ;)) with advertisement on it. These evening the showed information about a 'widget' that you can download to show the arrival/departure times of a single bus/tram stop. The next day I browsed the DVB website and found a link to this widget, it is a Yahoo Widget thingy... unfortunately the Yahoo Widget engine is not available for Linux :(

Ok, I'm a hacker, let's see whether we can fix that!

The Yahoo Widget consists of a couple of HTML, image and JavaScript files, packed into a proprietary format. Finding out the URL queried by widget to retrieve the information was no problem and the returned data are in an easy to parse format. So the rest of the work was to assemble a Plasmoid which makes use of these 'webservice'. Two days later (had to buy some xmas presents in the meantime ;)) there is a working version available:

You can see two applets which show the departure time for two different stops.
Of course this Plasmoid is only useful for all KDE users living in Dresden (maybe 10? ;)) so I'll make the code available on my private website only, or provide it by KNewStuff later.

Update: You can find the sources and the compile instructions now under