An asset can have a location (latitude and longitude) and a time zone. They put sites on maps and tell Rules card rules when sunrise is and what “07:00” means at that place. This page explains how to set them and which parts of Hermetry read them.
Set a location and a time zone
- Open Sites & Assets and open the asset’s drawer.
- Select Edit.
- Enter Latitude (−90 to 90) and Longitude (−180 to 180) in decimal degrees, for example
41.0151and28.9795. A value out of range is refused: “Latitude is -90..90 and longitude -180..180.” - Enter Time zone as an IANA name, for example
Europe/Istanbul,Europe/BerlinorAmerica/New_York. An unknown name is refused. - Select Save.
Leave the fields empty when they do not apply. Through the API, the fields are lat, lng and timezone; see Sites and assets API.
Get coordinates from any map application: open the place, copy the latitude and longitude, and use a dot as the decimal sign.
Inherited time zone
An asset without its own time zone shows its parent’s in the drawer’s Overview, for example “Europe/Istanbul (from Istanbul plant)”: the nearest asset above it that has one.
Important
This inheritance is for display only. Rules read the time zone of the asset itself, as described below. Set the time zone on every asset that is a rule’s home, or on every asset devices are placed on, if their rules use time windows.
Locations are not inherited at all.
What uses the location
| Feature | Uses |
|---|---|
| Sites on the map on Sites & Assets | Each site’s location; sites without one are listed as No location |
| Sites board template | The map card places each site at its location; the site page’s header shows the coordinates when the site has nothing above it and no address |
| Rules card: Sunrise or sunset trigger, Day or night condition | The home asset’s location; for a device home, the location of the asset the device is placed on. Without it: “Sunrise and sunset need this place’s location: set it on the place first.” |
Devices have their own positions (lat and lng in their attributes or telemetry), which device maps use. A device’s position does not place it on an asset: see Placing devices.
What uses the time zone
| Feature | Time zone used |
|---|---|
| Rules card: A time window, Months or dates, A public holiday, the Next run shown on the card | The time zone of the rule’s home asset; for a device home, of the asset the device is placed on; UTC if that asset has none |
| Rules card: A time of day, Days of the month triggers | Your organisation’s time zone (Settings > General > Timezone) |
History API day buckets (1d) | Always UTC |
So a rule “at 07:00, only if between 06:30 and 07:30” fires at 07:00 organisation time and checks the window in the place’s time zone. Keep both the same, or set them deliberately. Details: Time, sunrise/sunset, dates and holidays.
Daylight saving
Time zones follow daylight saving. A time that does not exist on the day the clocks go forward does not fire. Use IANA names, not fixed offsets such as +03:00, so the change is followed.
Checklist for a new site
- Give the site a latitude, longitude and time zone.
- Give every building, room or machine that is a rule’s home, or holds devices with time-window rules, the same time zone.
- Give those assets a location too if their rules use sunrise or sunset.
- Check the drawer’s Overview: the time zone should show without “(from …)” where rules need it.
Troubleshooting
| Problem | Cause |
|---|---|
| A site is not on the map | It has no latitude and longitude |
| A sunrise rule cannot be saved | The home asset (or, for a device home, its asset) has no location |
| A time window is one or more hours off | The home asset has no time zone of its own, so UTC is used; or the organisation’s time zone differs from the place’s |
| A daily total does not match the local day | History day buckets are UTC days; sum hourly buckets instead, see The history API |

