I am working with an Arduino Due and the Analog ADXL345 through a module following this tutorial, with the wire.h library at Fast Speed (400kHz), the Accelerometer Sampling at 800Hz (for the Maximum Reccomended Limit), and the Serial Monitor at 115200 bps.

The cable is 24AWG solid wire, 6in length, two pairs, for 3.3V, GND, SCL and SDA pins.

When the accelerometer is starting up, it generates a high pitched noise is generated!. Possibly by the 5V-3.3V regulator or by the accelerometer itself.

Under 400kHz|800Hz, the readings are unstable: by simply touching some open terminals in the Due, the Accelerometers readings toggle between strong oscillations and the correct ones (Figure 1).

enter image description here After some "taps", the oscillations stops and the proper measures can be captured at the expected sampling rate (Figure 2). Note the mean values are modified for plotting only.

enter image description here

What should I do to prevent such behavior?, and what is causing that, considering the device is indeed working at the expected speed?

  • Please add the wiring of the module and information about cable length, type, etc. The wires should be as short as possible and there should be common ground. Commented Jul 29, 2019 at 9:11
  • I edited the question with the tutorial followed, 15cm length cable, 24 AWG solid wire.
    – Brethlosze
    Commented Jul 29, 2019 at 16:12


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.