Adafruit ADXL343 Library
|
#include "WProgram.h"
#include <Adafruit_BusIO_Register.h>
#include <Adafruit_I2CDevice.h>
#include <Adafruit_SPIDevice.h>
#include <Adafruit_Sensor.h>
#include <Wire.h>
Go to the source code of this file.
Classes | |
union | int_config |
class | Adafruit_ADXL343 |
BSD license (see license.txt)
This is a library for the Adafruit ADS1015 breakout board -—> https://www.adafruit.com/products/???
Adafruit invests time and resources providing this open source code, please support Adafruit and open-source hardware by purchasing products from Adafruit!
v1.0 - First release
#define ADXL343_ADDRESS (0x53) |
Assumes ALT address pin low
#define ADXL3XX_REG_DEVID (0x00) |
Device ID
#define ADXL3XX_REG_THRESH_TAP (0x1D) |
Tap threshold
#define ADXL3XX_REG_OFSX (0x1E) |
X-axis offset
#define ADXL3XX_REG_OFSY (0x1F) |
Y-axis offset
#define ADXL3XX_REG_OFSZ (0x20) |
Z-axis offset
#define ADXL3XX_REG_DUR (0x21) |
Tap duration
#define ADXL3XX_REG_LATENT (0x22) |
Tap latency
#define ADXL3XX_REG_WINDOW (0x23) |
Tap window
#define ADXL3XX_REG_THRESH_ACT (0x24) |
Activity threshold
#define ADXL3XX_REG_THRESH_INACT (0x25) |
Inactivity threshold
#define ADXL3XX_REG_TIME_INACT (0x26) |
Inactivity time
#define ADXL3XX_REG_ACT_INACT_CTL (0x27) |
Axis enable control for activity and inactivity detection
#define ADXL3XX_REG_THRESH_FF (0x28) |
Free-fall threshold
#define ADXL3XX_REG_TIME_FF (0x29) |
Free-fall time
#define ADXL3XX_REG_TAP_AXES (0x2A) |
Axis control for single/double tap
#define ADXL3XX_REG_ACT_TAP_STATUS (0x2B) |
Source for single/double tap
#define ADXL3XX_REG_BW_RATE (0x2C) |
Data rate and power mode control
#define ADXL3XX_REG_POWER_CTL (0x2D) |
Power-saving features control
#define ADXL3XX_REG_INT_ENABLE (0x2E) |
Interrupt enable control
#define ADXL3XX_REG_INT_MAP (0x2F) |
Interrupt mapping control
#define ADXL3XX_REG_INT_SOURCE (0x30) |
Source of interrupts
#define ADXL3XX_REG_DATA_FORMAT (0x31) |
Data format control
#define ADXL3XX_REG_DATAX0 (0x32) |
X-axis data 0
#define ADXL3XX_REG_DATAX1 (0x33) |
X-axis data 1
#define ADXL3XX_REG_DATAY0 (0x34) |
Y-axis data 0
#define ADXL3XX_REG_DATAY1 (0x35) |
Y-axis data 1
#define ADXL3XX_REG_DATAZ0 (0x36) |
Z-axis data 0
#define ADXL3XX_REG_DATAZ1 (0x37) |
Z-axis data 1
#define ADXL3XX_REG_FIFO_CTL (0x38) |
FIFO control
#define ADXL3XX_REG_FIFO_STATUS (0x39) |
FIFO status
#define ADXL343_MG2G_MULTIPLIER (0.004) |
4mg per lsb
enum adxl3xx_dataRate_t |
Used with register 0x2C (ADXL3XX_REG_BW_RATE) to set bandwidth
enum adxl34x_range_t |
Used with register 0x31 (ADXL3XX_REG_DATA_FORMAT) to set g range
enum adxl3xx_int_pin |
Possible interrupt pin outputs on the ADXL343.