Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 02:53 29 Nov 2024 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : RTC module

Author Message
viscomjim
Guru

Joined: 08/01/2014
Location: United States
Posts: 925
Posted: 09:09am 02 Mar 2014
Copy link to clipboard 
Print this post

Does anyone know if the real time clock interface mmbasic command for PCF8563 in uMite is compatible with the DS1307 or the DS3231 ChronoDot modules sold by adafruit?

Thanks!!!
 
BobD

Guru

Joined: 07/12/2011
Location: Australia
Posts: 935
Posted: 09:29am 02 Mar 2014
Copy link to clipboard 
Print this post

  viscomjim said   Does anyone know if the real time clock interface mmbasic command for PCF8563 in uMite is compatible with the DS1307 or the DS3231 ChronoDot modules sold by adafruit?

Thanks!!!

It is not compatible. Check the datasheets of both devices.
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6101
Posted: 10:12am 02 Mar 2014
Copy link to clipboard 
Print this post

It is not the same but all the mentioned RTC modules ate I2C and easy to talk to from MM Basic.

Each RTC has its own advantages and disadvantages.
If you are intending to run from 3.3V, don't use the DS1307.

Jim
VK7JH
MMedit   MMBasic Help
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9308
Posted: 12:08pm 02 Mar 2014
Copy link to clipboard 
Print this post

  TassyJim said  RTC modules ate I2C and easy to talk to from MM Basic.


How do you eat an I2C?

Smoke makes things work. When the smoke gets out, it stops!
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6101
Posted: 12:42pm 02 Mar 2014
Copy link to clipboard 
Print this post

  Grogster said  
  TassyJim said  RTC modules ate I2C and easy to talk to from MM Basic.


How do you eat an I2C?


With chips.


VK7JH
MMedit   MMBasic Help
 
Lou

Senior Member

Joined: 01/02/2014
Location: United States
Posts: 229
Posted: 12:47pm 02 Mar 2014
Copy link to clipboard 
Print this post

Good one TassyJim. I was wondering myself, now I know.

Lou
Microcontrollers - the other white meat
 
Grogster

Admin Group

Joined: 31/12/2012
Location: New Zealand
Posts: 9308
Posted: 02:23pm 02 Mar 2014
Copy link to clipboard 
Print this post

  TassyJim said  
  Grogster said  
  TassyJim said  RTC modules ate I2C and easy to talk to from MM Basic.


How do you eat an I2C?


With chips.



Excellent come-back, and a double-pun!

Well done!

Smoke makes things work. When the smoke gets out, it stops!
 
jpconil
Newbie

Joined: 24/01/2014
Location: France
Posts: 2
Posted: 10:34pm 02 Mar 2014
Copy link to clipboard 
Print this post

Hello,

Here is the code I am using with a DS1307 connected to a Duinomite-Mini running MMBasic V4.4B :

'Ce programme de test marche avec un DS1307
'On lit l'heure, la date etc puis on l'affiche
'
Dim Table(8)
I2CEN 100,100

Do
I2CRCV &h68, 0, 7, Table(1), 1, &h00 'lit les secondes, minutes, etc

Secondes = ((Table(1) And &b01110000)/16)*10 + (Table(1) And &b1111)
Minutes = ((Table(2) And &b01110000)/16)*10 + (Table(2) And &b1111)
Heures = ((Table(3) And &b01110000)/16)*10 + (Table(3) And &b1111)

Cls
Print Heures; " :"; Minutes ; " :"; Secondes
Pause 1000
Loop


I got a module with a Lithium battery for US$1.5 on ebay. But it has an error of several seconds by day. There is another product of Maxim vith a better accuracy and the same I2C adress.

Cordially
 
viscomjim
Guru

Joined: 08/01/2014
Location: United States
Posts: 925
Posted: 11:41am 03 Mar 2014
Copy link to clipboard 
Print this post

Hi jpconil,

That code looks easier than what I thought it would be. Do you have code to set the time for the ds1307? The PCF8563 module seems to be difficult to get here in the states, unless I get it from overseas.

Thanks for you for your time.
 
Print this page


To reply to this topic, you need to log in.

© JAQ Software 2024