Move some MarlinCore and MarlinUI code (#20832)
This commit is contained in:
@@ -118,9 +118,7 @@ class TFilamentMonitor : public FilamentMonitorBase {
|
||||
|
||||
// Give the response a chance to update its counter.
|
||||
static inline void run() {
|
||||
if ( enabled && !filament_ran_out
|
||||
&& (printingIsActive() || TERN0(ADVANCED_PAUSE_FEATURE, did_pause_print))
|
||||
) {
|
||||
if (enabled && !filament_ran_out && (printingIsActive() || did_pause_print)) {
|
||||
TERN_(HAS_FILAMENT_RUNOUT_DISTANCE, cli()); // Prevent RunoutResponseDelayed::block_completed from accumulating here
|
||||
response.run();
|
||||
sensor.run();
|
||||
@@ -343,9 +341,7 @@ class FilamentSensorBase {
|
||||
}
|
||||
|
||||
static inline void block_completed(const block_t* const b) {
|
||||
if (b->steps.x || b->steps.y || b->steps.z
|
||||
|| TERN0(ADVANCED_PAUSE_FEATURE, did_pause_print) // Allow pause purge move to re-trigger runout state
|
||||
) {
|
||||
if (b->steps.x || b->steps.y || b->steps.z || did_pause_print) { // Allow pause purge move to re-trigger runout state
|
||||
// Only trigger on extrusion with XYZ movement to allow filament change and retract/recover.
|
||||
const uint8_t e = b->extruder;
|
||||
const int32_t steps = b->steps.e;
|
||||
|
||||
Reference in New Issue
Block a user