Tomonori Kuroki / MuWatchdog

Fork of Watchdog by David Smart

Revision:
15:e0e4c2268558
Parent:
11:a1611543c454
Child:
16:de80257a1ed0
--- a/Watchdog.h	Fri Feb 03 04:53:54 2017 +0000
+++ b/Watchdog.h	Fri Feb 23 13:41:54 2018 +0000
@@ -103,12 +103,18 @@
     ///
     /// @returns true if the Watchdog was the cause of the reset
     bool WatchdogCausedReset();
+
+#if defined( TARGET_STM )
+    uint32_t reset_status() { return _rcc_csr; }
+#endif
 private:
-    bool wdreset;
-    
-    #if defined( TARGET_STM )
+    bool _wdreset;
+
+#if defined( TARGET_STM )
+    uint32_t _rcc_csr;        // RCC clock control & status register
+
     int calcExponent16bit(uint16_t v);  // 整数Xを含む最小のべき乗指数
-    #endif
+#endif
 };
 
 #endif // WATCHDOG_H