I built a little gizmo that fetches weather reports from WeatherUnderground... Used code that was available on Instructables. I re-wrote some things to streamline things.... but am having a hard time getting a good location.. I.e. I live in NY and the box is querying weather in Baltimore... (code author say something about service providers using proxies etc..)
The author of the code mentions in his notes that this section of code is where more accurate geolocations can be noted...
Here is snip where things should change ...
private static void InitLocation()
{
GeoLoactionByIP myLocation = new GeoLoactionByIP();
AskGeoService askGeo = new AskGeoService();
myLocation.queryLocation();
weatherData = new WeatherUndergroundData("d0", myLocation.latitude, myLocation.longitude);// <<< Your Key Here
askGeo.queryLocation(myLocation.latitude, myLocation.longitude);
int minutes = (int)(askGeo.currentOffserMS / 1000 / 60);
Debug.Print("\tTimezone offset (+DST)=" + minutes + " minutes");
ntpService.SetTimeZoneOffset(minutes);
}
FWIW I've tried numerous iterations....
C#,
VB running a netduino +
FWIW 2 because of a snow day...I had plenty of time to google