rusEFI
The most advanced open source ECU
Loading...
Searching...
No Matches
redundant_ford_tps.h
Go to the documentation of this file.
1#pragma once
2
3#include "sensor.h"
4
5class RedundantFordTps final : public Sensor
6{
7public:
9 SensorType outputType,
10 SensorType firstSensor,
11 SensorType secondSensor
12 );
13
14 void configure(float maxDifference, float secondaryMaximum);
15
16 SensorResult get() const override;
17
18 bool isRedundant() const override {
19 return true;
20 }
21
22 void showInfo(const char* sensorName) const override;
23
24private:
25 // The two sensors we interpret to form one redundant sensor
28
29 // How far apart do we allow the sensors to be before reporting an issue?
30 float m_maxDifference = 0;
31
32 // At what primary % does the secondary hit 100%?
34};
bool isRedundant() const override
SensorResult get() const override
const SensorType m_first
const SensorType m_second
void showInfo(const char *sensorName) const override
void configure(float maxDifference, float secondaryMaximum)
Base class for sensors. Inherit this class to implement a new type of sensor.
expected< float > SensorResult
Definition sensor.h:46
SensorType
Definition sensor_type.h:18