I thought I did this in every file, but I forgot to do it in the
PressureSensor.h one. This is now rectified.
const float m_resistance; // in Ohms
const float m_max_pressure;
- static const float MIN_CURRENT = 4e-3; // in A
- static const float MAX_CURRENT = 20e-3; // in A
- static const float REFERENCE_VOLTAGE = 5; // in V
- static const int CONVERSION_BIT_NUM = 10;
+ static constexpr float MIN_CURRENT = 4e-3; // in A
+ static constexpr float MAX_CURRENT = 20e-3; // in A
+ static constexpr float REFERENCE_VOLTAGE = 5; // in V
+ static constexpr int CONVERSION_BIT_NUM = 10;
float signal_to_pressure(int ad_signal) const;