Public Member Functions
uint8_t getDeviceID ()
uint8_t getInfo ()
bool getDataReady ()
void getHeading (int16_t *x, int16_t *y, int16_t *z)
int16_t getHeadingX ()
int16_t getHeadingY ()
int16_t getHeadingZ ()
bool getOverflowStatus ()
bool getDataError ()
uint8_t getMode ()
void setMode (uint8_t mode)
void reset ()
void setSelfTest (bool enabled)
void disableI2C ()
void getAdjustment (uint8_t *x, uint8_t *y, uint8_t *z)
void setAdjustment (uint8_t x, uint8_t y, uint8_t z)
uint8_t getAdjustmentX ()
void setAdjustmentX (uint8_t x)
uint8_t getAdjustmentY ()
void setAdjustmentY (uint8_t y)
uint8_t getAdjustmentZ ()
void setAdjustmentZ (uint8_t z)
Constructor & Destructor Documentation
Default constructor, uses default I2C address.
- See also:
- AK8975_DEFAULT_ADDRESS
AK8975::AK8975
(
uint8_t
address )
Specific address constructor.
- Parameters:
-
address I2C address
- See also:
- AK8975_DEFAULT_ADDRESS
-
AK8975_ADDRESS_00
Member Function Documentation
void AK8975::initialize
(
)
Power on and prepare for general usage. No specific pre-configuration is necessary for this device.
bool AK8975::testConnection
(
)
Verify the I2C connection. Make sure the device is connected and responds as expected.
- Returns:
- True if connection is valid, false otherwise
The documentation for this class was generated from the following files: