From 4f394a4a21eb6fe983f83255dc9e358c7568fe71 Mon Sep 17 00:00:00 2001 From: zhaohe Date: Fri, 25 Aug 2023 12:31:38 +0800 Subject: [PATCH] fix some bug --- src/service/disinfection_ctl_service.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/service/disinfection_ctl_service.cpp b/src/service/disinfection_ctl_service.cpp index a7faf17..c0818af 100644 --- a/src/service/disinfection_ctl_service.cpp +++ b/src/service/disinfection_ctl_service.cpp @@ -83,7 +83,7 @@ float DisinfectionCtrlService::getDisinfectionDValue(float ppm) { if (ppm < 150) { dvalue = -0.5251 * ppm + 98.154; - } else if (ppm >= 150 || ppm < 240) { + } else if (ppm >= 150 && ppm < 240) { dvalue = -0.125 * ppm + 38.913; } else if (ppm >= 240) { // 240 -> 8.913