Sun position

This logic group determines the current altitude of the sun and the azimuth every minute in order to trigger e.g. sun position-dependent actions with these values.

The cyclical calculation of the values is done by the logic editor element "LUA script". It calculates the sun's altitude and azimuth according to the specifications (time and location) and outputs the two values via the outputs.

The cyclic transmitter "minute cycle" triggers the algorithm stored in the LUA script every minute. The current time is transferred from the connected logic editor element "Timer".
The necessary coordinates for the location must be stored directly in the LUA script (lines 1 and 2 in the LUA script).

 

Necessary adjustment before using this example:
In the LUA script, the values for the longitude and latitude must be changed to the current location. To do this, the variables "BG" (line 1 - for latitude) and "LG" (line 2 - for longitude) are changed in the script. The currently stored location is Dortmund.

Longitude and latitude / GPS coordinates can be found, for example, under Google Maps or
https://www.laengengrad-breitengrad.de/ can be determined.

Gero Jöbstl
(169)

Sun position

1K
This logic group is compatible with: EP
*With the download you accept the Notes on use for logic groups.