+-----o Vbatt | R1 # - # } Vr1 | + +---------o Vmeas | R2 # +- # | | --- Vlcd o---+ GND ADC_LCD_V_MEAS = ADC_VBATT + ADC_LCD_V_R1 ADC_LCD_V_R1 = (ADC_LCD_V_LCD - ADC_VBATT) * (ADC_LCD_R1 / (ADC_LCD_R1 + ADC_LCD_R2)) => (ADC_LCD_R1 + ADC_LCD_R2) * (ADC_LCD_V_MEAS - ADC_VBATT) = ADC_LCD_R1 * (ADC_LCD_V_LCD - ADC_VREF) => ADC_LCD_V_LCD = ((ADC_LCD_R1 + ADC_LCD_R2) * (ADC_LCD_V_MEAS - ADC_VBATT)) / ADC_LCD_R1 + ADC_VBATT