Fork of original library to fix mbed 5 deprecation warnings

Dependencies:   LPC1114_WakeInterruptIn

Dependents:   low-power-sleep

Fork of WakeUp by Erik -

Revision:
23:884e86933aaa
Parent:
19:9d355da2770e
--- a/Device/WakeUp_Freescale.cpp	Wed Nov 11 20:20:27 2015 +0000
+++ b/Device/WakeUp_Freescale.cpp	Mon Apr 10 13:05:23 2017 +0000
@@ -3,7 +3,7 @@
 #include "WakeUp.h"
 #include "us_ticker_api.h"
 
-FunctionPointer WakeUp::callback;
+Callback<void()> WakeUp::cbk;
 float WakeUp::cycles_per_ms = 1.0;
 
 static uint16_t remainder_count;
@@ -90,7 +90,9 @@
     // write 1 to TCF to clear the LPT timer compare flag
     LPTMR0->CSR |= LPTMR_CSR_TCF_MASK;
     restore();
-    callback.call();
+    if (cbk) {
+        cbk.call();
+    }
 }
 
 void WakeUp::calibrate(void)