Our tech tip this week comes from Philip in the OptoForum, who shared his PAC Control subroutine code for determining the time the sun rises and sets at a specific latitude.
You could use HTTP requests over the Internet to get this data (discussed earlier in the same thread). But with this OptoScript code you don't need an Internet connection.
Really handy for remote installations.
SNAP PAC controllers have no problem with math, and Philip notes that this code is more reliable than photocells. He uses it for turning lights on and off.
Read the OptoForum post and get the code. Thanks for sharing, Philip!
Do you have some code to share, or a question you'd like answered?
Come to the OptoForum anytime to ask and answer all kinds of questions about anything Opto. We'll see you there.