[SOLVED] ds1307 doesnot run when disconnected from vcc

Status
Not open for further replies.

avirajose

Junior Member level 3
Joined
Nov 28, 2011
Messages
29
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,281
Location
India
Activity points
1,491
hi all,
I have sucessfully interfaced ds1307 with pic16f877a and is working fine. But it only starts its oscillation when in vcc only. When i disconnect the vcc ,it stops the oscillation and simply store the previous date.
can anyone suggest me a solutionb for it.
 

Post your circuit and code to find out the problem..
 

check the data sheet there is a bit to enable oscillation i thing it is at address 0 in SEC reg
 


Why would you expect any other result?

The DS1307 requires some method of power to function. It does offer the option to implement a battery backup, which is the purpose of Vbat pin.


The DS1307 has a built-in power-sense circuit that detects power failures and automatically switches to the backup supply. Timekeeping operation continues while the part operates from the backup supply.




BigDog
 

check the data sheet there is a bit to enable oscillation i thing it is at address 0 in SEC reg

ya, there is a bit to enable oscillation. And it is enabled. But, as i said before,it oscillates while connected to vcc......while disconnected from vcc, it just act as eeeprom just saving the previous time.
 

apart from what bigdog has said , do look at the voltage of the battery (if you have hooked up one) . If it is below a particular value ( look up the datasheet) then the ds1307 will stop oscillating and just preserve the last time . This happened with me once - the 3.6v battery i was handed out was actually supplying 1.9v.
 

k, thanks a lot for all the replies......the problem was with ds1307..Replacing it solved my pro.and is working fine
 

Status
Not open for further replies.

Similar threads

Cookies are required to use this site. You must accept them to continue using the site. Learn more…