|Line 113:||Line 113:|
Latest revision as of 23:24, 15 February 2010
 Mokometeo 0.6
Mokometeo is a small python/elementary application fetching the weather forecast from WeatherUnderground weather pages
You need python-elementary and python-netclient to make it work.
 OM and SHR
So to install it, you can do :
opkg install python-elementary python-netclient http://www.opkg.org/packages/mokometeo_0.6_arm.ipk
Also need dependancies (on SHR testing) :
opkg install python-netclient
 Using Mokometeo
- For version 0.5 and higher, once the package (and dependencies) is installed, simply click on the desktop icon. A default configuration file ~/.mokometeo.cfg will be created which can be edited to your liking. Previous and next locations are selected using the buttons at the bottom of the screen, and if a network connection is active the forecast can be updated using the Refresh button. The forecast for all locations is saved in the configuration file so that a network connection is not necessary for switching locations after starting mokometeo. The middle area (containing the forecast information) is now scrollable using the standard elementary finger scrolling action.
- In the 0.2 version, there is a bug. To be able to use Mokometeo, please type theses commands before launching it:
mkdir /home/root/.mokometeo mkdir /home/root/.mokometeo/img cp /usr/share/mokometeo/question.png /home/root/.mokometeo/img/
- for the german 0.3, you don't need this
- You will see a window appearing, with a 4 days forecast : Today, tomorrow (J+1), the day after (J+2) , etc.
- You can use the Next and Previous buttons to change the displayed city.
- If you have no internet connection, you will have to wait a little bit, and then the window will show "question marks" and "-" as min and max temperatures
- Next time you starup Mokometeo, the last fetched data will be displayed.
 Configuring Mokometeo
 Version 0.5 and higher
The configuration file ~/.mokometeo.cfg has a section named [Main] which looks like:
[Main] units = celsius lastview = 0 locations = Melbourne,AU:Perth,AU:Paris,FR
The locations line can be edited and colon (:) separated locations of your choice added. I've found that <city>,<country abbreviation> works well with the WeatherUnderground API. It's probably worth checking using this URL:
(or similar) to make sure it returns the location you're expecting.
The units line can also be changed to fahrenheit if desired.
 Previous versions
- By default, 2 cities are configured. You can change the cities and add more in the file
This file must contains at minimum 2 lines. The first line is
The second and next lines is the name of the city, and the url (tested with french yahoo weather urls), for example:
 2010-01-12 - v0.6
- Added ability to add & remove locations using the GUI.
- Fixed problem where a space in the location designation caused the script to abort.
 2009-12-14 - v0.5
- Now uses the elementary GUI instead of Gtk+.
- Now uses the Weather Underground site instead of Yahoo weather (better API).
- Six days of forecast available.
- Now uses a single file (~/.mokometeo.cfg) for configuration and location history. The .mokometeo directory is no longer needed.
- Weather icons are not downloaded on the fly, they're part of the package.
- History is saved for all defined locations
 2009-03-13 - v0.2
- added some "print" in the code
- debug the .mokometeo folder ; put the config folder in /home/root/.mokometeo/ instead of /.mokometeo/
- test if the connection to internet is ok. If not, display question marks
- backup the data each time data is downloaded and displayed. This data is used on the next Mokometeo startup
- added the date and time when the data has been downloaded
 2009-03-12 - v0.1
 Future improvements / To do list
Use the GUI to add/remove locations
debug the initial copy of /usr/share/mokometeo/question.png into /home/root/.mokometeo/img/
improve the way the connection to Yahoo is handled
- test with different languages / locations
handle backup data for each city in the config file
 Sources and contribution
You can access the sources and participate by commiting patches via the google code mercurial : http://code.google.com/p/mokometeo/source/checkout To be able to commit:
- you need a gmail email adress
- I must add you as a user, so please contact me (or edit the discussion tab of this page)
- You can use this password hN8CP6BV5mT7