Comments (12)
Yes I know, there are 2 problems at this piont.
- The Due has no Backupbatterie so there will no data's stored if he is powerless.
- The Due does reset with the NRSTB pin. This resets the full chip with all backup regions including RTC, RTT and SC. Only if the reset is done with the NRST pin will these regions stay with their old values. And the value what you get then is the startvalue of the register, everytime
from arduino-due-rtc-library.
OK, I thought it was something I was doing wrong in the sketch! Thanks for putting this library together, and I'll look for changes in the future!
from arduino-due-rtc-library.
If I do
rtc_clock.set_clock(0, 0);
then the year is printing as 2070 instead of 1970. I am using Arduino IDE 1.6.4.
from arduino-due-rtc-library.
Did you want to set an unixtime oder date and time from compiler?
Can you post the complete sketch?
from arduino-due-rtc-library.
I want to set unitTime (0). When I start the code, it will check to sync
with time from the internet. If not reachable, I want to to set it as
unitTime 0, which should be the 1970 year, etc.
I doubt that it has something to do with SECONDS_FROM_1970_TO_2000
Bcz if I set the time 946684800, the year shows ok as 2000, but if I set it
as 946684799, the year shows as 2099 instead of 1999.
Avarachan
On Sat, Jun 20, 2015 at 1:08 PM, MarkusLange [email protected]
wrote:
Did you want to set an unixtime oder date and time from compiler?
—
Reply to this email directly or view it on GitHub
#4 (comment)
.
from arduino-due-rtc-library.
Can I get the complete sketch
from arduino-due-rtc-library.
I am playing with one of your example sketches
Due_RTC_Simple_Sample_oneline_time_and_date.ino
https://github.com/MarkusLange/Arduino-Due-RTC-Library/blob/master/examples/Due_RTC_Simple_Sample_oneline_time_and_date/Due_RTC_Simple_Sample_oneline_time_and_date.ino
My tests
void setup() {
Serial.begin(115200);
rtc_clock.init();
//rtc_clock.set_clock(DATE, TIME);
//rtc_clock.set_clock(0,0);
//rtc_clock.set_clock(946684799,0);
rtc_clock.set_clock(946684800,0);
}
Avarachan
On Sat, Jun 20, 2015 at 2:37 PM, MarkusLange [email protected]
wrote:
Can I get the complete sketch
—
Reply to this email directly or view it on GitHub
#4 (comment)
.
from arduino-due-rtc-library.
Ah I understand, yes you are right, I will rewrite it so that so that it works without the define SECONDS_FROM_1970_TO_2000 that it will count the ticks from the 1.01.1970 to the actuall date, so that every date from the start of the unixtime will shown correct.
from arduino-due-rtc-library.
New version up should work for you purpose
from arduino-due-rtc-library.
Downloaded the new lib, and tested (same as my previous post). rtc_clock.set_clock(0,0) still prints 2070.
from arduino-due-rtc-library.
I will take a closer look at the end of the week, may I need to seperate there something with set_clock you can set ntp and unixtime looks like it doesn't work the way I want
from arduino-due-rtc-library.
from arduino-due-rtc-library.
Related Issues (8)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arduino-due-rtc-library.