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 5968796 commit 415e9a7Copy full SHA for 415e9a7
src/SparkFun_ADS1219.cpp
@@ -135,7 +135,7 @@ bool SfeADS1219Driver::readConversion()
135
iu32.u32 = (iu32.u32 << 8) | rawBytes[1];
136
iu32.u32 = (iu32.u32 << 8) | rawBytes[2];
137
// Preserve the 2's complement.
138
- if (0x00100000 == (iu32.u32 & 0x00100000))
+ if (0x00800000 == (iu32.u32 & 0x00800000))
139
iu32.u32 = iu32.u32 | 0xFF000000;
140
_adcResult = iu32.i32; // Store the signed result
141
}
0 commit comments