Merge upstream changes from Marlin 2.1.1

This commit is contained in:
Stefan Kalscheuer
2022-09-03 09:23:32 +02:00
parent 626283aadb
commit 986e416c7f
1610 changed files with 73839 additions and 40857 deletions

View File

@@ -19,6 +19,7 @@
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*
*/
#pragma once
#include "../inc/MarlinConfig.h"
@@ -178,7 +179,7 @@ static void print_input_or_output(const bool isout) {
}
// pretty report with PWM info
inline void report_pin_state_extended(pin_t pin, const bool ignore, const bool extended=false, PGM_P const start_string=nullptr) {
inline void report_pin_state_extended(pin_t pin, const bool ignore, const bool extended=false, FSTR_P const start_string=nullptr) {
char buffer[MAX_NAME_LENGTH + 1]; // for the sprintf statements
bool found = false, multi_name_pin = false;
@@ -202,7 +203,7 @@ inline void report_pin_state_extended(pin_t pin, const bool ignore, const bool e
LOOP_L_N(x, COUNT(pin_array)) { // scan entire array and report all instances of this pin
if (GET_ARRAY_PIN(x) == pin) {
if (!found) { // report digital and analog pin number only on the first time through
if (start_string) SERIAL_ECHOPGM_P(start_string);
if (start_string) SERIAL_ECHOF(start_string);
SERIAL_ECHOPGM("PIN: ");
PRINT_PIN(pin);
PRINT_PORT(pin);
@@ -211,7 +212,7 @@ inline void report_pin_state_extended(pin_t pin, const bool ignore, const bool e
}
else {
SERIAL_CHAR('.');
SERIAL_ECHO_SP(MULTI_NAME_PAD + (start_string ? strlen_P(start_string) : 0)); // add padding if not the first instance found
SERIAL_ECHO_SP(MULTI_NAME_PAD + (start_string ? strlen_P(FTOP(start_string)) : 0)); // add padding if not the first instance found
}
PRINT_ARRAY_NAME(x);
if (extended) {
@@ -250,7 +251,7 @@ inline void report_pin_state_extended(pin_t pin, const bool ignore, const bool e
} // end of for loop
if (!found) {
if (start_string) SERIAL_ECHOPGM_P(start_string);
if (start_string) SERIAL_ECHOF(start_string);
SERIAL_ECHOPGM("PIN: ");
PRINT_PIN(pin);
PRINT_PORT(pin);