Closed puregame closed 3 years ago
Looks like TimeLib.h messes up std::chrono
, the standard time facility of c++ 11. If you replace #include "TeensyTimerTool.h"
by #include <chrono>
, you'll get the same issue. This of course is a pity, but I can't do much about it.
Two workarounds:
std::chrono
in the TeensyTimerTool config. See here: https://github.com/luni64/TeensyTimerTool/blob/77c116db1dc29077325b03f9a81684da45b72855/src/defaultConfig.h#L80This will of course disable the use of the time literals, i.e. you can't do things like trigger(25ms)
anymore. (https://github.com/luni64/TeensyTimerTool/wiki/Configuration)Time.h
from the TimeLib library folder. It is just relaying calls to Time.h
to TimeLib.h
which generates the problem. (The c++ std libraries want to call time.h and get redirected to TimeLib which of course can't work.)That worked, I had tried removing Time.h
from the folder but that alone did not work. I also renamed Time.cpp
to TimeLib.cpp
. All code still compiles and works as intended.
Thank you!
Confirmed: in the Time library, delete Time.h and rename Time.cpp to TimeLib.cpp
I'm playing around with a T4.1 and I want to use the TeensyTimerTool in a project that also will be using the RTC functionality.
I've narrowed down an issue to when both and "TeensyTimerTool.h" are both #included in the project. I tested this with an empty project and get compile issues. Any help on how to get past these compile issues would be great. I can't find anything similar on google.