History and charts
The camera keeps its own history for every tag in use. Charts on the overlay and the history in the DataBorder therefore need no server, no historian and no database anywhere else.
Stored data
The camera keeps measurements in three tiers of buckets. Each tier has a fixed number of slots.
| Tier | Period covered |
|---|---|
| One sample every 10 seconds | The last hour |
| One sample every minute | The last day |
| One sample every 10 minutes | The last week |
Each bucket keeps the minimum, the maximum, the last value and the average for its slot. A chart uses the finest tier that covers its window.
The camera keeps state tags as a log of transitions, up to ten thousand of them, together with hourly totals of the time spent in each state over the last week. The state strip, the donut, the state table and the hourly bars all draw from this log.
The camera keeps strings as a log of changes, up to a thousand entries.
When the next transition arrives, entry 0 is dropped and the rest shift down.
One bar is one hour, so every bar is full height.
Fixed size allocation
Each measurement tag takes about 90 kilobytes of memory, allocated once. The history never grows beyond that. When a tier is full, the newest bucket overwrites the oldest.
A camera with a few dozen tags in use keeps a week of history.
Stored tags
The camera polls and stores only tags in use. A tag is in use when it is on the overlay, in the DataBorder, or feeding a derived state. When a tag stops being used, the camera keeps its history for six hours, in case you are rearranging the layout, and then drops it. Deleting a tag from the library drops its history at once.
Restarts
The camera writes closed hours and closed days to its flash memory as read-only segments, once each. It writes the open hour and the state and string logs every 30 minutes and on a clean shutdown, and only when something has changed. After a restart, it restores the minute and 10-minute tiers from flash, and the 10-second tier refills within the hour.
The Stored data panel shows how full each tier is for every tag, when the history was last saved, and how much memory and flash it uses. See Status and troubleshooting.
Chart windows
Chart and state elements draw over a window chosen per element.
- A rolling window covers the last 15 minutes, hour, 8 hours, day or week, and always ends now.
- An anchored window covers this hour, this shift or today. It starts empty at the boundary and fills in. Shift boundaries are the start times you set under Settings → Shifts.
The time axis can show wall-clock times at the ends of the window, or offsets from now.
Full history in the DataBorder
The DataBorder can carry the last 24 hours of state runs, so that a decoded clip starts with context. It can also cycle the camera's full stored history, so that a longer clip reconstructs the charts above from the video alone. Both are options on the DataBorder page.