Here's what I have so far:
In my OpenHab.CFG file I included the bindings for Astro.
In my ITEMS file I have this:
DateTime Sunset_Time "Sunset [%1$tH:%1$tM]" {astro="planet=sun, type=set, property=end"}
I can see that I am returning the correct times because I added this line: Text item=Sunset_Time to the .SITEMAP file.
My question is, in the Rules file, what is the syntax to have my porch lights go on at sunset? If I was going to have the lights turn on at a specific time (say 6:30 AM), I would do the following:
rule "LampOnMorning"
when Time cron "0 30 6 * * ?"
then sendCommand(Lamp_Module, ON)
end
How would I do this for the sunset time? I tried replacing cron "0 30 6 * * ?" with Sunset_Time but it doesn't seem to like it.
Any suggestions on actual code of getting this to work would be very much appreciated.
Thank you.
-Rob