Laser Coolant Flow Meter / Safety Shutdown (#21431)

Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com>
This commit is contained in:
Mike La Spina
2021-03-29 01:41:56 -05:00
committed by GitHub
parent 8f509b0ae0
commit ccdbffbf3f
20 changed files with 512 additions and 173 deletions

View File

@@ -35,7 +35,7 @@
#include "../../module/motion.h"
#endif
#if HAS_COOLER
#if HAS_COOLER || HAS_FLOWMETER
#include "../../feature/cooler.h"
#endif
@@ -192,11 +192,19 @@ void menu_temperature() {
// Cooler:
//
#if HAS_COOLER
editable.state = cooler.is_enabled();
EDIT_ITEM(bool, MSG_COOLER(TOGGLE), &cooler.state, []{ if (editable.state) cooler.disable(); else cooler.enable(); });
bool cstate = cooler.enabled;
EDIT_ITEM(bool, MSG_COOLER_TOGGLE, &cstate, cooler.toggle);
EDIT_ITEM_FAST(int3, MSG_COOLER, &thermalManager.temp_cooler.target, COOLER_MIN_TARGET, COOLER_MAX_TARGET, thermalManager.start_watching_cooler);
#endif
//
// Flow Meter Safety Shutdown:
//
#if ENABLED(FLOWMETER_SAFETY)
bool fstate = cooler.flowsafety_enabled;
EDIT_ITEM(bool, MSG_FLOWMETER_SAFETY, &fstate, cooler.flowsafety_toggle);
#endif
//
// Fan Speed:
//