🧑‍💻 M43 updates

This commit is contained in:
Scott Lahteine
2023-05-14 18:32:59 -05:00
parent b364e44716
commit d17d86d6a5
2 changed files with 15 additions and 11 deletions
+3 -3
View File
@@ -372,7 +372,7 @@ void GcodeSuite::M43() {
for (;;) {
LOOP_S_LE_N(i, first_pin, last_pin) {
pin_t pin = GET_PIN_MAP_PIN_M43(i);
const pin_t pin = GET_PIN_MAP_PIN_M43(i);
if (!VALID_PIN(pin)) continue;
if (M43_NEVER_TOUCH(i) || (!ignore_protection && pin_is_protected(pin))) continue;
const byte val =
@@ -383,7 +383,7 @@ void GcodeSuite::M43() {
//*/
extDigitalRead(pin);
if (val != pin_state[i - first_pin]) {
report_pin_state_extended(pin, ignore_protection, false);
report_pin_state_extended(pin, ignore_protection, true);
pin_state[i - first_pin] = val;
}
}
@@ -401,7 +401,7 @@ void GcodeSuite::M43() {
else {
// Report current state of selected pin(s)
LOOP_S_LE_N(i, first_pin, last_pin) {
pin_t pin = GET_PIN_MAP_PIN_M43(i);
const pin_t pin = GET_PIN_MAP_PIN_M43(i);
if (VALID_PIN(pin)) report_pin_state_extended(pin, ignore_protection, true);
}
}