⚡️ Handle shared enable pins (#22824)
This commit is contained in:
committed by
Scott Lahteine
parent
25a131b942
commit
021ceeba0b
@ -33,6 +33,7 @@
|
||||
#include "../../../core/language.h"
|
||||
#include "../../../module/temperature.h"
|
||||
#include "../../../module/printcounter.h"
|
||||
#include "../../../module/stepper.h"
|
||||
#include "../../../gcode/queue.h"
|
||||
#if ENABLED(ADVANCED_PAUSE_FEATURE)
|
||||
#include "../../../feature/pause.h"
|
||||
@ -375,10 +376,10 @@ void DGUSRxHandler::Steppers(DGUS_VP &vp, void *data_ptr) {
|
||||
|
||||
switch (control) {
|
||||
case DGUS_Data::Control::ENABLE:
|
||||
enable_all_steppers();
|
||||
stepper.enable_all_steppers();
|
||||
break;
|
||||
case DGUS_Data::Control::DISABLE:
|
||||
disable_all_steppers();
|
||||
stepper.disable_all_steppers();
|
||||
break;
|
||||
}
|
||||
|
||||
@ -553,7 +554,7 @@ void DGUSRxHandler::FilamentSelect(DGUS_VP &vp, void *data_ptr) {
|
||||
default: return;
|
||||
case DGUS_Data::Extruder::CURRENT:
|
||||
case DGUS_Data::Extruder::E0:
|
||||
TERN_(HAS_MULTI_EXTRUDER, case DGUS_Data::Extruder::E1:)
|
||||
E_TERN_(case DGUS_Data::Extruder::E1:)
|
||||
dgus_screen_handler.filament_extruder = extruder;
|
||||
break;
|
||||
}
|
||||
|
@ -286,14 +286,8 @@ void DGUSTxHandler::TempMax(DGUS_VP &vp) {
|
||||
}
|
||||
|
||||
void DGUSTxHandler::StepperStatus(DGUS_VP &vp) {
|
||||
if (X_ENABLE_READ() == X_ENABLE_ON
|
||||
&& Y_ENABLE_READ() == Y_ENABLE_ON
|
||||
&& Z_ENABLE_READ() == Z_ENABLE_ON) {
|
||||
dgus_display.Write((uint16_t)vp.addr, Swap16((uint16_t)DGUS_Data::Status::ENABLED));
|
||||
}
|
||||
else {
|
||||
dgus_display.Write((uint16_t)vp.addr, Swap16((uint16_t)DGUS_Data::Status::DISABLED));
|
||||
}
|
||||
const bool motor_on = stepper.axis_enabled.bits & (_BV(LINEAR_AXES) - 1);
|
||||
dgus_display.Write((uint16_t)vp.addr, Swap16(uint16_t(motor_on ? DGUS_Data::Status::ENABLED : DGUS_Data::Status::DISABLED)));
|
||||
}
|
||||
|
||||
void DGUSTxHandler::StepIcons(DGUS_VP &vp) {
|
||||
|
Reference in New Issue
Block a user