Go Down

Topic: time clock module.. (Read 1 time) previous topic - next topic

Ruffsta

i bought this for my son, but we cannot find any tutorials or anything else he needs to use it...



found this, but it's not the same..
http://combustory.com/wiki/index.php/RTC1307_-_Real_Time_Clock

thanks in advance

tuxduino

The Time library has good support for DS1307.

http://playground.arduino.cc/Code/Time

Nick Gammon

I would connect up SDA, SCL, 5V, and Gnd as described in that article and saw what happened.
Please post technical questions on the forum, not by personal message. Thanks!

More info:
http://www.gammon.com.au/electronics

NickPyner

#3
Jan 02, 2013, 01:06 am Last Edit: Jan 02, 2013, 01:32 am by NickPyner Reason: 1
The clocks are the same, they just look different. I have the blue one just like yours. I had as seriously bad time getting any joy from it. This was partly due to my being a newbie, but far from wholly. I believe there is a swag of confusing and out-of-date junk out there - and badly written too. Since you ask the question, I assume you two are newbies. Being a newbie puts you at the disadvantage of having the latest gear, thereby having to sort the wheat from the chaff, and quite a lot of that chaff is in the Arduino playground.

About the only decent up-to-date tutorial written for the  DS1307 is here

http://bildr.org/2011/03/ds1307-arduino/

Read the first line in the code twice, indeed they write it twice.  

You only need four wires. Most of the terminals on the blue board are duplicates and it doesn't matter which one you use.

There are two sketches, one for setting the clock and the other for running. You write the setting time in the first sketch and the start point is when you release the reset button. Needless to say, the two sketches can be merged if you wish, and it might be an interesting programming exercise involving serial read, but I haven't bothered. My module came running on Shanghai Time.

tuxduino

The Time library takes care of communication with the DS1307 for you. Highly recommended.

CrossRoads

You have 2 chips on the I2C bus there - the DS1307, and a Atmel 24C32 EEPROM.

http://datasheets.maximintegrated.com/en/ds/DS1307.pdf
http://www.atmel.com/Images/doc0336.pdf

Both are addressed individually.
Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

projectstowork1

May I ask what is the purpose of adding the 24c32 for the ds1307 chip?

Boffin1

Quote
May I ask what is the purpose of adding the 24c32 for the ds1307 chip?


I have used part of the 56k of the DS1307s  nv memory ok, but I guess there might be projects that need more ?
With my mobile phone I can call people and talk to them -  how smart can you get ?

AWOL

Quote
I have used part of the 56k
bytes
"Pete, it's a fool looks for logic in the chambers of the human heart." Ulysses Everett McGill.
Do not send technical questions via personal messaging - they will be ignored.

Jack Christensen


May I ask what is the purpose of adding the 24c32 for the ds1307 chip?


Typical data logging setup. Memory to store the data and an RTC to time the sampling.
MCP79411/12 RTC ... "One Million Ohms" ATtiny kit ... available at http://www.tindie.com/stores/JChristensen/


Boffin1


Quote
I have used part of the 56k


bytes of course :-)
With my mobile phone I can call people and talk to them -  how smart can you get ?

Go Up