Mma8452Q 12 Bit Digital Accelerometer
Rs. 77.00 Rs. 95.00
- Brand: https://www.nxp.com/part/MMA8452Q#/
- Product Code: SEN-ACCELEROMETER
- SKU -
- Availability: In Stock
- Price in reward points: 3
- For Bulk Order 9962060070
Quick support on WhatsApp (+919962060070) only between morning 11am-4pm, no call will be answered
- Embedded features with flexible consumer-programmable options, configurable to 2 interrupt pins
- Embedded interrupt functions for average power savings relieving the host processor from constantly polling facts
- Access to both low-bypass filtered statistics as well as high-pass filtered facts, which minimizes the records evaluation required for jolt detection and quicker transitions
- Inertial wake-up interrupt signals from any combination of the configurable embedded capabilities permitting the MMA8451Q to reveal events and stay in a low-electricity mode at some point of periods of state of being inactive.
SPECIFICATION:
-1.95 to 3.6-volt supply voltage
-1.6 to 3.6-volt interface voltage
-±2g/±4g/±8g dynamically selectable full-scale
-Output data rates (ODR) from 1.56 Hz to 800 Hz
-99 μg/√Hz noise
-12-bit and 8-bit digital output
-I²C digital output interface (operates to 2.25 MHz with 4.7 kΩ pull-up)
-Two programmable interrupt pins for six interrupt sources
-Three embedded channels of motion detection
-Freefall or motion detection: one channel
-Pulse detection: one channel
-Jolt detection: one channel
-Orientation (portrait/landscape) detection with set hysteresis
-Automatic ODR change for auto-wake and return to sleep
-High pass filter data available real-time
-Self test
-RoHS compliant
-Current consumption: 6 μA–165 μA
-This product is included in NXP’s product longevity program, with assured supply for a minimum of 10 years after launch
OVERVIEW:
The NXP® MMA8452Q is a low-power, three-axis capacitive micromachined accelerometer with 12 bits of resolution, featuring:
-Embedded functions with flexible user-programmable options, configurable to two interrupt pins
-Embedded interrupt functions for overall power savings relieving the host processor from continuously polling data
-User-selectable full scales of ±2g/±4g/±8g with high-pass filtered data as well as non-filtered data available real-time
-Inertial wake-up interrupt signals from any combination of the configurable embedded functions allowing the MMA8452Q to monitor events and remain in a low-power mode during periods of inactivit
PACKAGE INCLUDES:
1 PCS x Mma8452Q 12 Bit Accelerometer
https://www.nxp.com/part/MMA8452Q#/
//SOURCE CODE TAKEN FROM BELOW LINK
//https://github.com/sparkfun/SparkFun_MMA8452Q_Arduino_Library
/******************************************************************************
MMA8452Q_Basic.ino
SFE_MMA8452Q Library Basic Example Sketch
Jim Lindblom @ SparkFun Electronics
Original Creation Date: June 3, 2014
https://github.com/sparkfun/MMA8452_Accelerometer
This sketch uses the SparkFun_MMA8452Q library to initialize the
accelerometer, and stream values from it.
Hardware hookup:
Arduino --------------- MMA8452Q Breakout
3.3V --------------- 3.3V
GND --------------- GND
SDA (A4) --\/330 Ohm\/-- SDA
SCL (A5) --\/330 Ohm\/-- SCL
The MMA8452Q is a 3.3V max sensor, so you'll need to do some
level-shifting between the Arduino and the breakout. Series
resistors on the SDA and SCL lines should do the trick.
Development environment specifics:
IDE: Arduino 1.0.5
Hardware Platform: Arduino Uno
**Updated for Arduino 1.6.4 5/2015**
This code is beerware; if you see me (or any other SparkFun employee) at the
local, and you've found our code helpful, please buy us a round!
Distributed as-is; no warranty is given.
******************************************************************************/
#include <Wire.h> // Must include Wire library for I2C
#include <SparkFun_MMA8452Q.h> // Includes the SFE_MMA8452Q library
// Begin using the library by creating an instance of the MMA8452Q
// class. We'll call it "accel". That's what we'll reference from
// here on out.
MMA8452Q accel;
// The setup function simply starts serial and initializes the
// accelerometer.
void setup()
{
Serial.begin(9600);
Serial.println("MMA8452Q Test Code!");
// Choose your adventure! There are a few options when it comes
// to initializing the MMA8452Q:
// 1. Default init. This will set the accelerometer up
// with a full-scale range of +/-2g, and an output data rate
// of 800 Hz (fastest).
accel.init();
// 2. Initialize with FULL-SCALE setting. You can set the scale
// using either SCALE_2G, SCALE_4G, or SCALE_8G as the value.
// That'll set the scale to +/-2g, 4g, or 8g respectively.
//accel.init(SCALE_4G); // Uncomment this out if you'd like
// 3. Initialize with FULL-SCALE and DATA RATE setting. If you
// want control over how fast your accelerometer produces
// data use one of the following options in the second param:
// ODR_800, ODR_400, ODR_200, ODR_100, ODR_50, ODR_12,
// ODR_6, or ODR_1.
// Sets to 800, 400, 200, 100, 50, 12.5, 6.25, or 1.56 Hz.
//accel.init(SCALE_8G, ODR_6);
}
// The loop function will simply check for new data from the
// accelerometer and print it out if it's available.
void loop()
{
// Use the accel.available() function to wait for new data
// from the accelerometer.
if (accel.available())
{
// First, use accel.read() to read the new variables:
accel.read();
// accel.read() will update two sets of variables.
// * int's x, y, and z will store the signed 12-bit values
// read out of the accelerometer.
// * floats cx, cy, and cz will store the calculated
// acceleration from those 12-bit values. These variables
// are in units of g's.
// Check the two function declarations below for an example
// of how to use these variables.
printCalculatedAccels();
//printAccels(); // Uncomment to print digital readings
// The library also supports the portrait/landscape detection
// of the MMA8452Q. Check out this function declaration for
// an example of how to use that.
printOrientation();
Serial.println(); // Print new line every time.
}
}
// The function demonstrates how to use the accel.x, accel.y and
// accel.z variables.
// Before using these variables you must call the accel.read()
// function!
void printAccels()
{
Serial.print(accel.x, 3);
Serial.print("\t");
Serial.print(accel.y, 3);
Serial.print("\t");
Serial.print(accel.z, 3);
Serial.print("\t");
}
// This function demonstrates how to use the accel.cx, accel.cy,
// and accel.cz variables.
// Before using these variables you must call the accel.read()
// function!
void printCalculatedAccels()
{
Serial.print(accel.cx, 3);
Serial.print("\t");
Serial.print(accel.cy, 3);
Serial.print("\t");
Serial.print(accel.cz, 3);
Serial.print("\t");
}
// This function demonstrates how to use the accel.readPL()
// function, which reads the portrait/landscape status of the
// sensor.
void printOrientation()
{
// accel.readPL() will return a byte containing information
// about the orientation of the sensor. It will be either
// PORTRAIT_U, PORTRAIT_D, LANDSCAPE_R, LANDSCAPE_L, or
// LOCKOUT.
byte pl = accel.readPL();
switch (pl)
{
case PORTRAIT_U:
Serial.print("Portrait Up");
break;
case PORTRAIT_D:
Serial.print("Portrait Down");
break;
case LANDSCAPE_R:
Serial.print("Landscape Right");
break;
case LANDSCAPE_L:
Serial.print("Landscape Left");
break;
case LOCKOUT:
Serial.print("Flat");
break;
}
}
15 days