75 #ifndef FOXBMS__BETA_H_
76 #define FOXBMS__BETA_H_
92 #define BETA_POSITION_IN_RESISTOR_DIVIDER_IS_R_1 (false)
95 #define BETA_RESISTOR_DIVIDER_SUPPLY_VOLTAGE_V (4.096f)
101 #define BETA_RESISTOR_DIVIDER_RESISTANCE_R_1_R_2_Ohm (10000.0f)
104 #define BETA_T_REF_C (25.0f)
107 #define BETA_R_REF_Ohm (10000.0f)
110 #define BETA_BETACOEFFICIENT (3984.0f)
142 #ifdef UNITY_UNIT_TEST
float_t BETA_ResistanceFromTemperature(int16_t temperature_ddegC)
returns NTC resistance corresponding to temperature, used to compute Vmin and Vmax of the divider
int16_t BETA_TemperatureFromResistance(float_t resistance_Ohm)
returns temperature corresponding to NTC resistance
int16_t BETA_GetTemperatureFromBeta(uint16_t adcVoltage_mV)
returns temperature based on measured ADC voltage