Contiki-NG
|
Driver for the Sensortag Invensense MPU9250 motion processing unit. More...
#include "contiki.h"
#include "lib/sensors.h"
#include "sys/rtimer.h"
#include "board-conf.h"
#include "mpu-9250-sensor.h"
#include <Board.h>
#include <ti/devices/DeviceFamily.h>
#include <DeviceFamily_constructPath(driverlib/cpu.h)>
#include <ti/drivers/PIN.h>
#include <ti/drivers/I2C.h>
#include <stdint.h>
#include <string.h>
#include <stdio.h>
#include <math.h>
Go to the source code of this file.
Functions | |
static bool | i2c_write_read (void *wbuf, size_t wcount, void *rbuf, size_t rcount) |
Setup and peform an I2C transaction. More... | |
static bool | i2c_write (void *wbuf, size_t wcount) |
Peform a write only I2C transaction. More... | |
static bool | i2c_read (void *rbuf, size_t rcount) |
Peform a read only I2C transaction. More... | |
static bool | sensor_init (void) |
Initialize the MPU-9250 sensor driver. More... | |
static void | sensor_sleep (void) |
Place the sensor in low-power mode. | |
static void | sensor_wakeup (void) |
Wakeup the sensor from low-power mode. | |
static bool | sensor_data_ready (uint8_t *int_status) |
Check whether a data or wake on motion interrupt has occurred. More... | |
static bool | acc_read (uint8_t int_status, uint16_t *data) |
Read data from the accelerometer, total of 3 words (X, Y, Z). More... | |
static bool | gyro_read (uint8_t int_status, uint16_t *data) |
Read data from the accelerometer, total of 3 words (X, Y, Z). More... | |
static int32_t | acc_convert (int32_t raw_data) |
Convert accelerometer raw reading to a value in G. More... | |
static int32_t | gyro_convert (int32_t raw_data) |
Convert gyro raw reading to a value in deg/sec. More... | |
static int | value (int type) |
Returns a reading from the sensor. More... | |
static int | configure (int type, int enable) |
Configuration function for the MPU9250 sensor. More... | |
static int | status (int type) |
Returns the status of the sensor. More... | |
Driver for the Sensortag Invensense MPU9250 motion processing unit.
Definition in file mpu-9250-sensor.c.