bs2pe interfacing with real time clock
roberto
Posts: 37
have never used the ds1302 (real time clock) would it be hard to log time real time to the eeprom for every event recorded?
is there an example anywhere someone have used real time clock has a logger using the
write commad?
i did go over the example to run the real time clock in parallax downloads but nothing refering has a logger.
thanks for any links
is there an example anywhere someone have used real time clock has a logger using the
write commad?
i did go over the example to run the real time clock in parallax downloads but nothing refering has a logger.
thanks for any links
Comments
·· It really depends on how much data you need to store and at what interval.· There are two ways to log data.· One is at a fixed interval.· In a situation like this you only need to store the date/time information once, since all the other samples would have a known sample interval.· The second method is event logging, and that could require a varying number of bytes depending on how much information you're storing.· The number of bytes of data plus the number of bytes of date/time information will dictate how much you can store.· And you would simply write this data, then increment your pointer by that number of bytes.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com
http://forums.parallax.com/showthread.php?p=531080
For Data logging, you might find the manual for Scott Edward's data collection proto board of value: www.seetron.com/obs.htm
The OWL2pe data logger is based on the BASIC Stamp 2pe, and the manual talks about how to use the DS1307 in the context of data logging:
www.emesystems.com/OWL2pepr.htm
Parallax Stamp in Class volume on Applied Sensors uses the BASIC Stamp as a data logger.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Tracy Allen
www.emesystems.com
·· Your post reminded me that I had some feedback for pending improvements to that code and so I made them and reposted the new code to that thread in place of the old code.· One of the suggestions was a template since many people didn't know what to remove from the demo code to use the DS1302.· I should've done that right from the start so I included it.· And your advice in the other thread about storing pointers and other NV data that gets updated more frequently is spot-on.· The DS1302 RAM is backed up along with the Clock when using a battery.·
BTW, I liked your code for spanning multiple slots using STORE in one formula.· Simple, yet powerful.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support
csavage@parallax.com