Selaa lähdekoodia

🩹 Fix MAX31865 approximations

Followup to #24407
Scott Lahteine 1 vuosi sitten
vanhempi
commit
c2972899ca
1 muutettua tiedostoa jossa 3 lisäystä ja 3 poistoa
  1. 3
    3
      Marlin/src/libs/MAX31865.cpp

+ 3
- 3
Marlin/src/libs/MAX31865.cpp Näytä tiedosto

@@ -489,9 +489,9 @@ float MAX31865::temperature(float rtd_res) {
489 489
     temp = RTD_C[0];
490 490
     temp += rpoly * RTD_C[1];
491 491
     rpoly *= rtd_res; temp += rpoly * RTD_C[2];
492
-    if (MAX31865_APPROX >= 3) rpoly *= rtd_res; temp += rpoly * RTD_C[3];
493
-    if (MAX31865_APPROX >= 4) rpoly *= rtd_res; temp += rpoly * RTD_C[4];
494
-    if (MAX31865_APPROX >= 5) rpoly *= rtd_res; temp += rpoly * RTD_C[5];
492
+    if (MAX31865_APPROX >= 3) { rpoly *= rtd_res; temp += rpoly * RTD_C[3]; }
493
+    if (MAX31865_APPROX >= 4) { rpoly *= rtd_res; temp += rpoly * RTD_C[4]; }
494
+    if (MAX31865_APPROX >= 5) { rpoly *= rtd_res; temp += rpoly * RTD_C[5]; }
495 495
   }
496 496
 
497 497
   return temp;

Loading…
Peruuta
Tallenna