1-Wire® library for mbed. Complete 1-Wire library that supports our silicon masters along with a bit-bang master on the MAX32600MBED platform with one common interface for mbed. Slave support has also been included and more slaves will be added as time permits.

Dependents:   MAXREFDES131_Qt_Demo MAX32630FTHR_iButton_uSD_Logger MAX32630FTHR_DS18B20_uSD_Logger MAXREFDES130_131_Demo ... more

Superseded by MaximInterface.

Revision:
141:cf38f48a2a49
Parent:
139:f0e0a7976846
--- a/Masters/OneWireMaster.cpp	Fri Feb 17 19:09:11 2017 +0000
+++ b/Masters/OneWireMaster.cpp	Fri Feb 17 21:54:14 2017 +0000
@@ -34,11 +34,11 @@
 
 namespace OneWire
 {
-    OneWireMaster::CmdResult OneWireMaster::OWWriteBlock(const uint8_t *sendBuf, uint8_t sendLen)
+    OneWireMaster::CmdResult OneWireMaster::OWWriteBlock(const uint8_t *sendBuf, size_t sendLen)
     {
         CmdResult result = OperationFailure;
 
-        for (uint8_t idx = 0; idx < sendLen; idx++)
+        for (size_t idx = 0; idx < sendLen; idx++)
         {
             result = OWWriteByte(sendBuf[idx]);
             if (result != Success)
@@ -50,11 +50,11 @@
         return result;
     }
 
-    OneWireMaster::CmdResult OneWireMaster::OWReadBlock(uint8_t *recvBuf, uint8_t recvLen)
+    OneWireMaster::CmdResult OneWireMaster::OWReadBlock(uint8_t *recvBuf, size_t recvLen)
     {
         CmdResult result = OperationFailure;
 
-        for (uint8_t idx = 0; idx < recvLen; idx++)
+        for (size_t idx = 0; idx < recvLen; idx++)
         {
             result = OWReadByte(recvBuf[idx]);
             if (result != Success)