How will the circuit hold the time? will it use current from the battery that is connected to it to hold the time?
You can have a counter, and the clock pulse stops when the supply is removed via a transistor, hence holding the timer value
You will have to have another power source though. just realised charge time will be affected lol.
Perhaps use a clock/alarm clock. Have a 1.5V or 3V output from the input power supply, and when power not connected, the clock will not run. And maybe set the charging time with an alarm clock
With the alarm clock, it can even switch off current to the batteries when charging is complete to prevent over charging
I am talking about an analogue clock btw, not digital as time may be reset due to power loss