Jump to content

Recommended Posts

Posted (edited)

Hello @raf.sonneville

there's a condition time exceeded which you can use.
You'll need to combine two conditions and invert the second.

time exceeded = 6:00 and not time exceeded = 18:00

The Lua equivalent is

if (layout.time > toTime("6:00")) and (layout.time < toTime("18:00")) then

I hope that helps?
Goetz

Edited by Goetz
Lua code corrected
Posted (edited)

Hello @raf.sonneville

Just a method I use to detect the change of day/night.
Take a light giving object and put it in automatic mode for day/night.  ( you may hide this reference object )
If there is a change in day / night the integrated switch will toggle.
This EV reacts on it.

Das ist nur eine Methode, mit der ich den Wechsel von Tag und Nacht erkenne.
Nehmen Sie ein lichtgebendes Objekt und stellen Sie es in den automatischen Modus für Tag/Nacht. ( Sie können dieses Referenzobjekt ausblenden )
Wenn es eine Änderung in Tag / Nacht der integrierte Schalter umschalten.
Dieser EV reagiert darauf.

railwaillantern.thumb.jpg.0af83dcbecb7a40ada53ebcc1bca71db.jpg

The advantage is that if you use other times , the reaction stays correct. 
Der Vorteil ist, dass die Reaktion auch dann korrekt bleibt, wenn Sie andere Zeiten verwenden. 

sunrisesunset.jpg.ff54956870c6a0b11a68f3aaf0d86cdb.jpg

Regards, Herman

 

 

Edited by Herman
translation

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...