File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -95,7 +95,7 @@ uint8_t BME280::begin()
9595 }
9696
9797 // Reading all compensation data, range 0x88:A1, 0xE1:E7
98-
98+
9999 calibration.dig_T1 = ((uint16_t )((readRegister (BME280_DIG_T1_MSB_REG) << 8 ) + readRegister (BME280_DIG_T1_LSB_REG)));
100100 calibration.dig_T2 = ((int16_t )((readRegister (BME280_DIG_T2_MSB_REG) << 8 ) + readRegister (BME280_DIG_T2_LSB_REG)));
101101 calibration.dig_T3 = ((int16_t )((readRegister (BME280_DIG_T3_MSB_REG) << 8 ) + readRegister (BME280_DIG_T3_LSB_REG)));
@@ -123,7 +123,7 @@ uint8_t BME280::begin()
123123 // Set the config word
124124 dataToWrite = (settings.tStandby << 0x5 ) & 0xE0 ;
125125 dataToWrite |= (settings.filter << 0x02 ) & 0x1C ;
126- dataToWrite |= (settings.runMode ) & 0x01 ;
126+ // dataToWrite |= (settings.runMode) & 0x01;
127127 writeRegister (BME280_CONFIG_REG, dataToWrite);
128128
129129 // Set ctrl_hum first, then ctrl_meas to activate ctrl_hum
@@ -141,7 +141,7 @@ uint8_t BME280::begin()
141141 writeRegister (BME280_CTRL_MEAS_REG, dataToWrite);
142142
143143
144- return 0 ;
144+ return readRegister ( 0xD0 ) ;
145145}
146146
147147// Strictly resets. Run .begin() afterwards
You can’t perform that action at this time.
0 commit comments