From 298cbec7fc7b32abd30b7e00b37ad71e3ab0ec81 Mon Sep 17 00:00:00 2001 From: "H. Utku Maden" Date: Wed, 1 May 2024 11:48:46 +0300 Subject: [PATCH] Fixes humidity bug in #3. Thanks @kaido42. --- bmx280.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bmx280.c b/bmx280.c index 6e28478..4be32e3 100644 --- a/bmx280.c +++ b/bmx280.c @@ -531,7 +531,7 @@ esp_err_t bmx280_readout(bmx280_t *bmx280, int32_t *temperature, uint32_t *press return error; *humidity = bme280_compensate_H_int32(bmx280, - (buffer[0] << 8) | buffer[0] + (buffer[0] << 8) | buffer[1] ); } }