|
upm
0.4.1
Sensor/Actuator repository for libmraa (v0.8.0)
|
API for the HMC5883L 3-Axis Digital Compass. More...
Honeywell HMC5883L is a 3-axis digital compass. Communication with HMC5883L is simple and all done through an I2C interface. Different breakout boards are available. Typically, a 3V supply is all that is needed to power the sensor.
Public Member Functions | |
| synchronized void | delete () |
| Hmc5883l (int bus) | |
| float | direction () |
| float | heading () |
| short[] | coordinates () |
| int | update () |
| void | set_declination (float dec) |
| float | get_declination () |
| short [] coordinates | ( | ) |
Returns a pointer to an int[3] that contains the coordinates as ints
| float get_declination | ( | ) |
Gets the current magnetic declination value
| void set_declination | ( | float | dec | ) |
Sets the magnetic declination for better calibration
| int update | ( | ) |
Updates the values by reading from I2C
1.8.9.1