![]() |
ISSDK
1.8
IoT Sensing Software Development Kit
|
Provides init() and read() functions for the MAG3110 magnetometer. More...
#include "board.h"
#include "sensor_fusion.h"
#include "sensor_drv.h"
#include "sensor_io_i2c.h"
#include "drivers.h"
#include "mag3110.h"
Go to the source code of this file.
Macros | |
#define | MAG3110_COUNTSPERUT 10 |
Functions | |
int8_t | MAG3110_Init (struct PhysicalSensor *sensor, SensorFusionGlobals *sfg) |
int8_t | MAG3110_Read (struct PhysicalSensor *sensor, SensorFusionGlobals *sfg) |
int8_t | MAG3110_Idle (struct PhysicalSensor *sensor, SensorFusionGlobals *sfg) |
Variables | |
const registerreadlist_t | MAG3110_WHO_AM_I_READ [] |
const registerreadlist_t | MAG3110_DR_STATUS_READ [] |
registerreadlist_t | MAG3110_DATA_READ [] |
const registerwritelist_t | MAG3110_Initialization [] |
const registerwritelist_t | MAG3110_IDLE [] |
Provides init() and read() functions for the MAG3110 magnetometer.
Definition in file driver_MAG3110.c.
#define MAG3110_COUNTSPERUT 10 |
Definition at line 19 of file driver_MAG3110.c.
Referenced by MAG3110_Init().
int8_t MAG3110_Idle | ( | struct PhysicalSensor * | sensor, |
SensorFusionGlobals * | sfg | ||
) |
Definition at line 147 of file driver_MAG3110.c.
References PhysicalSensor::addr, PhysicalSensor::bus_driver, PhysicalSensor::deviceInfo, F_USING_MAG, int32_t(), MagSensor::isEnabled, PhysicalSensor::isInitialized, SensorFusionGlobals::Mag, SENSOR_ERROR_INIT, Sensor_I2C_Write(), and status.
int8_t MAG3110_Init | ( | struct PhysicalSensor * | sensor, |
SensorFusionGlobals * | sfg | ||
) |
Definition at line 82 of file driver_MAG3110.c.
References PhysicalSensor::addr, PhysicalSensor::bus_driver, PhysicalSensor::deviceInfo, F_USING_MAG, MagSensor::fCountsPeruT, MagSensor::fuTPerCount, MagSensor::iCountsPeruT, int32_t(), MagSensor::isEnabled, PhysicalSensor::isInitialized, MagSensor::iWhoAmI, SensorFusionGlobals::Mag, MAG3110_COUNTSPERUT, MAG3110_WHO_AM_I, MAG3110_WHOAMI_VALUE, Register_I2C_Read(), SENSOR_ERROR_INIT, SENSOR_ERROR_NONE, Sensor_I2C_Write(), and status.
Referenced by main().
int8_t MAG3110_Read | ( | struct PhysicalSensor * | sensor, |
SensorFusionGlobals * | sfg | ||
) |
Definition at line 113 of file driver_MAG3110.c.
References PhysicalSensor::addr, addToFifo(), PhysicalSensor::bus_driver, CHX, CHY, CHZ, conditionSample(), PhysicalSensor::deviceInfo, F_USING_MAG, PhysicalSensor::isInitialized, SensorFusionGlobals::Mag, MAG_FIFO_SIZE, SENSOR_ERROR_INIT, SENSOR_ERROR_NONE, Sensor_I2C_Read(), and status.
Referenced by main().
registerreadlist_t MAG3110_DATA_READ[] |
Definition at line 36 of file driver_MAG3110.c.
const registerreadlist_t MAG3110_DR_STATUS_READ[] |
Definition at line 30 of file driver_MAG3110.c.
const registerwritelist_t MAG3110_IDLE[] |
Definition at line 139 of file driver_MAG3110.c.
const registerwritelist_t MAG3110_Initialization[] |
Definition at line 42 of file driver_MAG3110.c.
const registerreadlist_t MAG3110_WHO_AM_I_READ[] |
Definition at line 24 of file driver_MAG3110.c.