PUBLIC   marks

ON THIS LINK

Time/Weather Desktop on Flickr - Photo Sharing!

by karlcow

Well, most of the work is done by Earthdesk and GeekTool 3.

Earthdesk is set to Natural Color, Equirectangular projection, Natural Color, Real Moonlight, centered on Vienna, Background: Starfield. Zoom 80%, Clouds 80%, Brightness 80%.

In GeekTool, the times and the weathers are all separate Shell "geeklets".

Times are generated by running shell commands like

env TZ=Asia/Tokyo date " %l:%M %p"

every 20 seconds

The weather is the tricky part. The way I am doing it now, if I am not careful, gets me throttled for too many concurrent requests to the wunderground.com API server. It also fails badly if I am disconnected, so I will need to do it differently.

FWIW: I have a PHP script which I run as separate Shell Geeklets. I invoke it with the name of the city I want. It then hits wunderground and gets back an XML stream of the local weather, which I parse, format and echo. (the way I'd change this is run the script from cron, with a 30 second wait between requests, and cache the results locally, which I would then call from the Shell Geeklets)

From there it's just a question of setting fonts, sizes, colors and moving the little Geeklet boxes around as you want them.

Comments

No comment on this link yet. React !


PUBLIC TAGS
on this link

geek   meteo   semanticdesktop  

BY

karlcow
the 24/10/2009 at 15:00