You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+19-6Lines changed: 19 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -19,7 +19,7 @@ In the following listing you see a very simple example for a logbook file. It ke
19
19
2021-01-31 18:00:00 -0.926 89.06
20
20
2021-01-31 18:30:00 -1.14067 89.1933
21
21
22
-
## Data accumulation and statistical summary
22
+
## Data accumulation and statistical summary
23
23
24
24
Sensorlogger is able to read values from Tinkerforge sensors and JSON structures in user-defined **time intervals.** After reading, these values can be forwarded immediately to MQTT brokers or to a HomeMatic CCU (the XML-API is used to set system variables using their ISE-ID). The values are also stored internally until they become irrelevant for any further statistical analysis.
25
25
@@ -68,7 +68,7 @@ The virtual package `libcurl-dev` offers different implementations. All of them
68
68
69
69
### MQTT Support
70
70
71
-
If you need support for MQTT, the Paho MQTT libraries for C and C++ must be installed. You can get packages for Arch-based distributions for the AUR: [paho-mqtt-c-git](https://aur.archlinux.org/packages/paho-mqtt-c-git/) and [paho-mqtt-cpp-git](https://aur.archlinux.org/packages/paho-mqtt-cpp-git/). For Debian-based systems (e.g. Raspberry Pi, Tinkerforge Red Brick) we have to compile and install the libraries on our own. To do this, we need to make sure that we already have all the required packages installed:
71
+
If you need support for MQTT, the Paho MQTT libraries for C and C++ must be installed. You can get packages for Arch-based distributions from the AUR: [paho-mqtt-c](https://aur.archlinux.org/packages/paho-mqtt-c/) and [paho-mqtt-cpp](https://aur.archlinux.org/packages/paho-mqtt-cpp/). There also exist [Debian packages](https://packages.debian.org/search?suite=stable§ion=all&arch=any&searchon=names&keywords=paho-mqtt) for newer distributions. If not, we have to compile and install the libraries on our own. To do this, we need to make sure that we already have all the required packages installed:
72
72
73
73
apt-get install libssl-dev build-essential gcc make
74
74
apt-get install cmake cmake-gui cmake-curses-gui
@@ -168,6 +168,7 @@ The `general` section of the configuration file may contain the following settin
@@ -179,6 +180,12 @@ The `general` section of the configuration file may contain the following settin
179
180
180
181
Standard value: `null`
181
182
183
+
+`"logfile_max_lines":` Maximum number of lines in the log file. If the log file grows bigger than this limit, it will be trimmed by removing the oldest lines from the top. Note that for performance reasons, the log file is only trimmed when Sensorlogger starts and then every time after 100 lines have been written.
184
+
185
+
Set this value to `0` to deactivate trimming of the log file.
186
+
187
+
Standard value: `10000`
188
+
182
189
+`"loglevel":` Type of events that are logged. Can be any of the following:
183
190
-`"error"`: Only log error messages.
184
191
-`"warning"`: Log errors and warnings.
@@ -746,12 +753,14 @@ The `"columns"` key (as a child node of a logbooks object) always hosts a JSON a
746
753
"confidence_absolute": 10.0,
747
754
},
748
755
{
749
-
"title": "Humidity",
756
+
"title": "Maximum humidity today",
750
757
"unit": "%rel",
751
758
"sensor_id": "Weather/Humidity",
752
-
"mqtt_publish": "House/Weather/Humidity/median",
759
+
"mqtt_publish": "House/Weather/Humidity/max24h",
753
760
"homematic_publish": "37856",
754
-
"operation": "median",
761
+
"operation": "max",
762
+
"evaluation_period": {"value": 24, "unit": "h"},
763
+
"reset_times": ["0:00"],
755
764
"confidence_sigma": 3.0
756
765
},
757
766
{
@@ -803,6 +812,10 @@ The `"columns"` key (as a child node of a logbooks object) always hosts a JSON a
803
812
804
813
Standard value: `null`
805
814
815
+
+`"reset_times":` Specific points in time when the column values are reset, i.e., the value cache for this column is cleared. For example, when an evaluation period is defined to calculate a moving average, the accumulated data can be cleared at midnight such that the previous day is not part of the moving average. Likewise, a daily maximum for a value can be computed.
816
+
817
+
The reset times are listed in an array. An arbitrary number of reset times can be defined. Each reset time is a string that contains hour and minute in 24-hour format, such as `"14:30"`. To repeat a reset at a certain minute every hour, the star notation can be used: `"*:00"` does a reset every full hour.
818
+
806
819
+`"count_factor":` This factor can be used to weight the number of events of a pulse counter. It only affects the counter operations `"count"`, `"freq"`, `"freq_min"` and `"freq_max"`. In the example above, the wind sensor triggers two pulses per rotation, so we scale the pulse frequency by a factor of 0.5 to get the rotation frequency.
807
820
808
821
Standard value: `1`
@@ -832,7 +845,7 @@ The `"columns"` key (as a child node of a logbooks object) always hosts a JSON a
832
845
833
846
### Tinkerforge: Supported Bricklets
834
847
835
-
Currently, version 2.1.33 (2022-05-11) of the [Tinkerforge](https://www.tinkerforge.com/) C/C++ bindings are used. The following Tinkerforge Bricklets are supported. The table also lists the channel IDs if a Bricklet supports different types of measurements.
848
+
Currently, version 2.1.34 (2024-02-27) of the [Tinkerforge](https://www.tinkerforge.com/) C/C++ bindings are used. The following Tinkerforge Bricklets are supported. The table also lists the channel IDs if a Bricklet supports different types of measurements.
0 commit comments