View unanswered posts | View active topics It is currently Fri Sep 10, 2010 7:31 am



Reply to topic  [ 91 posts ]  Go to page: 1, 2, 3, 4, 5 ... 7  Next
 NOAA Weather Script 
Author Message

Joined: Oct 16, 2004
Posts: 53
Location: Phoenix, AZ
Post NOAA Weather Script
I created this swanky little script for all you kiddies that pulls the latest weather information from the NOAA website and put them into Indigo variables. Yummy!

NOAA Weather Script

Give it a try and let me know how it works for you.

Cheers.
Karl


Last edited by Threadhead on Sun Dec 31, 2006 12:29 pm, edited 1 time in total.



Sat Jan 21, 2006 12:12 pm
Profile
Site Admin
User avatar

Joined: Jan 27, 2003
Posts: 8077
Location: Texas
Post Re: NOAA Weather Script
Thanks Karl! I'm looking forward to playing with it.

Regards,
Matt


Sun Jan 22, 2006 12:28 am
Profile WWW

Joined: Sep 24, 2005
Posts: 404
Post 
excellent script karl, thanks!


Sun Jan 22, 2006 3:39 pm
Profile

Joined: Jan 25, 2006
Posts: 26
Post NOAA Script
This works very well...but I'm wondering what part of this information would be a variable test for rain to tell Indigo not to water the lawn. Now, don't laugh, but the best I can come up with is: water the lawn unless Humidity is > 100.


Tue Jan 31, 2006 6:25 pm
Profile

Joined: Oct 16, 2004
Posts: 53
Location: Phoenix, AZ
Post 
Since the humidity is 'relative humidity', then 100% would be raining. So I would say that if the relative humidity is say >98% or so, it's a good bet that it's raining outside.

However, it really depends on how close you are to the reporting station and the geographic differences in your area. Here in AZ, it can be outright pouring rain only a few block away, and you get not a drop. Also, we have a contidion in the summer called 'verga' where it rains, but the water evaporates before it hits the ground. So you can see the rain a few hundred feet above your head, but it doesn't hit you.

BTW, we are on day number 107 without a single drop of rain, an all time record. And it's nearly 80 degrees outside. 8)


Wed Feb 01, 2006 12:44 pm
Profile

Joined: Sep 24, 2005
Posts: 404
Post 
yes, i did a little research for mine, and set the humidity threshold at 87% for raining. that is based on what the measured humidity was in my area when it was actually raining. varies w/ location. and with temp. the real thing is to work up an index that takes dew point and temp trends into account as well as rh. still working on that... : )


Thu Feb 02, 2006 4:40 pm
Profile

Joined: Jan 30, 2005
Posts: 16
Location: Michigan
Post Re: NOAA Weather Script
This is way kool. It worked perfectly on the first try.
Is it possible to "speak" the information that will be stored in the variables list?


Sat Feb 04, 2006 10:14 am
Profile

Joined: Jan 04, 2006
Posts: 6
Post NOAA Weather Script
Great Script! On cloudy days, I'd like to have my lights turn on a little earlier and turn off a litlle later. I tried to modify the script to get the weather variable with little success. I thought about using visibility but not sure if I can do it that way.

Any ideas?

Thanks,

Arturo


Tue Feb 21, 2006 10:55 am
Profile

Joined: Oct 16, 2004
Posts: 53
Location: Phoenix, AZ
Post 
Arturo,
Shouldn't be a problem. Just remember that all variables are stored as strings and you will need to convert them to numbers (integers) before you can do any comparison or math.


Tue Feb 21, 2006 11:47 pm
Profile

Joined: Jan 04, 2006
Posts: 6
Post NOAA Weather Script
Just wondering. Could I get the weather variable (cloudy, foggy, etc) as well? I don't see it in the list. Then I could use this as a condition to turn my lights on early or turn them off later. I am a novice at apple script. Any hints are greatly appreciated.

Thanks,

Arturo


Wed Feb 22, 2006 8:43 am
Profile

Joined: Oct 16, 2004
Posts: 53
Location: Phoenix, AZ
Post 
You can only get what NOAA supplies. And all the fields can be turned on/off in the top portion of the script.

So, there is no "cloudy" or "fair" field, only a condition. And to be honest, I don't know all the possibilities that could be expressed in the condition. Here in AZ, we only get to see one condition: sunny :wink:


Wed Feb 22, 2006 9:04 am
Profile

Joined: Jan 04, 2006
Posts: 6
Post noaa weather script
We get sunny, too. But it can go from sunny to rainy to sunny again in 20 minutes. I actually think I can get what I want by dividing relative humidity by visibility. I am going to play around with what values correspond to it getting darker at dusk. Any hints about how to convert the noaa text values to numbers?

Arturo


Fri Feb 24, 2006 1:59 pm
Profile

Joined: Oct 16, 2004
Posts: 53
Location: Phoenix, AZ
Post 
You can only convert the variables (which are all strings) to number via AppleScript.


Fri Feb 24, 2006 8:40 pm
Profile

Joined: Jan 04, 2006
Posts: 6
Post NOAA Weather Script
I tried by doing this but it says it cannot conver that class of variables.

Here is the code.


tell application "Indigo"
set vismi to value of variable "NOAA_Visiblity_mi" as integer
end tell

Arturo


Tue Feb 28, 2006 10:08 am
Profile

Joined: Feb 11, 2006
Posts: 20
Post Has anyone else had this problem
I'm trying to run the NOAA script. I edited the user defined varialbles and created a timed event in Indigo. I get the follwoing error when running the script.


Mar 29, 2006 10:13 PM
Time/Date Action Weather Script Update
NOAA Weather NOAA Weather Script Starting.
NOAA Weather ParseXML:NSCannotCreateScriptCommandError(10)

I must be doing something wrong.

I'm running OS X Server 10.3.9 and the script runs fine on my laptop running OS X 10.4.5. Both are on the same network. HUH....


Wed Mar 29, 2006 10:21 pm
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 91 posts ]  Go to page: 1, 2, 3, 4, 5 ... 7  Next

Who is online

Users browsing this forum: MSN [Bot] and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.   Template designed by STSoftware.