Fix FILAMENT_LCD_DISPLAY for disabled state

This commit is contained in:
Scott Lahteine
2017-11-16 16:19:58 -06:00
parent 1e8afb66b7
commit b2dda096fe
3 changed files with 18 additions and 9 deletions

View File

@ -1002,13 +1002,12 @@ void Temperature::updateTemperaturesFromRawValues() {
// Convert raw Filament Width to millimeters
float Temperature::analog2widthFil() {
return current_raw_filwidth * 5.0 * (1.0 / 16383.0);
//return current_raw_filwidth;
}
// Convert raw Filament Width to a ratio
int Temperature::widthFil_to_size_ratio() {
float temp = filament_width_meas;
if (temp < MEASURED_LOWER_LIMIT) temp = filament_width_nominal; //assume sensor cut out
if (temp < MEASURED_LOWER_LIMIT) temp = filament_width_nominal; // Assume a bad sensor reading
else NOMORE(temp, MEASURED_UPPER_LIMIT);
return filament_width_nominal / temp * 100;
}