geez man, he's already pointed you to that exact feature and you ignored him and posted again! BTW, what are you talking about setting a location - have you installed LMCE yet? Didn't you notice that it actually determines it location automatically and tells you on screen? It uses this (lat/long/etc) to determine your sunrise/set times automatically, and fires those events then ... just hook into the events and use them like he suggested...

geez man, he's already pointed you to that exact feature and you ignored him and posted again! BTW, what are you talking about setting a location - have you installed LMCE yet? Didn't you notice that it actually determines it location automatically and tells you on screen? It uses this (lat/long/etc) to determine your sunrise/set times automatically, and fires those events then ... just hook into the events and use them like he suggested...

Hi,

just quick related question: can those calculated times be checked or seen somewhere ?

Do we have some state (day/night) that could queried after those events (sometimes you must query current state without waiting for events to happen) ?

Can I add a further question?! Is there any way the Sunrise/set events can be varied - eg <sunrise-30mins> or <sunset+60mins>? The actual point of sunrise and set is not necessarily the actual time you want to turn on/off lights, for instance. In many circumstances you will want to turn on lights long before actual sunset as it could be very dark in the house already, or perhaps in the higher latitudes you might want to delay this significantly because the sunset dusk period is very long...

Can I add a further question?! Is there any way the Sunrise/set events can be varied - eg <sunrise-30mins> or <sunset+60mins>? The actual point of sunrise and set is not necessarily the actual time you want to turn on/off lights, for instance. In many circumstances you will want to turn on lights long before actual sunset as it could be very dark in the house already, or perhaps in the higher latitudes you might want to delay this significantly because the sunset dusk period is very long...

I also thought about that possibility. Sometimes it's needed to have some delay. Regarding Thom's replay it's possible to set positive delay. At least will use that