Calibrate voltage readings
Anduril
3 clicks from off shows you the read battery voltage compare to measured voltage or assume full battery is 4.2V
in the light specific hwdef-“lights name”.h file
for 1S builds without voltage divider
// average drop across diode on this hardware
#ifndef VOLTAGE_FUDGE_FACTOR
#define VOLTAGE_FUDGE_FACTOR 6 // add 0.25V
#endif
change the diode offset value in 0.05V steps
.
for builds with LDO
// Raw ADC readings at 4.4V and 2.2V (in-between, we assume values form a straight line)
#ifndef ADC_44
#define ADC_44 184
#endif
#ifndef ADC_22
#define ADC_22 92
#endif
#define VOLTAGE_FUDGE_FACTOR 0 // add 0.25V
2 options:
- change the voltage fudge factor –1 is here about 0.1V lower
- change the ADC_44 and ADC_22 value similar to NarsilM
.
NarsilM
look if 3 clicks show proper voltage reading either at full or drained battery
Changes in the Setups.h file
LDO Builds
in NarsilM I have added different voltage reading tables those you can simple enable
#define VOLTAGE_MON // Comment out to disable - ramp down and eventual shutoff when battery is low
//#define VOLT_MON_R1R2 // uses external R1/R2 voltage divider, comment out for 1.1V internal ref
//#define USING_2200K
//#define USING_1000K // for 4S
//#define USING_1000K_01 // 2.8V +0.1
//#define USING_1000K_02 // 2.7V +0.2
//#define USING_1000K_m01 // 3V –0.1
//#define USING_1000K_m005 // 2,95V –0.05
//#define USING_680K // for 3S GT buck
//#define USING_680K_02 // 2.8V +0.2
//#define USING_680K_01 // 2.8V +0.1
//#define USING_680K_m01 // 3.0V –0.1
//#define USING_680K_m02 // 3.1V –0.2
//#define USING_680K_m03 // 3.2V –0.2
#define USING_360K // for using a 360K resistor (LDO and 2S cells)
//#define USING_360K_m01 // 3V –0.1
//#define USING_360K_m005 // 2.95V –0.05
//#define USING_360K_005 // 2.85V +0.05
//#define USING_360K_01 // 2.8V +0.1
//#define USING_220K // for using a 220K resistor (LDO and 1S cells)
.
for 1S builds change the diode offset
#define D1_DIODE 4 // Drop over rev. polarity protection diode: 0.2V normally, 0.3V for Q8, bigger value for too high voltage
.
Bistro HD
see if full battery shows 4.2 blinks in hidden modes or if the LVP is at 2.7V
change v correction value in the fr-calibration.h file
1S builds
//Calibration for traditional voltage-divider, NON LDO*/////////
//
#define v_correction 0.0 //in volts for minor calibration adjustment.
.
LDO builds
//LDO OTSM calibrataion//
//
#else // next version is the value used for LDO OTSM configs where the divider voltage is read relative to Vcc
#define v_correction 0.0 //in volts for minor calibration adjustment.
.
.
Calibrate temperature readings
Anduril
read the actual MCU temperature
- 3 clicks from Off followed by 3 double presses
measure the driver’s temperature with IR thermometer or use room temperature
2 options:
- while you are in the temp read from above do 4 clicks then follow user manual to set the calibration and the max. temp value
2. if use 10 clicks for thermal calibration is enabled in the setup file
10 click and then follow the manual
NarsilM
read actual MCU temp by 3 clicks followed by double press
in Setup.h
// Temperature Calibration Offset
#define TEMP_CAL_OFFSET (–6)
- change this value and compile a .hex so that the readout is as the drivers temp
- flash driver and check if it is now equal
Bistro HD
set the max limit in the light