Move M150 to cpp
This commit is contained in:
parent
eef4a54778
commit
92c15f5578
@ -355,10 +355,6 @@ bool pin_is_protected(const int8_t pin) {
|
||||
return false;
|
||||
}
|
||||
|
||||
#if HAS_COLOR_LEDS
|
||||
#include "gcode/feature/leds/M150.h"
|
||||
#endif
|
||||
|
||||
#include "gcode/config/M201.h"
|
||||
|
||||
#if 0 // Not used for Sprinter/grbl gen6
|
||||
|
@ -20,6 +20,13 @@
|
||||
*
|
||||
*/
|
||||
|
||||
#include "../../../inc/MarlinConfig.h"
|
||||
|
||||
#if HAS_COLOR_LEDS
|
||||
|
||||
#include "../../gcode.h"
|
||||
#include "../../../feature/leds/leds.h"
|
||||
|
||||
/**
|
||||
* M150: Set Status LED Color - Use R-U-B-W for R-G-B-W
|
||||
*
|
||||
@ -34,7 +41,7 @@
|
||||
* M150 W ; Turn LED white using a white LED
|
||||
*
|
||||
*/
|
||||
void gcode_M150() {
|
||||
void GcodeSuite::M150() {
|
||||
set_led_color(
|
||||
parser.seen('R') ? (parser.has_value() ? parser.value_byte() : 255) : 0,
|
||||
parser.seen('U') ? (parser.has_value() ? parser.value_byte() : 255) : 0,
|
||||
@ -44,3 +51,5 @@ void gcode_M150() {
|
||||
#endif
|
||||
);
|
||||
}
|
||||
|
||||
#endif // HAS_COLOR_LEDS
|
@ -116,7 +116,6 @@ void GcodeSuite::dwell(millis_t time) {
|
||||
//
|
||||
// Placeholders for non-migrated codes
|
||||
//
|
||||
extern void gcode_M150();
|
||||
extern void gcode_M163();
|
||||
extern void gcode_M164();
|
||||
extern void gcode_M165();
|
||||
@ -509,12 +508,8 @@ void GcodeSuite::process_next_command() {
|
||||
#endif
|
||||
|
||||
#if HAS_COLOR_LEDS
|
||||
|
||||
case 150: // M150: Set Status LED Color
|
||||
gcode_M150();
|
||||
break;
|
||||
|
||||
#endif // HAS_COLOR_LEDS
|
||||
case 150: M150(); break; // M150: Set Status LED Color
|
||||
#endif
|
||||
|
||||
#if ENABLED(MIXING_EXTRUDER)
|
||||
case 163: // M163: Set a component weight for mixing extruder
|
||||
|
Loading…
Reference in New Issue
Block a user