Measuring High Voltage

Hy!
I have a simple, but special problem.
I want to measure the arduino's battery's voltage.
The battery is a 3cell li-ion, which max voltage is about 12,2V
How can I measure it with the onboard ADC?
Because i think if I use a voltage divider, it max change during the discharge of the battery, and works properly only at a given voltage, not changing V.

You need a voltage divider to get the voltage down to a level legal for the Arduino. If you use 1K between the input and Ground and 2K between the inout and +12.2 you should get a 'divide by 3'. Your maximum will be just over 4V so it will be safe for the Arduino input, assuming you are running the Arduino at 5V. Measure the input voltage and multiply by 3 to get the actual battery voltage.

Then i knew it wrong. Thanks for the help