Component guide · Intermediate · 4 min read
ST LIS2DH12, LIS2DW12

DFRobot Gravity), LIS2DU12, LIS2DE12, LIS2DTW12, IIS2DH, IIS2DLPC, LIS331 and SC7A20 Accelerometers
By Geekobot Learning Team · Updated 29 Oct 2026
On this page
These ST accelerometers are the low-power successors of the LIS3DH, found in trackers, wearables and asset tags. The LIS2DH12 and LIS2DW12 draw a few microamps and wake the system on motion; the IIS parts are industrial grades; the LIS331HH reads up to ±24 g for impacts. The SC7A20 is a compatible low-cost chip. DFRobot's Gravity LIS2DW12 board is ready to plug in.
Key specs at a glance
- Range
- ±2 to ±16 g (LIS331HH up to ±24 g)
- Power
- About 2 to 10 µA in low-power modes
- Interface
- I2C (0x18 or 0x19) or SPI
- Supply
- 1.62 to 3.6 V (chips); Gravity 3.3 or 5 V
- Data rate
- 1 Hz to over 1 kHz
- Features
- Wake on motion, free-fall, tap, 6D orientation, FIFO
Models in this guide
These are alternatives. Pick the one that fits your project; you only need one.
Option 1STMicroelectronics LIS2DH12 3-Axis Digital Accelerometer, ±2/4/8/16g, I²C/SPI, Low Power MEMS Sensor₹134
Option 2STMicroelectronics LIS2DH12TR LGA-12 3-Axis Accelerometer Sensor ROHS₹93
Option 3DFRobot Gravity LIS2DW12 Triple Axis Accelerometer Sensor (±2g/±4g/±8g/±16g) – I2C Interface₹536
Option 4STMicroelectronics LIS2DW12TR LGA-12 3-Axis Accelerometer Sensor ROHS₹207
Option 5STMicroelectronics LIS2DU12TR LGA-12 3-Axis Accelerometer Sensor ROHS₹229
Option 6STMicroelectronics LIS2DE12TR LGA-12 3-Axis Accelerometer Sensor ROHS₹188
What the LIS2DH12, LIS2DW12 and ST low-power accelerometers is
The ST LIS2DH12 and LIS2DW12 are tiny low-power 3-axis accelerometers with I2C and SPI, used in wearables, trackers and wake-on-motion battery devices.
The LIS2DH12 uses the same register map as the LIS3DH, so LIS3DH code usually works. The LIS2DW12 has a different map and needs its own library.
Use the motion interrupt to wake a sleeping ESP32 or nRF52 for trackers and anti-theft alarms.
LIS2DH12, LIS2DW12 and ST low-power accelerometers pinout
The pins on the LIS2DH12, LIS2DW12 and ST low-power accelerometers and what each one does.
| Pin | Function |
|---|---|
| VDD / VDDIO | Supply |
| GND | Ground |
| SCL / SDA | I2C |
| SDO / SA0 | Address select |
| CS | SPI chip select |
| INT1 / INT2 | Interrupts |
- VDD / VDDIO
- Supply
- GND
- Ground
- SCL / SDA
- I2C
- SDO / SA0
- Address select
- CS
- SPI chip select
- INT1 / INT2
- Interrupts
Wiring the LIS2DH12, LIS2DW12 and ST low-power accelerometers
Modules with a regulator run from 3.3 V or 5 V. Bare chips (LGA or QFN parts) are 1.8 to 3.6 V only: mount them on a breakout and use a level shifter with 5 V boards.
| LIS2DH12, LIS2DW12 and ST low-power accelerometers pin | Arduino Uno | ESP32 |
|---|---|---|
| VCC | 5V (or 3.3V) | 3V3 |
| GND | GND | GND |
| SDA | A4 | GPIO 21 |
| SCL | A5 | GPIO 22 |
- VCC
- Arduino Uno:
- 5V (or 3.3V)
- ESP32:
- 3V3
- GND
- Arduino Uno:
- GND
- ESP32:
- GND
- SDA
- Arduino Uno:
- A4
- ESP32:
- GPIO 21
- SCL
- Arduino Uno:
- A5
- ESP32:
- GPIO 22
Example code
For the LIS2DW12 use the DFRobot_LIS or STM32duino LIS2DW12 library; the wiring is the same.
#include <SparkFun_LIS2DH12.h>
SPARKFUN_LIS2DH12 accel;
void setup() {
Serial.begin(115200);
Wire.begin();
while (!accel.begin()) { Serial.println("LIS2DH12 not found"); delay(1000); }
}
void loop() {
Serial.printf("x %.0f y %.0f z %.0f mg\n", accel.getX(), accel.getY(), accel.getZ());
delay(100);
}Setup and tuning
VCC 1.7 to 3.6 V (use 3.3 V), GND, SDA and SCL; breakouts usually add pull-ups.
the SA0 pin sets 0x18 or 0x19 on I2C.
use the SparkFun LIS2DH12 or STM32duino LIS2DW12 library.
pick ±2 g for tilt and ±8 or ±16 g for shocks.
set the motion interrupt so the microcontroller sleeps until the device moves.
What you need
Shop this list14 of 15 found in our store · ₹4,659
STMicroelectronics LIS2DH12 3-Axis Digital Accelerometer, ±2/4/8/16g, I²C/SPI, Low Power MEMS Sensor: the part this guide coversSTMicroelectronics LIS2DH12 3-Axis Digital Accelerometer, ±2/4/8/16g, I²C/SPI, Low Power MEMS Sensor₹134
STMicroelectronics LIS2DH12TR LGA-12 3-Axis Accelerometer Sensor ROHS: another version this guide coversSTMicroelectronics LIS2DH12TR LGA-12 3-Axis Accelerometer Sensor ROHS₹93
DFRobot Gravity LIS2DW12 Triple Axis Accelerometer Sensor (±2g/±4g/±8g/±16g) – I2C Interface: another version this guide coversDFRobot Gravity LIS2DW12 Triple Axis Accelerometer Sensor (±2g/±4g/±8g/±16g) – I2C Interface₹536
STMicroelectronics LIS2DW12TR LGA-12 3-Axis Accelerometer Sensor ROHS: another version this guide coversSTMicroelectronics LIS2DW12TR LGA-12 3-Axis Accelerometer Sensor ROHS₹207
STMicroelectronics LIS2DU12TR LGA-12 3-Axis Accelerometer Sensor ROHS: another version this guide coversSTMicroelectronics LIS2DU12TR LGA-12 3-Axis Accelerometer Sensor ROHS₹229
STMicroelectronics LIS2DE12TR LGA-12 3-Axis Accelerometer Sensor ROHS: another version this guide coversSTMicroelectronics LIS2DE12TR LGA-12 3-Axis Accelerometer Sensor ROHS₹188
STMicroelectronics LIS2DTW12TR MEMS Module, 3-Axis Accelerometer & Temperature Sensor, ±16g, 1.62V to 3.6V, LGA-12: another version this guide coversSTMicroelectronics LIS2DTW12TR MEMS Module, 3-Axis Accelerometer & Temperature Sensor, ±16g, 1.62V to 3.6V, LGA-12₹223
STMicroelectronics IIS2DH 3-Axis Accelerometer Sensor, ±16g, Ultra-Low Power 2µA, 1~5.3kHz ODR, SPI/I²C, LGA-12: another version this guide coversSTMicroelectronics IIS2DH 3-Axis Accelerometer Sensor, ±16g, Ultra-Low Power 2µA, 1~5.3kHz ODR, SPI/I²C, LGA-12₹439
STMicroelectronics IIS2DLPC 3-Axis Accelerometer ±2/4/8/16g Ultra-Low Power – I²C/SPI LGA-12: another version this guide coversSTMicroelectronics IIS2DLPC 3-Axis Accelerometer ±2/4/8/16g Ultra-Low Power – I²C/SPI LGA-12₹158
STMicroelectronics LIS331DLHTR LGA-16 3-Axis Accelerometer Sensor ROHS: another version this guide coversSTMicroelectronics LIS331DLHTR LGA-16 3-Axis Accelerometer Sensor ROHS₹326
STMicroelectronics LIS331HH 3-Axis MEMS Accelerometer, ±6g/±12g/±24g, 16-bit, I2C/SPI, 0.5Hz–1kHz ODR, 2.16–3.6V, LGA16: another version this guide coversSTMicroelectronics LIS331HH 3-Axis MEMS Accelerometer, ±6g/±12g/±24g, 16-bit, I2C/SPI, 0.5Hz–1kHz ODR, 2.16–3.6V, LGA16₹1,529
Silan SC7A20TR LGA-12 3-Axis Accelerometer Sensor ROHS: another version this guide coversSilan SC7A20TR LGA-12 3-Axis Accelerometer Sensor ROHS₹39
ESP32-WROOM-32 38-pin development board: for Wi-Fi logging and dashboardsESP32-WROOM-32 38-Pin Development Board₹389- Uno R3 development board: the controller used in the wiring tableFind this part
GY-521 MPU6050 6-axis module: the classic low-cost IMUGY-521 MPU6050 6-Axis Gyro and Accelerometer Module₹169Closest match, check the specs
Alternatives and when to choose them
- LIS3DH: the older, most documented part.
- Bosch BMA400: ultra-low power alternative.
- ADXL345: popular breakout.
Common mistakes to avoid
- Feeding 5 V to the bare chip.
- Using ±16 g range for small tilt angles.
- Polling all day instead of using the motion interrupt.
- Forgetting the SA0 address setting.
Frequently asked questions
What is the difference between LIS2DH12 and LIS2DW12?
The LIS2DW12 is newer, uses less power and has lower noise; both are 3-axis accelerometers.
Can it wake my ESP32 from deep sleep?
Yes. Route the INT1 pin to a wake-up pin and set the motion threshold.
Why does the sensor not answer on I2C?
Check the address (0x18 or 0x19 from SA0), the pull-ups and the 3.3 V supply.
Can I connect it to a 5 V Arduino?
Only on a breakout with a regulator and level shifting; the chip is a 3.3 V part.
Can it count steps?
Not built in on these two, but you can count peaks in the readings in code.
Parts for this guide
STMicroelectronics LIS2DH12 3-Axis Digital Accelerometer, ±2/4/8/16g, I²C/SPI, Low Power MEMS Sensor₹134View- ₹93View
- ₹536View
- ₹207View
- ₹229View
- ₹188View
STMicroelectronics LIS2DTW12TR MEMS Module, 3-Axis Accelerometer & Temperature Sensor, ±16g, 1.62V to 3.6V, LGA-12₹223View
STMicroelectronics IIS2DH 3-Axis Accelerometer Sensor, ±16g, Ultra-Low Power 2µA, 1~5.3kHz ODR, SPI/I²C, LGA-12₹439View- ₹158View
- ₹326View
STMicroelectronics LIS331HH 3-Axis MEMS Accelerometer, ±6g/±12g/±24g, 16-bit, I2C/SPI, 0.5Hz–1kHz ODR, 2.16–3.6V, LGA16₹1,529View- ₹39View
- ₹389View
- ₹359View
- ₹169View
Keep learning
Sources
Written by the Geekobot team from manufacturer datasheets. Always check the datasheet for the exact part and variant you buy.

