Move M42 to cpp

This commit is contained in:
Scott Lahteine
2017-09-16 03:42:05 -05:00
parent 69b664b6fe
commit 10fab24e50
4 changed files with 9 additions and 7 deletions

View File

@@ -363,15 +363,13 @@ void suicide() {
/**
* Sensitive pin test for M42, M226
*/
static bool pin_is_protected(const int8_t pin) {
bool pin_is_protected(const int8_t pin) {
static const int8_t sensitive_pins[] PROGMEM = SENSITIVE_PINS;
for (uint8_t i = 0; i < COUNT(sensitive_pins); i++)
if (pin == (int8_t)pgm_read_byte(&sensitive_pins[i])) return true;
return false;
}
#include "gcode/control/M42.h"
#if ENABLED(PINS_DEBUGGING)
#include "gcode/config/M43.h"
#endif