Difference between revisions of "HAMWeather"

From Amahi Wiki
Jump to: navigation, search
Line 10: Line 10:
 
Note where you save it, and then (as root) run the following:
 
Note where you save it, and then (as root) run the following:
  
  chmod a+x install_pt2.sh
+
  chmod a+x Install_pt2.sh
  
 
To run it, type:
 
To run it, type:
  
  ./install_pt2.sh
+
  ./Install_pt2.sh
  
 
The ICAO identifier for your airport in the US is the 3-letter identifier (i.e., ORD for Chicago O'Hare) with a K at the front (KORD). Pick the airport closest to you.
 
The ICAO identifier for your airport in the US is the 3-letter identifier (i.e., ORD for Chicago O'Hare) with a K at the front (KORD). Pick the airport closest to you.

Revision as of 17:16, 1 September 2009


HAMWeather should run out of the box; however, the "Current Conditions" section may have a bunch of N/As listed. If you don't, don't worry about this - you're fine. If you do, it's because the database doesn't know the closest airport to you (where it gets the current temp info from).

If you get N/As, there are two options. The first is to register; the developer will set you up with a database with every US city and the closest airport, with no work on your part. See their website for details.

The alternative, if you're in the US, is to run a script to let the program know the closest airport to you. The script is located at: http://wiki.amahi.org/images/e/e8/Install_pt2.sh

Note where you save it, and then (as root) run the following:

chmod a+x Install_pt2.sh

To run it, type:

./Install_pt2.sh

The ICAO identifier for your airport in the US is the 3-letter identifier (i.e., ORD for Chicago O'Hare) with a K at the front (KORD). Pick the airport closest to you.

Once you're done, you can delete the install_pt2.sh file, since you're done. If you want to add extra cities in the future, re-run it with different cities and airports.

If your city isn't found by the script or you're outside the US, you can follow the directions below.

To add your information, you need to edit the SQL database, using the instructions from:

http://www.hamweather.com/kb/index.php?article=21

The easiest way to do this is using phpMyAdmin (another webapp), which lets you modify the MySQL database. To do this, you need the 4 letter ICAO abbreviation for the airport closest to you. If you live in the US, it's going to be "K" followed by the 3-letter airport abbreviation - i.e., for Gainesville, it's "KGNV" instead of just GNV.

To add my town (Gainesville, FL) in phpMyAdmin, I clicked "Databases", picked "weather", and then picked "places". Click "Search" at the top, and enter your city under "Name". Gainesville brings up 7 choices, but I picked the one in FL. Write down the number under "places_id".

Next, click "alt_cc_info" on the left. Click the "insert" tab at the top, and fill in the "places_id" field with the number you wrote down, the "ICAO" field with the 4-letter airport ID, put "3" for the type_code, and 1 for precedence. Click "go", and you should be all set.

If you have multiple locations you want, you can repeat these instructions to add all of them.

An alternative is to register HAMWeather - http://www.hamweather.com/hw3/store/, in which case they'll send you a complete database that is already updated.