Components / Sensors / ADXL345 accelerometer

ADXL345 accelerometer

3-axis accelerometer with tap and free-fall detection.

MeasuresAcceleration on 3 axes
Range±2, ±4, ±8 or ±16 g
InterfaceI2C or SPI
I2C address0x53 or 0x1D
SensorsReviewedMPN ADXL345Used in 18 projects
4.98V
In short

What is the ADXL345 accelerometer and what is it used for?

3-axis accelerometer with tap and free-fall detection. Makers use it for tilt sensing, step counters.

How it works

A micro-machined mass on springs moves with acceleration, and the change in capacitance between fingers is measured.

Key specifications

Sensor specValue
MeasuresAcceleration on 3 axes
Range±2, ±4, ±8 or ±16 g
InterfaceI2C or SPI
I2C address0x53 or 0x1D
Supply voltage2 to 3.6 V

Pinout

GNDGround
VCC3.3 V (modules often accept 5 V)
CSChip select, high for I2C
INT1 and INT2Interrupts for taps, free fall and activity
SDOAddress 0x53 (low) or 0x1D (high)
SDAI2C data or SPI
SCLI2C clock or SPI clock

How to use it

Use the Adafruit ADXL345 library and pick the smallest range that fits your motion for the best resolution. The built-in tap and free-fall detection can wake a sleeping microcontroller through INT1.

Applications

Alternatives

Buy at

Common questions

What is the ADXL345 accelerometer used for?

In maker projects: tilt sensing, step counters.

How does the ADXL345 accelerometer work?

A micro-machined mass on springs moves with acceleration, and the change in capacitance between fingers is measured.

What voltage does the ADXL345 accelerometer need?

2 to 3.6 V.

How do I connect the ADXL345 accelerometer to an Arduino or ESP32?

I2C or SPI. Pins: GND (Ground), VCC (3.3 V (modules often accept 5 V)), CS (Chip select, high for I2C), INT1 and INT2 (Interrupts for taps, free fall and activity), SDO (Address 0x53 (low) or 0x1D (high)), SDA (I2C data or SPI).

What can I use instead of the ADXL345 accelerometer?

MPU6050 IMU and LIS3DH accelerometer.