Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
generalize sundial API #1
(I will offer to buy you a beer should you ever be near Chicago or I near your location.)
@HankB Ha, thanks! Submitting this PR is gratitude enough :)
I never thought anyone would use this...I wrote this for Arduino to control the gate on my chicken coop without having to phone home to figure out when sunset/sunrise was. Turns out Arduino doesn't have enough precision in its
One of the reasons for pulling the 'time from' out of the calculation was so I could easily test results. Based on your comments I probably should do that. I'm surprised the calculations didn't work on the Arduino but I don't think I've ever tried any floating point on that architecture.
FWIW my use case is to turn outdoor lights on and off. I should probably spring for a light sensor but I like S/W solutions. ;)