Adafruit HMC5883 Unified Library
|
Unified sensor driver for the magnetometer ///. More...
#include <Adafruit_HMC5883_U.h>
Public Member Functions | |
Adafruit_HMC5883_Unified (int32_t sensorID=-1) | |
Instantiates a new Adafruit_HMC5883 class. More... | |
bool | begin (void) |
Setups the HW. More... | |
void | setMagGain (hmc5883MagGain gain) |
Sets the magnetometer's gain. More... | |
bool | getEvent (sensors_event_t *) |
Gets the most recent sensor event. More... | |
void | getSensor (sensor_t *) |
Gets the sensor_t data. | |
Unified sensor driver for the magnetometer ///.
Adafruit_HMC5883_Unified::Adafruit_HMC5883_Unified | ( | int32_t | sensorID = -1 | ) |
Instantiates a new Adafruit_HMC5883 class.
sensorID | sensor ID, -1 by default |
bool Adafruit_HMC5883_Unified::begin | ( | void | ) |
Setups the HW.
void Adafruit_HMC5883_Unified::setMagGain | ( | hmc5883MagGain | gain | ) |
Sets the magnetometer's gain.
gain | Desired magnetic gain |
bool Adafruit_HMC5883_Unified::getEvent | ( | sensors_event_t * | event | ) |
Gets the most recent sensor event.