70 void put(
unsigned index, uint64_t timestamp,
const float val[3], uint64_t error_count,
int priority);
77 float *
get_best(uint64_t timestamp,
int *index);
void put(unsigned index, uint64_t timestamp, const float val[3], uint64_t error_count, int priority)
Put an item into the validator group.
void set_timeout(uint32_t timeout_interval_us)
Set the timeout value for the whole group.
DataValidator * _first
first node in the group
int failover_index()
Get the index of the failed sensor in the group.
DataValidator * _last
last node in the group
void print()
Print the validator value.
uint32_t failover_state()
Get the error state of the failed sensor in the group.
DataValidatorGroup operator=(const DataValidatorGroup &)
float * get_best(uint64_t timestamp, int *index)
Get the best data triplet of the group.
static constexpr float MIN_REGULAR_CONFIDENCE
float get_vibration_offset(uint64_t timestamp, int axis)
Get the vibration offset in the sensor unit.
float get_vibration_factor(uint64_t timestamp)
Get the RMS / vibration factor.
void set_equal_value_threshold(uint32_t threshold)
Set the equal count threshold for the whole group.
DataValidator * add_new_validator()
Create a new Validator (with index equal to the number of currently existing validators) ...
unsigned failover_count() const
Get the number of failover events.
uint32_t _timeout_interval_us
currently set timeout
A data validation class to identify anomalies in data streams.
int _prev_best
the previous best index
int _curr_best
currently best index
unsigned _toggle_count
number of back and forth switches between two sensors
DataValidatorGroup(unsigned siblings)
uint64_t _first_failover_time
timestamp where the first failover occured or zero if none occured