J M / MCP9808
Revision:
2:4f8e1fb852d3
Parent:
1:7e98ef2bd303
--- a/MCP9808.hpp	Mon Jan 09 17:57:58 2017 +0000
+++ b/MCP9808.hpp	Fri Jan 20 19:48:45 2017 +0000
@@ -56,6 +56,14 @@
         MCP9808_CFG_FLAG_SHDN_ENABLED =        (1 << 8),
     };
 
+    /** Manufacturer ID from MCP9808_REG_MFG_ID register
+     */
+    static const uint16_t MCP9808_MFG_ID = 0x0054;
+
+    /** Device ID from MCP9808_REG_DEV_ID register
+     */
+    static const uint16_t MCP9808_DEV_ID = 0x0400;
+
     /** Create an MCP9808 using the specified pins for I2C and specified I2C
      *  address
      *
@@ -67,6 +75,12 @@
 
     virtual ~MCP9808();
 
+    /** Detects the sensor's presence
+     *
+     * @returns true if sensor is detected
+     */
+    bool is_detected();
+
     /** Puts the sensor into (low-power) shutdown mode
      *
      *  @returns 0 on success, negative on error