From a5e3df0375db96205dffb1e5f7e5fd0fb83c1296 Mon Sep 17 00:00:00 2001 From: Jan-Stefan Janetzky Date: Sun, 20 Nov 2022 23:53:11 +0100 Subject: [PATCH] [FAP] htu21d falsely reading temp as humidity compiled and tested by blowing onto the sensor. fixes #174 --- applications/plugins/htu21d_temp_sensor/temperature_sensor.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/plugins/htu21d_temp_sensor/temperature_sensor.c b/applications/plugins/htu21d_temp_sensor/temperature_sensor.c index 407bc76d0..eb03571fe 100644 --- a/applications/plugins/htu21d_temp_sensor/temperature_sensor.c +++ b/applications/plugins/htu21d_temp_sensor/temperature_sensor.c @@ -113,7 +113,7 @@ static bool temperature_sensor_fetch_data(double* temperature, double* humidity) *temperature = (float)(adc_raw * 175.72 / 65536.00) - 46.85; // Fetch humidity - ret = temperature_sensor_cmd((uint8_t)HTU21D_CMD_TEMPERATURE, buffer, 2); + ret = temperature_sensor_cmd((uint8_t)HTU21D_CMD_HUMIDITY, buffer, 2); if(ret) { // Calculate humidity