26 const uint8_t BMP085::PRESSURE_CONV_MS[]
__PROGMEM = {
76 if (ms > 0)
delay(ms);
121 ms += pgm_read_byte(&PRESSURE_CONV_MS[
m_mode]);
122 if (ms > 0)
delay(ms);
134 int32_t B3, B6, X1, X2, X3;
139 X1 = (
m_param.
b2 * ((B6 * B6) >> 12)) >> 11;
144 X2 = (
m_param.
b1 * ((B6 * B6) >> 12)) >> 16;
145 X3 = ((X1 + X2) + 2) >> 2;
146 B4 = (
m_param.
ac4 * (uint32_t) (X3 + 32768)) >> 15;
147 B7 = ((uint32_t) UP - B3) * (50000 >>
m_mode);
148 m_pressure = (B7 < 0x80000000) ? (B7 << 1) / B4 : (B7 / B4) << 1;
150 X1 = (X1 * 3038) >> 16;
static const uint8_t RES_REG
static const uint8_t PRESSURE_CONV_CMD
bool sample_pressure_request()
bool begin(Mode mode=ULTRA_LOW_POWER)
IOStream & operator<<(IOStream &outs, BMP085 &bmp)
static const uint8_t TEMP_CONV_CMD
void(* delay)(uint32_t ms)
static const uint8_t COEFF_REG
int read(void *buf, size_t size)
const uint8_t BMP085::PRESSURE_CONV_MS[] __PROGMEM
int write(void *buf, size_t size)
bool sample_temperature_request()
void acquire(TWI::Driver *dev)
static const uint8_t CMD_REG
int16_t temperature() const
static const uint8_t TEMP_CONV_MS