Move M150 to cpp

This commit is contained in:
Scott Lahteine
2017-09-17 00:50:24 -05:00
parent eef4a54778
commit 92c15f5578
3 changed files with 12 additions and 12 deletions

View File

@ -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