Formatting / cleanup

2.0.x
Scott Lahteine 8 years ago
parent 29d4ec8257
commit c7a8f7970b

@ -1777,7 +1777,6 @@ static void clean_up_after_endstop_or_probe_move() {
lcd_status_printf_P(0, PSTR(MSG_HOME " %s%s%s " MSG_FIRST), xx ? MSG_X : "", yy ? MSG_Y : "", zz ? MSG_Z : ""); lcd_status_printf_P(0, PSTR(MSG_HOME " %s%s%s " MSG_FIRST), xx ? MSG_X : "", yy ? MSG_Y : "", zz ? MSG_Z : "");
#endif #endif
return true; return true;
} }
return false; return false;
} }
@ -1983,7 +1982,6 @@ static void clean_up_after_endstop_or_probe_move() {
#endif #endif
#endif #endif
#if ENABLED(BLTOUCH) #if ENABLED(BLTOUCH)
void bltouch_command(int angle) { void bltouch_command(int angle) {
servo[Z_ENDSTOP_SERVO_NR].move(angle); // Give the BL-Touch the command and wait servo[Z_ENDSTOP_SERVO_NR].move(angle); // Give the BL-Touch the command and wait
@ -2206,8 +2204,7 @@ static void clean_up_after_endstop_or_probe_move() {
// - Raise to the BETWEEN height // - Raise to the BETWEEN height
// - Return the probed Z position // - Return the probed Z position
// //
//float probe_pt(const float &x, const float &y, const bool stow = true, const int verbose_level = 1) { float probe_pt(const float x, const float y, const bool stow/*=true*/, const int verbose_level/*=1*/) {
float probe_pt(const float x, const float y, const bool stow, const int verbose_level) {
#if ENABLED(DEBUG_LEVELING_FEATURE) #if ENABLED(DEBUG_LEVELING_FEATURE)
if (DEBUGGING(LEVELING)) { if (DEBUGGING(LEVELING)) {
SERIAL_ECHOPAIR(">>> probe_pt(", x); SERIAL_ECHOPAIR(">>> probe_pt(", x);
@ -5319,7 +5316,6 @@ inline void gcode_M42() {
#include "pinsDebug.h" #include "pinsDebug.h"
inline void toggle_pins() { inline void toggle_pins() {
int pin, j, start = 0, I_flag = 0, end = NUM_DIGITAL_PINS - 1, wait = 500, repeat = 1; int pin, j, start = 0, I_flag = 0, end = NUM_DIGITAL_PINS - 1, wait = 500, repeat = 1;
@ -5481,7 +5477,6 @@ inline void gcode_M42() {
* M43 S - Servo probe test * M43 S - Servo probe test
* P<index> - Probe index (optional - defaults to 0 * P<index> - Probe index (optional - defaults to 0
*/ */
inline void gcode_M43() { inline void gcode_M43() {
if (code_seen('T')) { // must be first ot else it's "S" and "E" parameters will execute endstop or servo test if (code_seen('T')) { // must be first ot else it's "S" and "E" parameters will execute endstop or servo test
@ -5503,7 +5498,6 @@ inline void gcode_M42() {
return; return;
} }
// Get the range of pins to test or watch // Get the range of pins to test or watch
int first_pin = 0, last_pin = NUM_DIGITAL_PINS - 1; int first_pin = 0, last_pin = NUM_DIGITAL_PINS - 1;
if (code_seen('P')) { if (code_seen('P')) {
@ -5558,7 +5552,6 @@ inline void gcode_M42() {
report_pin_state_extended(pin, ignore_protection); report_pin_state_extended(pin, ignore_protection);
} }
#endif // PINS_DEBUGGING #endif // PINS_DEBUGGING
#if ENABLED(Z_MIN_PROBE_REPEATABILITY_TEST) #if ENABLED(Z_MIN_PROBE_REPEATABILITY_TEST)
@ -6041,17 +6034,18 @@ inline void gcode_M105() {
#endif #endif
#ifndef MIN_COOLING_SLOPE_DEG
#define MIN_COOLING_SLOPE_DEG 1.50
#endif
#ifndef MIN_COOLING_SLOPE_TIME
#define MIN_COOLING_SLOPE_TIME 60
#endif
/** /**
* M109: Sxxx Wait for extruder(s) to reach temperature. Waits only when heating. * M109: Sxxx Wait for extruder(s) to reach temperature. Waits only when heating.
* Rxxx Wait for extruder(s) to reach temperature. Waits when heating and cooling. * Rxxx Wait for extruder(s) to reach temperature. Waits when heating and cooling.
*/ */
#ifndef MIN_COOLING_SLOPE_DEG
#define MIN_COOLING_SLOPE_DEG 1.50
#endif
#ifndef MIN_COOLING_SLOPE_TIME
#define MIN_COOLING_SLOPE_TIME 60
#endif
inline void gcode_M109() { inline void gcode_M109() {
if (get_target_extruder_from_command(109)) return; if (get_target_extruder_from_command(109)) return;
@ -6275,11 +6269,11 @@ inline void gcode_M109() {
residency_start_ms = now; residency_start_ms = now;
} }
#endif //TEMP_BED_RESIDENCY_TIME > 0 #endif // TEMP_BED_RESIDENCY_TIME > 0
// Prevent a wait-forever situation if R is misused i.e. M190 R0 // Prevent a wait-forever situation if R is misused i.e. M190 R0
if (wants_to_cool) { if (wants_to_cool) {
// break after MIN_COOLING_SLOPE_TIME_BED seconds // Break after MIN_COOLING_SLOPE_TIME_BED seconds
// if the temperature did not drop at least MIN_COOLING_SLOPE_DEG_BED // if the temperature did not drop at least MIN_COOLING_SLOPE_DEG_BED
if (!next_cool_check_ms || ELAPSED(now, next_cool_check_ms)) { if (!next_cool_check_ms || ELAPSED(now, next_cool_check_ms)) {
if (old_temp - temp < MIN_COOLING_SLOPE_DEG_BED) break; if (old_temp - temp < MIN_COOLING_SLOPE_DEG_BED) break;
@ -6307,7 +6301,7 @@ inline void gcode_M110() {
* M111: Set the debug level * M111: Set the debug level
*/ */
inline void gcode_M111() { inline void gcode_M111() {
marlin_debug_flags = code_seen('S') ? code_value_byte() : (uint8_t) DEBUG_NONE; marlin_debug_flags = code_seen('S') ? code_value_byte() : (uint8_t)DEBUG_NONE;
const static char str_debug_1[] PROGMEM = MSG_DEBUG_ECHO; const static char str_debug_1[] PROGMEM = MSG_DEBUG_ECHO;
const static char str_debug_2[] PROGMEM = MSG_DEBUG_INFO; const static char str_debug_2[] PROGMEM = MSG_DEBUG_INFO;

Loading…
Cancel
Save