From: Nathael Pajani Date: Thu, 3 Jan 2019 16:52:05 +0000 (+0100) Subject: Temperature can be negative, use signed integer. X-Git-Url: http://git.techno-innov.fr/?a=commitdiff_plain;h=d7655807bc6a50358d51ce85c98cd2c29a4524c7;p=soft%2Flpc122x%2Fcore Temperature can be negative, use signed integer. --- diff --git a/extdrv/bme280_humidity_sensor.c b/extdrv/bme280_humidity_sensor.c index 42044f0..656b569 100644 --- a/extdrv/bme280_humidity_sensor.c +++ b/extdrv/bme280_humidity_sensor.c @@ -170,7 +170,7 @@ int bme280_configure(struct bme280_sensor_config* conf) * glibc. */ #define READ_CMD_SIZE 3 -int bme280_sensor_read(struct bme280_sensor_config* conf, uint32_t* pressure, uint32_t* temp, uint16_t* hum) +int bme280_sensor_read(struct bme280_sensor_config* conf, uint32_t* pressure, int32_t* temp, uint16_t* hum) { int ret = 0; char cmd_buf[READ_CMD_SIZE] = { conf->addr, BME280_REGS(raw_data), (conf->addr | I2C_READ_BIT), };