Go to the documentation of this file.
139 #if MODULE_HMC5883L_INT || DOXYGEN
160 #if MODULE_HMC5883L_INT
175 #if MODULE_HMC5883L_INT
197 #if MODULE_HMC5883L_INT || DOXYGEN
@ HMC5883L_MEAS_MODE_BIAS_POS
Positive bias config for all axes.
hmc5883l_op_mode_t op_mode
Operation mode (HMC5883L_OP_MODE_CONTINUOUS)
@ HMC5883L_GAIN_330
Range +-5.6 Gs, Resolution 3.03 mGs/LSB.
@ HMC5883L_OP_MODE_CONTINUOUS
Continuous measurement.
HMC5883L device initialization parameters.
@ HMC5883L_OP_MODE_SINGLE
Single measurement.
hmc5883l_gain_t gain
Gain (default HMC5883L_GAIN_1090)
int hmc5883l_init_int(hmc5883l_t *dev, hmc5883l_drdy_int_cb_t cb, void *arg)
Initialize and activate the DRDY interrupt of HMC5883L sensor device.
int16_t y
magnetic field y-axis as 16 bit two's complements
@ HMC5883L_OP_MODE_IDLE
Idle mode.
@ HMC5883L_ERROR_I2C
any I2C communication error
hmc5883l_dor_t dor
Data output rate (default HMC5883L_DOR_15)
int16_t z
magnetic field z-axis as 16 bit two's complements
hmc5883l_meas_avg_t meas_avg
Measurement avaraging (default HMC5883L_MEAS_AVG_NONE)
hmc5883l_error_codes_t
Definition of error codes.
hmc5883l_meas_mode_t meas_mode
Measurement mode (default HMC5883L_MEAS_MODE_NORMAL)
hmc5883l_gain_t
Gain (determines the sensitivity and the range)
int hmc5883l_power_down(hmc5883l_t *dev)
Power down the sensor.
@ HMC5883L_MEAS_AVG_4
4 samples are averaged
int16_t x
magnetic field x-axis as 16 bit two's complements
@ HMC5883L_ERROR_RAW_DATA
reading raw data failed
int16_t z
magnetic field y-axis
@ HMC5883L_GAIN_820
Range +-1.9 Gs, Resolution 1.22 mGs/LSB.
@ HMC5883L_GAIN_660
Range +-2.5 Gs, Resolution 1.52 mGs/LSB.
@ HMC5883L_MEAS_MODE_NORMAL
Normal measurement config.
int hmc5883l_power_up(hmc5883l_t *dev)
Power up the sensor.
@ HMC5883L_ERROR_COMMON
common error
int hmc5883l_init(hmc5883l_t *dev, const hmc5883l_params_t *params)
Initialize the HMC5883L sensor device.
@ HMC5883L_MEAS_AVG_8
8 samples are averaged
@ HMC5883L_GAIN_440
Range +-4.0 Gs, Resolution 2.27 mGs/LSB.
@ HMC5883L_ERROR_NO_DATA
no data are available
int hmc5883l_read_raw(const hmc5883l_t *dev, hmc5883l_raw_data_t *raw)
Read one sample of raw sensor data as 16 bit two's complements.
@ HMC5883L_DOR_0_75
0.75 Hz
@ HMC5883L_GAIN_1370
Range +-0.88 Gs, Resolution 0.73 mGs/LSB.
@ HMC5883L_GAIN_390
Range +-4.7 Gs, Resolution 2.56 mGs/LSB.
hmc5883l_gain_t gain
Gain (default HMC5883L_GAIN_1090)
void(* hmc5883l_drdy_int_cb_t)(void *)
HMC5883L DRDY interrupt callback function type.
@ HMC5883L_MEAS_AVG_NONE
No averaging.
@ HMC5883L_GAIN_230
Range +-8.1 Gs, Resolution 4.35 mGs/LSB.
hmc5883l_meas_mode_t
Measurement modes.
hmc5883l_op_mode_t
Operation modes.
@ HMC5883L_MEAS_MODE_BIAS_NEG
Negative bias config for all axes.
int hmc5883l_read(const hmc5883l_t *dev, hmc5883l_data_t *data)
Read one sample of magnetic field values in milli-Gauss (mGs)
Magnetic field values in milli-Gauss (mGs)
hmc5883l_dor_t
Data output rates (DOR)
@ HMC5883L_GAIN_1090
Range +-1.3 Gs, Resolution 0.92 mGs/LSB.
@ HMC5883L_DOR_15
15 Hz (default)
int16_t y
magnetic field y-axis
Low-level GPIO peripheral driver interface definitions.
@ HMC5883L_ERROR_WRONG_ID
wrong id read
int16_t x
magnetic field x-axis
int hmc5883l_data_ready(const hmc5883l_t *dev)
Data-ready status function.
hmc5883l_op_mode_t op_mode
Operation mode (HMC5883L_OP_MODE_CONTINUOUS)
@ HMC5883L_MEAS_AVG_2
2 samples are averaged
Raw data set as two complements.
Low-level I2C peripheral driver interface definition.
hmc5883l_meas_avg_t
Measurement avaraging (number of samples are averaged for output)
HMC5883L sensor device data structure type.