Dallas' DS1820 family temperature sensor using mbed debug logs.
Fork of DS1820 by
Diff: DS1820.cpp
- Revision:
- 16:0764e4de41d2
- Parent:
- 15:8b82d53770df
--- a/DS1820.cpp Sat Apr 28 19:26:09 2018 +0300 +++ b/DS1820.cpp Mon Apr 30 14:40:29 2018 +0300 @@ -193,7 +193,7 @@ */ uint8_t DS1820::read(float &temp) { uint16_t temp_uint16 = 0; - uint8_t result = read_uint16(temp_uint16); + uint8_t result = readRaw(temp_uint16); bool temp_available = 0 == result; if (temp_available) { @@ -215,7 +215,7 @@ * 1 - sensor not present ('temp' is not updated) * 2 - CRC error ('temp' is not updated) */ -uint8_t DS1820::read_uint16(uint16_t &temp) { +uint8_t DS1820::readRaw(uint16_t &temp) { if (present) { oneWire.reset(); oneWire.skip();