modm API documentation
modm::bme280data::Data Class Reference
Inheritance diagram for modm::bme280data::Data:
modm::bme280data::DataBase

Public Member Functions

int32_t getTemperature ()
 
void getTemperature (int32_t &temp)
 
void getTemperature (float &temp)
 
void getTemperature (double &temp)
 
int32_t getPressure ()
 
int32_t getHumidity ()
 
CalibrationgetCalibration ()
 
void rawHumidityTouched ()
 Notify data class about changed buffer of raw pressure data.
 
void rawPressureTouched ()
 Notify data class about changed buffer of raw pressure data.
 
void rawTemperatureTouched ()
 Notify data class about changed buffer of raw temperature data.
 

Protected Types

enum  { HUMIDITY_CALCULATED = Bit2, TEMPERATURE_CALCULATED = Bit1, PRESSURE_CALCULATED = Bit0 }
 

Protected Member Functions

void calculateCalibratedTemperature ()
 
void calculateCalibratedPressure ()
 
void calculateCalibratedHumidity ()
 

Protected Attributes

Calibration calibration
 
uint8_t meta
 
uint8_t raw [8]
 

Member Enumeration Documentation

anonymous enum
inheritedprotected
Enum ValuesDocumentation
HUMIDITY_CALCULATED 

Remember if the raw data was already converted to calibrated humidity.

TEMPERATURE_CALCULATED 

Remember if the raw data was already converted to calibrated temperature.

PRESSURE_CALCULATED 

Remember if the raw data was already converted to calibrated pressure.

Member Function Documentation

void Data::calculateCalibratedHumidity ( )
inlineprotected
void Data::calculateCalibratedPressure ( )
inlineprotected
void Data::calculateCalibratedTemperature ( )
inlineprotected

Use the calibration data read from the sensor to calculate the calibrated temperature from the raw data. The result is stored in this struct for further access. Implemented differently for Fixed Point, Single and Double Precision by template specialsation.

int32_t Data::getPressure ( )
inline

Get the calibrated pressure from the device in Pascal.

If recalculation is necessary it is done on the fly. No I2C transaction.

int32_t Data::getTemperature ( )
inline

Get the calibrated temperature for the device in 0.01 degree Celsius

If recalculation is necessary it is done on the fly. No I2C transaction.

Member Data Documentation

uint8_t modm::bme280data::DataBase::raw[8]
inheritedprotected

The raw data that was read from the sensor 0 .. 2 pressure data 3 .. 5 temperatur data 6 .. 7 humidity data


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