From 35d9584f6dfe5afd927ca900a2946d9e2044c01d Mon Sep 17 00:00:00 2001 From: Robin Mueller Date: Mon, 24 Jun 2024 23:48:54 +0200 Subject: [PATCH] does this work? --- src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib.rs b/src/lib.rs index 251038a..aa2a7d8 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -523,7 +523,7 @@ impl Lis2dh12 { let (out_h, out_l) = self.get_temp_out()?; // 10-bit resolution let value = (i16(out_h) << 8) | i16(out_l); - Ok(25 + f32(value) * 1) + Ok(25.0 + f32(value)) } /// `REFERENCE` register