Wiki source code of Filtering sensor readings

Last modified by Андрей Калиновский on 2023/04/25 14:39

Show last authors
1 Software filtering of sensor values ​​is intended for smoothing and filtering sensor readings that do not have hardware filtering. Filtering should be used when it is necessary to remove erroneous values, much more or less than other values.
2
3 The median filtering algorithm is used to filter sensor readings.
4
5 Filtering of sensor readings is available for simple sensors of the following types:
6
7 * (((
8 Onboard voltage
9 )))
10 * (((
11 Engine speed
12 )))
13 * (((
14 Engine temperature
15 )))
16 * (((
17 trailer temperature
18 )))
19 * (((
20 Fuel level
21 )))
22 * (((
23 Fuel level in the tank
24 )))
25 * (((
26 grain level
27 )))
28 * (((
29 Arbitrary
30 )))
31
32 If one of the listed sensors is selected, the filtering settings will be displayed in the sensor settings window:
33
34 [[image:image-20230425143905-1.png]]
35
36 * (((
37 Use median filtering
38 )))
39
40 Enables the sensor's median filtering algorithm.
41
42 * (((
43 Degree of filtration
44 )))
45
46 Sets the degree of filtering, values ​​from 0 to 255 are available for input. The degree of filtering means the number of messages that will be used for filtering. The value entered in the filtration degree field is multiplied by 5, the value obtained after multiplication will be the number of messages to filter. If 0 is entered, then 3 messages will be used for filtering. The larger the value, the more the data will be “smoothed out”, therefore it will differ significantly from the original data.
47
48 **If filtering is enabled for a sensor, then the filtered dataset will be used for event calculations, display of calculation results in tooltips, reports, including Report Builder, and user graphs.**
49
50 If tare is used for sensor values, then filtering will be applied after taring the “raw” values.
51
52 If the virtual sensor includes a simple sensor with filtering enabled, then the filtered data will also be used to calculate the readings of the virtual sensor.
53
54 Filtering example:
55
56 Fuel level graph  **without filter option enabled**
57
58 [[image:image-20230425143909-2.png]]
59
60 Fuel level graph  **with filter option enabled**
61
62 [[image:image-20230425143912-3.png]]

Меню

GLONASSSoft wiki - 2023 г