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
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
skipper,
you may be using an early version of the library. You can either change the following in the sketch:
TimeElements te;
to
tmElements_t te;
or try downloading the latest version of the library.
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
mem, thank you. It works now.
Cheers
Skipper, good to hear you have it working.
Catcher, adjustment works by offsetting the time by the given number of seconds. For example, adjustTime(-3600) ; sets the clock back 1 hour.
mem ,
The Sw i tried using didnt work for me ( I sent you PM with the problem)
But I manged to get the uFAT runing and reading from my SD!!!
cool
But write doesn't work .. tried two SDs - they are not write protected .. but I cant write to them (only read the stuff I wrote in the file on windows)
any help ? :-[(no errors...)
moriszen, It sounds like the problem relates to the interface to the SD card rather than something to do with the Time Library. I would like to keep this thread focused on issues relating to the Time library.
Perhaps you can start another thread for a discussion on getting your SD card going.
Hey mem,
Just wanted to thank you for writing this library. I was just sitting down to solve this problem and your library pretty much nailed everything I needed.
It works great.
J
Is there an example somewhere of this library running an alarmed event?
Is there an example somewhere of this library running an alarmed event?
There is an example in the TimeAlarms directory in the current download.
See this thread for more details: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1263305457
Ahh, thank you!
I guess I had an older version of Time that didn't have TimeAlarms?
I guess I had an older version of Time that didn't have TimeAlarms?
Yes, the TimeAlarms library was only added recently. Perhaps you can report how you get on with the alarms library in the thread linked above.
Hello !
Is it possibe to run the Time-lib with the NPT Internet Time Sync together with a webserver (e.g. Ben Combees Webduino) ?
I didn't tried it already, but maybe there is somebody who have experiences.
Ollie.
I haven't tried it but would expect you could add the relevant code from the NTP example sketch in the download into Bens webduino library.
Bear in mind that NTP uses the UDP protocol so you would need to add the third party UDP library as documented in the NTP example.
If you want to try this, I suggest you get the NTP example sketch running on its own and then consider how you would want to integrate this into webduino.
I would be interested to follow your progress, perhaps create a new thread to cover this specific topic.
I guess I had an older version of Time that didn't have TimeAlarms?
Yes, the TimeAlarms library was only added recently. Perhaps you can report how you get on with the alarms library in the thread linked above.
It was a joy to use!!
your example was simple & thorough enough for me to understand how to use it.
The only confusion I had was timerRepeat is only in seconds and not
formatted like alarmRepeat but it did not take long to figure out time time * 60 to get minutes.
thank you for such a wonderful & versatile library!
Glasshopper, good to hear you found the library useful
? timerRepeat is only in seconds and not formatted like alarmRepeat ?
You should be able to set timers just like alarms, did you try something like : Alarm.timerRepeat( 1,30,0, TimerTask); // set timer to repeat every 1 hour and 30 minutes
I have created a Visual Basic application based on the code from Moriszen.
Here is the link: http://www.megaupload.com/?d=1A76PJ5F
Nice to see you got it posted .
Does anyone know if the time library will work in idle - low power mode .
I want to have an application that wakes up once or twice a day an logs the time and date (running on batteries) .
any suggestions ?
The time library relies on the Arduino millis timer which services an interrupt every millisecond. This means it will not work in low power mode.
For an application that needs to wake up once or twice a day you would probably need to use a low power Real Time Clock that generated an interrupt that would wake up the Arduino when it needed to log something. Have a look in the playground to see if anyone has published an RTC application that does something like this.
? timerRepeat is only in seconds and not formatted like alarmRepeat ?
You should be able to set timers just like alarms, did you try something like : Alarm.timerRepeat( 1,30,0, TimerTask); // set timer to repeat every 1 hour and 30 minutes
I see..
Alarm.timerRepeat(1, 0, Repeats);
does not work
but
Alarm.timerRepeat( 0, 1, 0, Repeats);
does.
thank you