Skip to content

Commit 6e94aae

Browse files
committed
2 parents fd1bea9 + 8c42495 commit 6e94aae

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

DallasTemperature.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -528,7 +528,7 @@ int16_t DallasTemperature::calculateTemperature(const uint8_t* deviceAddress,
528528
*/
529529

530530
if (deviceAddress[0] == DS18S20MODEL) {
531-
fpTemperature = ((fpTemperature & 0xfff0) << 3) - 16
531+
fpTemperature = ((fpTemperature & 0xfff0) << 3) - 32
532532
+ (((scratchPad[COUNT_PER_C] - scratchPad[COUNT_REMAIN]) << 7)
533533
/ scratchPad[COUNT_PER_C]);
534534
}

library.properties

+1
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ paragraph=Supports DS18B20, DS18S20, DS1822, DS1820
77
category=Sensors
88
url=https://github.com/milesburton/Arduino-Temperature-Control-Library
99
architectures=*
10+
depends=OneWire

0 commit comments

Comments
 (0)