Sfoglia il codice sorgente

🐛 Use ADC_VREF for Filament Width ADC Vref (#23977)

Manianac 2 anni fa
parent
commit
72a9a02c17
Nessun account collegato all'indirizzo email del committer
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1
    1
      Marlin/src/feature/filwidth.h

+ 1
- 1
Marlin/src/feature/filwidth.h Vedi File

@@ -67,7 +67,7 @@ public:
67 67
   }
68 68
 
69 69
   // Convert raw measurement to mm
70
-  static float raw_to_mm(const uint16_t v) { return v * 5.0f * RECIPROCAL(float(MAX_RAW_THERMISTOR_VALUE)); }
70
+  static float raw_to_mm(const uint16_t v) { return v * float(ADC_VREF) * RECIPROCAL(float(MAX_RAW_THERMISTOR_VALUE)); }
71 71
   static float raw_to_mm() { return raw_to_mm(raw); }
72 72
 
73 73
   // A scaled reading is ready

Loading…
Annulla
Salva