Need help Stop using button cell power when current gone Ds3231

I made a clock using ds3231 ic using uno r3 and oled display . please look the schematic carefully

|500x249

when my electricity load shedding happens atmega going to use button cell battery and also oled using button cell charge. its very big problem after load shedding i see my clock is little slow down such 10 second .How to solve this problem to not eat up button cell charge , i have no idea ,need help. :( :(

The battery should last for years, and the DS3231 should keep very accurate time.

You have probably wired it incorrectly, but Fritzing diagrams are almost always useless. This one is no exception.

1) The DC jack needs a minimum of 7volt for the onboard regulator to make a stable 5volt.

2) Why the AMS1117. A DS3231 module can most likely run on 5volt (I2C signals need to be 5volt).

If you need 3.3volt, the Uno has an onboard 3.3volt/150mA regulator. Leo..

ok i will increse it 7 volt , my problem point is if my power supply or power source off for a while ,then attempt to the circuit(circuit is look like button cell battery connect with ds3231 on the other way arduino and oled connect with same source ) arduino and oled are going eating ds3231 button cell charge ... how to stop it ?

Your Fritzing picture shows a bare chip and a button cell. You might not have that.

Post a link to the RTC module that you actually are using. The DS3231 RTC module I have does NOT drain the battery when the Arduino is powered off. Why do you think that will happen. Leo..

ds3231 ic not avaiable in fritizinfg so i use 8X2 pin like ds3231 , when current is gone my powersupply is off then i look the Arduino green and yellow light still on but dim mode ,so probally its look like arduino eating button cell anyhow i have to stop this draing via diode ,but i dont know where i set the diode and what kind of diode i used ?

Just hook your battery to the VBAT pin of the DS3231, not the VCC pin.

thanks Edison

thanks Edison

!Edison |500x250 ;P