|
47 | 47 | // "Temperature" submenu items
|
48 | 48 | //
|
49 | 49 |
|
50 |
| -void Temperature::lcd_preheat(const uint8_t e, const int8_t indh, const int8_t indb) { |
51 |
| - UNUSED(e); UNUSED(indh); UNUSED(indb); |
52 |
| - #if HAS_HOTEND |
53 |
| - if (indh >= 0 && ui.material_preset[indh].hotend_temp > 0) |
54 |
| - setTargetHotend(_MIN(thermalManager.hotend_max_target(e), ui.material_preset[indh].hotend_temp), e); |
55 |
| - #endif |
56 |
| - #if HAS_HEATED_BED |
57 |
| - if (indb >= 0 && ui.material_preset[indb].bed_temp > 0) setTargetBed(ui.material_preset[indb].bed_temp); |
58 |
| - #endif |
59 |
| - #if HAS_FAN |
60 |
| - if (indh >= 0) { |
61 |
| - const uint8_t fan_index = active_extruder < (FAN_COUNT) ? active_extruder : 0; |
62 |
| - if (true |
63 |
| - #if REDUNDANT_PART_COOLING_FAN |
64 |
| - && fan_index != REDUNDANT_PART_COOLING_FAN |
65 |
| - #endif |
66 |
| - ) set_fan_speed(fan_index, ui.material_preset[indh].fan_speed); |
67 |
| - } |
68 |
| - #endif |
69 |
| - ui.return_to_status(); |
70 |
| -} |
71 |
| - |
72 | 50 | #if HAS_PREHEAT
|
73 | 51 |
|
| 52 | + void Temperature::lcd_preheat(const uint8_t e, const int8_t indh, const int8_t indb) { |
| 53 | + UNUSED(e); UNUSED(indh); UNUSED(indb); |
| 54 | + #if HAS_HOTEND |
| 55 | + if (indh >= 0 && ui.material_preset[indh].hotend_temp > 0) |
| 56 | + setTargetHotend(_MIN(thermalManager.hotend_max_target(e), ui.material_preset[indh].hotend_temp), e); |
| 57 | + #endif |
| 58 | + #if HAS_HEATED_BED |
| 59 | + if (indb >= 0 && ui.material_preset[indb].bed_temp > 0) setTargetBed(ui.material_preset[indb].bed_temp); |
| 60 | + #endif |
| 61 | + #if HAS_FAN |
| 62 | + if (indh >= 0) { |
| 63 | + const uint8_t fan_index = active_extruder < (FAN_COUNT) ? active_extruder : 0; |
| 64 | + if (true |
| 65 | + #if REDUNDANT_PART_COOLING_FAN |
| 66 | + && fan_index != REDUNDANT_PART_COOLING_FAN |
| 67 | + #endif |
| 68 | + ) set_fan_speed(fan_index, ui.material_preset[indh].fan_speed); |
| 69 | + } |
| 70 | + #endif |
| 71 | + ui.return_to_status(); |
| 72 | + } |
| 73 | + |
74 | 74 | #if HAS_TEMP_HOTEND
|
75 | 75 | inline void _preheat_end(const uint8_t m, const uint8_t e) { thermalManager.lcd_preheat(e, m, -1); }
|
76 | 76 | void do_preheat_end_m() { _preheat_end(editable.int8, 0); }
|
|
0 commit comments