overview of RTC date/time handling in Spin?
rikki
Posts: 53
Hello,
I'm a beginner with the Propeller product family.
I have both a Propeller Mini and a Spinerette.
I also have a DS1307 board from another firm which has been proven with the Propeller.
I want to create an application to run at a given time of day and look up a time of day constant from a table of dates (YR/MM/DD). I would be happy to use the Spinerette if possible, otherwise I'll use the Mini + DS1307.
I've surveyed the OBEX and have not found an example of time and date formats applicable in the Spin language.
Can anyone provide guidance or point me to an example from the OBEX?
Thanks very much in advance!
I'm a beginner with the Propeller product family.
I have both a Propeller Mini and a Spinerette.
I also have a DS1307 board from another firm which has been proven with the Propeller.
I want to create an application to run at a given time of day and look up a time of day constant from a table of dates (YR/MM/DD). I would be happy to use the Spinerette if possible, otherwise I'll use the Mini + DS1307.
I've surveyed the OBEX and have not found an example of time and date formats applicable in the Spin language.
Can anyone provide guidance or point me to an example from the OBEX?
Thanks very much in advance!
Comments
What you described makes sense and I'll happily and gratefully take the same approach.
I did purchase a Spinerette for this application, as it does have an RTC, (and my I/O needs are minimal).
Presumably there is some documentation to describe the RTC clock usage in the Spinerette, but I have yet to locate it.
(I am aware the Spinerette is at E-O-L, and I have further plans for that product)
I have not yet understood in what format the RTC data is on the Spinerette (or would be with the combination of Propeller Mini + external RTC).
I assume just a hex value at some location. I've no idea where
I do need date though, as well as time-of-day.
My interest otherwise for future purposes is with the Mini, primarily for use with the Xbee products. In that use-case I would not normally need a RTC, but I would like to learn how to use an external RTC with the Mini at some point.
As I have the Spinerette on hand for this one-time need, integration of the Mini with the external RTC isn't a priority at the moment, if I can get the Spinerette working for my immediate one-time project.
My understanding of I2C serial is minimal, but there are no doubt many good code examples in the PropellerTool library and the OBEX.
So I have some further homework to do.
I'm less than qualified, being not a software developer.
My experience is in industrial automation, where time and date would usually be in the IEC Time format, a datatype for date and time used in PLCs and SCADA.
The Propeller is such an intriguing product that I am determined to learn.
I have yet to power-up either of my Propeller boards for the first time. I hope to do so today in fact. I only just installed PropellerTool, and have failed so far in my attempts to install simpleIDE.
(I'm still learning the installation of non-packaged software in Linux / Ubuntu).
I am expecting to use the Propeller products to great advantage in the near future.
Thanks again for you help. It's a much-needed step in the right direction.
You need to click on the edit button then move down and click on "edit" in the popup box below.
Many thanks. Might ask what is the probability of success with a Propeller if I can't even see the EDIT button there.
Found this..
date_time
http://obex.parallax.com/object/191
and..
http://obex.parallax.com/object/36
For the PCF8583 RTC...
This may be the RTC on the Spinerette, yeah?
The BOM doesn't list a part-number for it..
( and I edited the thread title to include "..RTC.." )
Chances are pretty good if you are persistent and ask for help on the forum when you get stuck.
With regard to the time format, I would use the same format to store the time table that the RTC or OBEX interface object uses.