Public Member Functions | Private Attributes | List of all members
HMC5883L Class Reference

#include <hmc5883l.h>

Public Member Functions

void cb (uint8_t result)
 
bool init (I2C *i2c_drv)
 
bool is_initialized ()
 
bool present ()
 
bool read (float mag_data[])
 
void update ()
 

Private Attributes

volatile float data_ [3]
 
I2Ci2c_ {nullptr}
 
uint8_t i2c_buf_ [6]
 
uint32_t last_update_ms_
 
bool mag_present_ {false}
 
uint32_t next_update_ms_
 

Detailed Description

Definition at line 83 of file hmc5883l.h.

Member Function Documentation

void HMC5883L::cb ( uint8_t  result)

Definition at line 85 of file hmc5883l.cpp.

bool HMC5883L::init ( I2C i2c_drv)

Definition at line 37 of file hmc5883l.cpp.

bool HMC5883L::is_initialized ( )
inline

Definition at line 91 of file hmc5883l.h.

bool HMC5883L::present ( )

Definition at line 69 of file hmc5883l.cpp.

bool HMC5883L::read ( float  mag_data[])

Definition at line 100 of file hmc5883l.cpp.

void HMC5883L::update ( )

Definition at line 76 of file hmc5883l.cpp.

Member Data Documentation

volatile float HMC5883L::data_[3]
private

Definition at line 96 of file hmc5883l.h.

I2C* HMC5883L::i2c_ {nullptr}
private

Definition at line 94 of file hmc5883l.h.

uint8_t HMC5883L::i2c_buf_[6]
private

Definition at line 95 of file hmc5883l.h.

uint32_t HMC5883L::last_update_ms_
private

Definition at line 97 of file hmc5883l.h.

bool HMC5883L::mag_present_ {false}
private

Definition at line 99 of file hmc5883l.h.

uint32_t HMC5883L::next_update_ms_
private

Definition at line 98 of file hmc5883l.h.


The documentation for this class was generated from the following files:


rosflight_firmware
Author(s): Daniel Koch , James Jackson
autogenerated on Thu Apr 15 2021 05:07:58