i was trying to get timestamp using Time.now(). while time interval is running with Timealarms library, i am getting an error
lib/TimeAlarms/TimeAlarms.h:14:15: expected unqualified-id before ‘(’ token
there is nothing in 14th line.
i was trying to get timestamp using Time.now(). while time interval is running with Timealarms library, i am getting an error
lib/TimeAlarms/TimeAlarms.h:14:15: expected unqualified-id before ‘(’ token
there is nothing in 14th line.
It could be and often is up a little higher above the 14th line in your code where you will find the problem.
If it’s bailing in the .h file, look at where it’s included in the source and look for problems above that.
This seems to either come from targeting an old system version or using a version of the library that’s targeted at one.
it was not a problem in the code. i was getting error only when i add Time.now()
i used Time.local() and it worked
There is a macro definition problem in that ported library. In your code where you include the TimeAlarms library, right after that you need to undefined the problem:
#include "TimeAlarms.h"
#undef now()
adding #undef now()
under all the header files solved the problem.
thank you