Times

The Miniserver can either use the Internet to set its time or can use the local time on your PC, so there are parameters which are defined in the Times section of the Periphery tree window to use in your program.

Loxone Musterkoffer

Information

In the Periphery tree window click on the first entry. Here you can enter all the information about your project. As long as you have Internet access when you save the details of the project such as the postcode (put in the entry Town). This will enable the Miniserver to calculate its time and hence you can then use all the values in the Times section in your program accurately.

Overview

You can find the times in the Periphery tree window underneath the section Server communication (beneath the Miniserver). 

Times

Name Description
Annual pulse

A pulse each year on 01/01/YYYY at 00:00

Calendar type

Number of the current day of the calendar

Day

Returns the current day

Daylight

Is on when it is daylight according to location

Daylight 30min Is on when it is daylight plus 30 minutes after sunrise and 30 minutes before sunset
Days since 2009 Number of days that have passed since 01/01/2009 (Loxone epoch)
Hour

Outputs the hour of the current time, e.g. 12:43:05 would return 12

Minutes

Outputs the minutes of the current time, e.g. 12:43:05 would return 43

Minutes past midnight Specifies how many minutes have passed since midnight
Time to dawn Specifies how many minutes since midnight it is until dawn that day
Time to dusk Specifies how many minutes since midnight until it is dusk that day
Time to sunrise Specifies how many minutes since midnight until sunrise that day
Time to sunset Specifies how many minutes since midnight until sunset that day
Month

Returns the current month as a number, e.g. November would be 11 

Pulse for dawn Pulse at the transition between night and day just before sunrise
Pulse for day

Daily pulse at 00:00

Pulse for dusk Pulse at the transition between night and day just after sunset
Pulse for hour Pulse at every hour
Pulse for minute Pulse at every minute
Pulse for month Monthly pulse on the 01/MM/YYYY at 00:00
Pulse for second Pulse every second
Pulse for sunrise Pulse when the sun is moving above the horizon at the point it crosses
Pulse for sunset Pulse when the sun is moving below the horizon at the point it crosses
Seconds Outputs the seconds of the current time, e.g. 12:43:05 would return 5
Seconds since boot Seconds since the last time that the Miniserver booted
Start pulse Provides a pulse when the Miniserver boots
Sun direction 

Returns the current direction of the sun from 0° to 359°. This value is continually updated. North = 0°, East = 90°, South = 180°, West = 270°

Sun elevation

Returns the current elevation angle of the sun to the horizon from 0° to 90°, this is also continually updated

Weekday

Returns the current day of the week: Monday = 0, Tuesday = 1, Wednesday = 2, Thursday = 3, Friday = 4, Saturday = 5, Sunday = 6

Year

Outputs the year of the current date, e.g. 15/11/2013 would return 2013

Examples

Curtains open at sunrise

Often people would like that their curtains open at sunrise. Not at 7:00 am, not at 8:00 am, but at sunrise. With Loxone no problem!

Just use the Pulse for sunrise found in the Times. In this example the pulse is connected to a memory flag and then this can be used on all the Automatic blind blocks. It is connected to the Cu input which drives the curtains fully open.

The opposite has also been implemented by using the Pulse for dusk as well so the curtains close in the evening.

Motion detector only brings on lights at night

In a bathroom at night you might want to use a motion detector to bring on some low level lights. You wouldn't want this to happen at day. To do this simply use the Lighting controller program block with the time "Daylight". 

Connect the motion sensor to the input Mv on the Lighting controller. See more about this here. Then associate a night scene with the motion sensor.

To stop the motion sensor coming on in the day connect the time input "Daylight" to the DisM input. If this input is active the motion sensor will be disabled and won't turn on the night scene when triggered.

Outdoor lighting for evening

The outside lights in this configuration are set to turn on 90 minutes after sunset and then off at midnight. The lights can also be directly controlled in the UI with the pushbutton block.

First the time "Minutes until sunset" is connected to an Add (2-way) block with the constant 90. Then when the time "Minutes past midnight" is equal to this value this turns the outdoor lights on (connected to the O always on input of the pushbutton). 

Then when the time "Minutes past midnight" is equal to zero the lights go off (this is connected to the R input on the pushbutton).

Using constants means it is easy to quickly change the times the lights come on and go off at.