How to measure battery voltage using ATmega8 processor (by Ziggy)
LD micro and Atmel AVR rely on supply voltage as the reference voltage for the ADC.
In order to measure battery voltage an external reference is needed unless it is possible to select and enable internal reference using LDmicro.
Advice is sought to either enable internal reference on an ATmega 8 processor or some other low cost solution to be able to check the status of batteries.
(no subject) (by Ziggy)
Thank You for the update.
I had resolved this problem with additional external hardware by setting up an external 2.5V reference.
In the earlier versions of LDmicro it was not possible to select Aref other than Aref = Vcc.
The idea is to set up the reference and measure it against VCC, As battery voltage diminishes, external analog reference will apparently grow in value.
At a certain point in battery life external reference will apparently go beyond a certain maximum acceptable value and an alarm will be raised.
The option You have put above is so much more elegant and economical.
re:suggestion (by Brat Steve)
The working part where it will be going to get the working aspects which will be having the overall part to the external reference ensure it to which is going to beyond the setting the part.