You're defining cTime as a char array and expect it to behave like a clock? Treat your child as a refrigerator and I'm sure you'll find he's lousy at keeping your beer cool.
If you are getting compile time errors then the problem may be in the DateStrings.cpp. If so either download an up to date copy of the library or a fixed DateStrings.cpp from here.
It may also be useful to tell us what the actual problem is rather than keeping us guessing and when it is fixed let us know.
Compiling 'PIR' for 'IntelĀ® Edison'
Build folder: file:///C:/Users/Terrence/AppData/Local/VMicro/Arduino/Builds/PIR/izmir_ec
fcntl.h:In file included from
fast_gpio_common.c:from
stat.h:91:21: error: field 'st_atim' has incomplete type
:struct timespec st_atim; * Time of last access. *
:^
stat.h:92:21: error: field 'st_mtim' has incomplete type
:struct timespec st_mtim; * Time of last modification. *
:^
stat.h:93:21: error: field 'st_ctim' has incomplete type
:struct timespec st_ctim; * Time of last status change. *
:^
fcntl.h:In file included from
variant.cpp:from
stat.h:91:21: error: field 'st_atim' has incomplete type
:struct timespec st_atim; * Time of last access. *
:^
stat.h:92:21: error: field 'st_mtim' has incomplete type
:struct timespec st_mtim; * Time of last modification. *
:^
stat.h:93:21: error: field 'st_ctim' has incomplete type
:struct timespec st_ctim; * Time of last status change. *
:^
stat.h:152:21: error: field 'st_atim' has incomplete type
:struct timespec st_atim; * Time of last access. *
:^
stat.h:153:21: error: field 'st_mtim' has incomplete type
:struct timespec st_mtim; * Time of last modification. *
:^
stat.h:154:21: error: field 'st_ctim' has incomplete type
:struct timespec st_ctim; * Time of last status change. *
:^
Error compiling core
You're defining cTime as a char array and expect it to behave like a clock?
What would you suggest instead of a char array? I don't want a clock, I am just formatting the datetime so I can store it in Azure Tablestorage.
Treat your child as a refrigerator and I'm sure you'll find he's lousy at keeping your beer cool.
I do not like warm beer. Please help me avoid that situation.
Do yourself a favor. Get an RTC
Turns out my Intel Edison board has a RTC, but no coin battery to keep it up to date. When the board boots up it NTPs and gets the time from a server.
This doesn't help you much, but that code compiles fine with an Uno selected as the target.
I suspect therefore that you have some issue with your install - what version supports the Edison?
As an aside, note that it's a bad idea to use serial.print in an interrupt. Set a volatile flag in the interrupt and move the serial prints to loop, controlled by the flag.