sparkfun / SparkFun_ADXL345_Arduino_Library

Arduino Library for the ADXL345
46 stars 52 forks source link

Negative values not working? #14

Open BorisBrock opened 5 years ago

BorisBrock commented 5 years ago

When reading the values via readAccel(int x, int y, int* z), three integers are returned. But their values are never negative. Instead small negative values become huge positive numbers (e.g. 65540).

Is that supposed to happen? Am I using it wrong?

PS: I used your example code, unmodified. I compiled with PlatformIO and ran it on a SparkFun ESP32Thing.