From 3d62ec51d2952518985cf28af40e6346f1d0cf3f Mon Sep 17 00:00:00 2001 From: Stanley Huang Date: Wed, 29 Oct 2014 23:35:05 +1100 Subject: fix compilation issue with Arduino DUE --- megalogger/Narcoleptic.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'megalogger') diff --git a/megalogger/Narcoleptic.cpp b/megalogger/Narcoleptic.cpp index 5da3924..61fb13c 100644 --- a/megalogger/Narcoleptic.cpp +++ b/megalogger/Narcoleptic.cpp @@ -16,6 +16,10 @@ * along with this program. If not, see . */ +#include "Narcoleptic.h" + +#ifndef __SAM3X8E__ + #include #include #include @@ -23,7 +27,6 @@ #include #include -#include "Narcoleptic.h" SIGNAL(WDT_vect) { wdt_disable(); @@ -54,4 +57,12 @@ void NarcolepticClass::delay(int milliseconds) { if (milliseconds >= 16) { sleep(WDTO_15MS); milliseconds -= 15; } } +#else + +void NarcolepticClass::delay(int milliseconds) { + delay(milliseconds); +} + +#endif + NarcolepticClass Narcoleptic; -- cgit v1.2.3