From: Nathael Pajani Date: Fri, 12 May 2017 23:09:44 +0000 (+0200) Subject: remove unrequired sleep from bme driver. X-Git-Url: http://git.techno-innov.fr/?a=commitdiff_plain;h=5ccfc84215c53a3de05de1a36a1fc3ea6724fcee;p=soft%2Flpc122x%2Fcore remove unrequired sleep from bme driver. --- diff --git a/extdrv/bme280_humidity_sensor.c b/extdrv/bme280_humidity_sensor.c index 9976edf..42044f0 100644 --- a/extdrv/bme280_humidity_sensor.c +++ b/extdrv/bme280_humidity_sensor.c @@ -148,16 +148,13 @@ int bme280_configure(struct bme280_sensor_config* conf) if (bme280_probe_sensor(conf) != 1) { return -ENODEV; } - /* The call to bme280_configure() was certainly the first access to the sensor, so - * the probe part made I2C access, thus leave some delay for I2C to become available again. */ - msleep(1); /* Send the configuration */ ret = i2c_write(conf->bus_num, cmd_buf, CONF_BUF_SIZE, NULL); if (ret != CONF_BUF_SIZE) { conf->probe_ok = 0; return -EIO; } - + /* Get the calibration data */ ret = bme280_get_calibration_data(conf); return ret;