Electronic – Microcontroller input pin impedance/leakage current

adcinput-impedanceleakage-currentmicrocontroller

I'm using the internal ADC of an ATMEGA324PA to measure the voltage of a low power 3.6V battery. The ADC is referenced to it's internal 2.56V and I need to use a voltage divider on the battery.
To not draw too much current form battery I'm using large value resistors, but this is a problem, because the ADC input pin on uC is leaking at the most 1uA (according to the datasheet – page 328).

This can easily be compensated in the code, but is this leakage current constant? Does it vary with temperature, Vcc, etc. How much does it vary? Is this leakage caused by the input pin protection diodes (page 74)?

enter image description here

Best Answer

You could use a P channel MOSFET for connecting the battery to a lower resistance potential divider but it would need a spare GPIO line: -

enter image description here

The TPS1110 has a leakage current less than 100 nA so it won't draw too much from the battery.