Skip to content

Commit d4656eb

Browse files
committed
https://github.com/adafruit/Adafruit_LSM9DS0_Library/issues/4
1 parent 89ecde9 commit d4656eb

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

Adafruit_LSM9DS0.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -405,13 +405,9 @@ byte Adafruit_LSM9DS0::readBuffer(boolean type, byte reg, byte len, uint8_t *buf
405405
_wire->endTransmission();
406406
_wire->requestFrom(address, (byte)len);
407407

408-
// Wait around until enough data is available
409-
while (_wire->available() < len);
410-
411408
for (uint8_t i=0; i<len; i++) {
412409
buffer[i] = _wire->read();
413410
}
414-
_wire->endTransmission();
415411
} else {
416412
SPI.beginTransaction(SPISettings(200000, MSBFIRST, SPI_MODE0));
417413
digitalWrite(_cs, LOW);
@@ -550,4 +546,4 @@ void Adafruit_LSM9DS0::getTempSensor(sensor_t* sensor) {
550546
sensor->max_value = 0.0; // ToDo
551547
sensor->min_value = 0.0; // ToDo
552548
sensor->resolution = 0.0; // ToDo
553-
}
549+
}

0 commit comments

Comments
 (0)