Using an MMA7455 accelerometer with an ESP32 board

The MMA7455L is a Digital Output (I2C/SPI), low power, low profile capacitive micromachined accelerometer featuring signal conditioning, a low pass filter, temperature compensation, self-test, configurable to detect 0g through interrupt pins (INT1 or INT2), and pulse detect for quick motion detection. 0g offset and sensitivity are factory set and require no external devices. The 0g offset can be customer calibrated using assigned 0g registers and g-Select which allows for command selection for 3 acceleration ranges (2g/4g/8g). The MMA7455L includes a Standby Mode that makes it ideal for handheld battery powered electronics.

Using an MMA7455 accelerometer with an ESP32 board


• Digital Output (I2C/SPI)
• 3mm x 5mm x 1mm LGA-14 Package
• Self-Test for Z-Axis
• Low Voltage Operation: 2.4 V – 3.6 V
• User Assigned Registers for Offset Calibration
• Programmable Threshold Interrupt Output
• Level Detection for Motion Recognition (Shock, Vibration, Freefall)
• Pulse Detection for Single or Double Pulse Recognition
• Sensitivity (64 LSB/g @ 2g and @ 8g in 10-Bit Mode)
• Selectable Sensitivity (±2g, ±4g, ±8g) for 8-bit Mode
• Robust Design, High Shocks Survivability (5,000g)
• RoHS Compliant
• Environmentally Preferred Product
• Low Cost

Typical Applications

• Cell Phone/PMP/PDA: Image Stability, Text Scroll, Motion Dialing, Tap to Mute
• HDD: Freefall Detection
• Laptop PC: Freefall Detection, Anti-Theft
• Pedometer
• Motion Sensing, Event Recorder

Here is a picture of a typical module

Here is how to wire the MMA7455 accelerometer to your ESP32 device


Module LOLIN 32
VDD 3v3
Gnd Gnd
SDA SDA – 21
SCL SCL – 22


You will need to grab a copy of the library. Download and copy to your Arduino -> Libraries folder

This is one of the test examples


Open the serial monitor window and you should see something like this

Read more: Using an MMA7455 accelerometer with an ESP32 board

About The Author

Scroll to Top
Read previous post:

[Will] wanted to build some animatronic eyes that didn’t require high-precision 3D printing. He wound up with a forgiving design that uses...