Dallas DS18B20 OneWire sensor library

Dependencies:   LinkedList

Dependents:   B-SMART_V15_release

Fork of DS1820 by Erik -

Files at this revision

API Documentation at this revision

Comitter:
SomeRandomBloke
Date:
Sun Jan 10 22:35:20 2016 +0000
Parent:
13:51a5011dc0ad
Commit message:
Updates to expose address

Changed in this revision

DS1820.cpp Show annotated file Show diff for this revision Revisions of this file
DS1820.h Show annotated file Show diff for this revision Revisions of this file
diff -r 51a5011dc0ad -r 4760669f5f5e DS1820.cpp
--- a/DS1820.cpp	Mon Mar 09 20:41:08 2015 +0000
+++ b/DS1820.cpp	Sun Jan 10 22:35:20 2016 +0000
@@ -31,6 +31,10 @@
     }
 }
 
+char *DS1820::getAddress() {
+    return _ROM;
+}
+
  
 bool DS1820::onewire_reset(DigitalInOut *pin) {
 // This will return false if no devices are present on the data bus
diff -r 51a5011dc0ad -r 4760669f5f5e DS1820.h
--- a/DS1820.h	Mon Mar 09 20:41:08 2015 +0000
+++ b/DS1820.h	Sun Jan 10 22:35:20 2016 +0000
@@ -105,8 +105,11 @@
       * @param a number between 9 and 12 to specify resolution
       * @returns true if successful
       */ 
-    bool setResolution(unsigned int resolution);       
-
+    bool setResolution(unsigned int resolution);
+    
+    char *getAddress();
+    
+    static LinkedList<node> probes;
 private:
     bool _parasite_power;
     bool _power_mosfet;
@@ -134,7 +137,7 @@
     char _ROM[8];
     char RAM[9];
     
-    static LinkedList<node> probes;
+//    static LinkedList<node> probes;
 };