Add HAS_FILAMENT_SENSOR ahead of 12962
This commit is contained in:
@ -33,7 +33,7 @@
|
||||
#include "../gcode/queue.h"
|
||||
#endif
|
||||
|
||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||
#if HAS_FILAMENT_SENSOR
|
||||
#include "runout.h"
|
||||
#endif
|
||||
|
||||
@ -115,7 +115,7 @@ void host_action(const char * const pstr, const bool eol) {
|
||||
host_action_prompt_begin(PSTR("Paused"));
|
||||
host_action_prompt_button(PSTR("Purge More"));
|
||||
if (false
|
||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||
#if HAS_FILAMENT_SENSOR
|
||||
|| runout.filament_ran_out
|
||||
#endif
|
||||
)
|
||||
@ -127,7 +127,7 @@ void host_action(const char * const pstr, const bool eol) {
|
||||
host_action_prompt_show();
|
||||
}
|
||||
else if (response == 1) {
|
||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||
#if HAS_FILAMENT_SENSOR
|
||||
if (runout.filament_ran_out) {
|
||||
runout.enabled = false;
|
||||
runout.reset();
|
||||
|
@ -41,7 +41,7 @@
|
||||
#include "fwretract.h"
|
||||
#endif
|
||||
|
||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||
#if HAS_FILAMENT_SENSOR
|
||||
#include "runout.h"
|
||||
#endif
|
||||
|
||||
@ -112,7 +112,7 @@ static bool ensure_safe_temperature(const AdvancedPauseMode mode=ADVANCED_PAUSE_
|
||||
}
|
||||
|
||||
void do_pause_e_move(const float &length, const float &fr) {
|
||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||
#if HAS_FILAMENT_SENSOR
|
||||
runout.reset();
|
||||
#endif
|
||||
current_position[E_AXIS] += length / planner.e_factor[active_extruder];
|
||||
@ -251,7 +251,7 @@ bool load_filament(const float &slow_load_length/*=0*/, const float &fast_load_l
|
||||
host_action_prompt_begin(PSTR("Paused"));
|
||||
host_action_prompt_button(PSTR("PurgeMore"));
|
||||
if (false
|
||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||
#if HAS_FILAMENT_SENSOR
|
||||
|| runout.filament_ran_out
|
||||
#endif
|
||||
)
|
||||
|
@ -24,7 +24,7 @@
|
||||
|
||||
#include "../../inc/MarlinConfig.h"
|
||||
|
||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||
#if HAS_FILAMENT_SENSOR
|
||||
#include "../runout.h"
|
||||
#endif
|
||||
|
||||
@ -84,7 +84,7 @@ private:
|
||||
|
||||
static inline void set_runout_valid(const bool valid) {
|
||||
findaRunoutValid = valid;
|
||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||
#if HAS_FILAMENT_SENSOR
|
||||
if (valid) runout.reset();
|
||||
#endif
|
||||
}
|
||||
|
@ -26,7 +26,7 @@
|
||||
|
||||
#include "../inc/MarlinConfigPre.h"
|
||||
|
||||
#if ENABLED(FILAMENT_RUNOUT_SENSOR)
|
||||
#if HAS_FILAMENT_SENSOR
|
||||
|
||||
#include "runout.h"
|
||||
|
||||
@ -58,4 +58,4 @@ void FilamentSensorBase::filament_present(const uint8_t extruder) {
|
||||
int8_t RunoutResponseDebounced::runout_count; // = 0
|
||||
#endif
|
||||
|
||||
#endif // FILAMENT_RUNOUT_SENSOR
|
||||
#endif // HAS_FILAMENT_SENSOR
|
||||
|
Reference in New Issue
Block a user