I want to run my project off a 9V battery. I am struggling to find a way to be able to monitor the power level of the battery and display this through my project and on my lcd. I would also like to monoitor the battery level on the backup battery of my rtc module if that is possible
Does any one have any advice for me please?
this youtube video on monitoring the power level of a battery may be of interest to you.
I would also like to monoitor the battery level on the backup battery of my rtc module if that is possible
I believe it would require making connection directly to the battery holder on your RTC and monitoring it with an analog input. I would caution you on doing this as even thought the analog input draws very little current it will still pose a drain on this small battery, potentially shorting it's life.
Thanks for the advise and info.
Appreciate it.
it will still pose a drain on this small battery
Hi @ ruplicator, the video link I posted shows using an external circuit to monitor the battery and towards the end it is shown how to use a timer to periodically wake the circuit to test a battery meaning the circuit is only live for a very short time to minimise the current drain. Of course some drain on the battery will take place, but this could be minimised by severely limiting the wake up time and test duration. So maybe not to discount this for monitoring the spare battery ? 🤔
You will want to use a voltage divider to read the battery voltage via an analog pin. Google "Reading voltage from battery voltage divider"
I think the video you referenced is very appropriate example for monitoring the 9V supply the OP asked about. The video was covering how to monitor a LiPo with potentially thousands of mA of storage.
I was trying to cover the other question about the backup battery on a Real Time Clock. These batteries are very small and can easily have their life reduced if mishandled by just getting oil from your skin between their poles. Even a FET has resistance in the off condition that is comparative to residue fingerprint oil.
However, depending on the application and how critical it is to know the state of the backup battery rather than implementing a replacement schedule it might be appropriate to measure the battery.
I myself would not monitor a battery like this. A good one should run for a long time.