Go Down

Topic: Time Library added to Playground (Read 39 times) previous topic - next topic


mem - Thanks for the reply and new time set function.
Is there a common external site you guys use here to link to ?
I am thinking of building some king of general purpose logger which I want to run on batteries (1 li-ion bat) but I am afraid if I reduce the clock speed I will loose the functionality of the RTC .
AN example would be loging my body temperature along the day and having the Atmega wake up every min or so and sample the temperature place in flash with current time and go back to sleep . Other examples would be to wake up on external events (open door etc').
B.T.W this is a link to the project I posted on INSTRUCTABLES http://www.instructables.com/id/Arduino-True-Battery-Capacity-Tester-Li-IonNiMH/


Hey mem.

I tried to use your code (from your last post) and the error I get is:
error: 'TimeElements' does not name a type In function 'void processSetTime()':

Any suggestions?
Thank you in advance


Jan 12, 2010, 07:03 pm Last Edit: Jan 12, 2010, 07:05 pm by mem Reason: 1

you may be using an early version of the library. You can either change the following in the sketch:
[font=Courier New]  TimeElements te; [/font]
[font=Courier New]  tmElements_t te; [/font]

or try downloading the latest version of the library.


Jan 12, 2010, 11:11 pm Last Edit: Jan 12, 2010, 11:15 pm by dmxspider Reason: 1
Thanks mem! library works great with my arduino clock.

Things that helped me: Simplicity of the new library. The adjust time function (rather than using macro). And the proccessing sketch. I'm sure I'll uncover all the benefits of the library eventually.

This seems simple but.. how does adjustment value work? And how would one derive this number, T1262347200 ,  to equal Jan 1st 2010?

EDIT: Nevermind. It's Unix time. So i just enter the new Unix time into the adjustment function.  

Thanks! ;D :D


mem, thank you. It works now.


Go Up