Implementation of 1-Wire with added Alarm Search Functionality

Dependents:   Max32630_One_Wire_Interface

Revision:
57:1635f247ceae
Parent:
48:6f9208ae280e
Child:
71:562f5c702094
--- a/OneWire_Masters/OneWireMaster.cpp	Tue Apr 12 10:51:20 2016 -0500
+++ b/OneWire_Masters/OneWireMaster.cpp	Wed Apr 13 18:52:34 2016 -0500
@@ -375,9 +375,9 @@
         result = OWReadBit(tsb);
     if (result == Success)
     {
-        if (sbr == 1)
+        if (sbr)
             search_direction = DIRECTION_WRITE_ONE;
-        else if ((sbr == 0) && (tsb == 1))
+        else if (tsb)
             search_direction = DIRECTION_WRITE_ZERO;
         // else: use search_direction parameter