WISP ERT (Client)
1.0.0
The WISP Extended Runtime (WISP side)
|
#include "accel.h"
#include "accel_registers.h"
#include "../globals.h"
#include "../Timing/timer.h"
#include "../wired/spi.h"
Functions | |
BOOL | ACCEL_reset () |
BOOL | ACCEL_range () |
BOOL | ACCEL_initialize () |
BOOL | ACCEL_initialize_withoutWait () |
void | ACCEL_standby () |
BOOL | ACCEL_singleSample_FIFO (threeAxis_t_8 *result) |
BOOL | ACCEL_singleSample (threeAxis_t_8 *result) |
BOOL | ACCEL_readStat (threeAxis_t_8 *result) |
BOOL | ACCEL_readID (threeAxis_t_8 *result) |
BOOL ACCEL_initialize | ( | ) |
BOOL ACCEL_initialize_withoutWait | ( | ) |
BOOL ACCEL_range | ( | ) |
BOOL ACCEL_readID | ( | threeAxis_t_8 * | result | ) |
BOOL ACCEL_readStat | ( | threeAxis_t_8 * | result | ) |
BOOL ACCEL_reset | ( | ) |
Turn on and start up the ADXL362 accelerometer. This leaves the ADXL running.
BOOL ACCEL_singleSample | ( | threeAxis_t_8 * | result | ) |
BOOL ACCEL_singleSample_FIFO | ( | threeAxis_t_8 * | result | ) |
Grab one sample from the ADXL362 accelerometer
void ACCEL_standby | ( | ) |
Put the ADXL362 into a lower power standby state without gating power
uint8_t const ADXL_CONFIG_FIFO_CTL[] = {ADXL_CMD_WRITE_REG,ADXL_REG_FIFO_CONTROL,0X0A} |
uint8_t const ADXL_CONFIG_FIFO_SAMPLE[] = {ADXL_CMD_WRITE_REG,ADXL_REG_FIFO_SAMPLES,6} |
uint8_t const ADXL_CONFIG_FILTER[] = {ADXL_CMD_WRITE_REG,ADXL_REG_FILTER_CTL,0x14} |
uint8_t const ADXL_CONFIG_INTERRUPT[] = {ADXL_CMD_WRITE_REG,ADXL_REG_INTMAP1,0X01} |
uint8_t const ADXL_CONFIG_MEAS[] = {ADXL_CMD_WRITE_REG,ADXL_REG_POWER_CTL,0x22} |
uint8_t const ADXL_CONFIG_RESET[] = {ADXL_CMD_WRITE_REG,ADXL_REG_SOFT_RESET,0x52} |
uint8_t const ADXL_CONFIG_STBY[] = {ADXL_CMD_WRITE_REG,ADXL_REG_POWER_CTL,0x00} |
uint8_t const ADXL_READ_DEVID[] = {ADXL_CMD_READ_REG,ADXL_REG_DEVID_AD,0x00} |
uint8_t const ADXL_READ_PARTID[] = {ADXL_CMD_READ_REG,ADXL_REG_PARTID,0x00} |
Driver for the ADXL362 accelerometer
uint8_t const ADXL_READ_XYZ_16BIT[] = {ADXL_CMD_READ_REG,ADXL_REG_XDATA_L,0x00,0x00,0x00,0x00,0x00,0x00} |
uint8_t const ADXL_READ_XYZ_16BIT_FIFO[] = {ADXL_CMD_READ_FIFO,0x00,0x00,0x00,0x00,0x00,0x00} |
uint8_t const ADXL_READ_XYZ_8BIT[] = {ADXL_CMD_READ_REG,ADXL_REG_XDATA,0x00,0x00,0x00} |
uint8_t const ADXL_REAsxD_STATUS[] = {ADXL_CMD_READ_REG,ADXL_REG_STATUS,0x00} |