Assign unique latitude and longitude for device

Posted on
Mon Dec 29, 2003 10:43 pm
ctdkite offline

Assign unique latitude and longitude for device

I have several vivaria from with plants and animals from different locations. Is it possible to assign a latitude and longitude for each device? For example, can I tell the lights in tank 1 go on and off according to the sunrise/sunset in Madagascar, and the lights in tank 2 according to the sunrise/sunset in Cuba, and still keep the house set according to where I actually live?

Warning I am new to home automation, Indigo, and scripts! Any help would be appreciated.

Posted on
Tue Dec 30, 2003 9:37 am
matt (support) offline
Site Admin
User avatar
Posts: 21417
Joined: Jan 27, 2003
Location: Texas

Re: Assign unique latitude and longitude for device

Interesting! I had never considered this use before. Unfortunately, there is no easy way to do this. The Longitude/Latitude used for the sunset/sunrise calculations is a global preference to the entire application. There are some AppleScript verbs to calculate sunset/sunrise for a particular date ("calculate sunset" and "calculate sunrise") but they always use the global preference for the location.

There is a chance you could hack something together by running a different copy of Indigo under a different login account that has a different location setting. I think maybe you could get this to work, but the complexity to usefulness factor is pretty high, IMO.

Regards,
Matt

Posted on
Fri Jan 02, 2004 5:39 pm
ctdkite offline

Forget long/lat; what if I knew the times?

If I knew the times of sunrise and sunset for each location, could I use that information somehow?

While most weather programs have sunrise/sunset information, I could not find a way to "get" that information to send to Indigo (or any app). The times and daylight duration are easily obtained, however, in text form. Is there someway to incorporate that data into a script?

Chris

Posted on
Fri Jan 02, 2004 10:25 pm
matt (support) offline
Site Admin
User avatar
Posts: 21417
Joined: Jan 27, 2003
Location: Texas

Re: Forget long/lat; what if I knew the times?

ctdkite wrote:
If I knew the times of sunrise and sunset for each location, could I use that information somehow?

While most weather programs have sunrise/sunset information, I could not find a way to "get" that information to send to Indigo (or any app). The times and daylight duration are easily obtained, however, in text form. Is there someway to incorporate that data into a script?

Chris


I believe to do this you would have to create an AppleScript application that handles all the timing. You could define Action Groups inside Indigo that turn on/off the devices, and then use the "execute group" verb to have those groups executed. But the script would have to manually handle the timing of when to execute the verb.

Is anyone currently doing something like this (running an AppleScript application that does manual timing) that might have some sample AppleScript to share?

Regards,
Matt

Posted on
Sat Jan 03, 2004 12:25 am
gregjsmith offline
Posts: 946
Joined: Apr 01, 2003
Location: Rio Rancho, NM

(No subject)

You might be able to use iCal for this. When a event occurs it could schedule a iCal event to do what you need based on timezones or something.

I was working on that but never got it working right.

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 19 guests