We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5bc0a5c commit ce3190fCopy full SHA for ce3190f
DHT.cpp
@@ -194,11 +194,11 @@ boolean DHT::read(bool force) {
194
_lastresult = false;
195
return _lastresult;
196
}
197
- data[i * 0.125] <<= 1;
+ data[i/8] <<= 1;
198
// Now compare the low and high cycle times to see if the bit is a 0 or 1.
199
if (highCycles > lowCycles) {
200
// High cycles are greater than 50us low cycle count, must be a 1.
201
- data[i * 0.125] |= 1;
+ data[i/8] |= 1;
202
203
// Else high cycles are less than (or equal to, a weird case) the 50us low
204
// cycle count so this must be a zero. Nothing needs to be changed in the
0 commit comments