Fix BLTouch debugging (#15232)
This commit is contained in:
parent
f6220addd8
commit
3b4ae17e36
2 changed files with 15 additions and 14 deletions
|
@ -2125,14 +2125,14 @@ void clean_up_after_endstop_or_probe_move() {
|
||||||
bool bltouch_deploy_proc() {
|
bool bltouch_deploy_proc() {
|
||||||
// Do a DEPLOY
|
// Do a DEPLOY
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("BLTouch DEPLOY requested");
|
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("BLTouch DEPLOY requested");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Attempt to DEPLOY, wait for DEPLOY_DELAY or ALARM
|
// Attempt to DEPLOY, wait for DEPLOY_DELAY or ALARM
|
||||||
if (_bltouch_deploy_query_alarm()) {
|
if (_bltouch_deploy_query_alarm()) {
|
||||||
// The deploy might have failed or the probe is already triggered (nozzle too low?)
|
// The deploy might have failed or the probe is already triggered (nozzle too low?)
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("BLTouch ALARM or TRIGGER after DEPLOY, recovering");
|
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("BLTouch ALARM or TRIGGER after DEPLOY, recovering");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
bltouch_clear(); // Get the probe into start condition
|
bltouch_clear(); // Get the probe into start condition
|
||||||
|
@ -2141,7 +2141,7 @@ void clean_up_after_endstop_or_probe_move() {
|
||||||
if (_bltouch_deploy_query_alarm()) {
|
if (_bltouch_deploy_query_alarm()) {
|
||||||
// The deploy might have failed or the probe is actually triggered (nozzle too low?) again
|
// The deploy might have failed or the probe is actually triggered (nozzle too low?) again
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("BLTouch Recovery Failed");
|
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("BLTouch Recovery Failed");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
SERIAL_ECHOLN(MSG_STOP_BLTOUCH); // Tell the user something is wrong, needs action
|
SERIAL_ECHOLN(MSG_STOP_BLTOUCH); // Tell the user something is wrong, needs action
|
||||||
|
@ -2160,7 +2160,7 @@ void clean_up_after_endstop_or_probe_move() {
|
||||||
// The trigger STOW (see motion.cpp for example) will pull up the probes pin as soon as the pulse
|
// The trigger STOW (see motion.cpp for example) will pull up the probes pin as soon as the pulse
|
||||||
// is registered.
|
// is registered.
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("bltouch.deploy_proc() end");
|
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("bltouch.deploy_proc() end");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return false; // report success to caller
|
return false; // report success to caller
|
||||||
|
@ -2169,7 +2169,7 @@ void clean_up_after_endstop_or_probe_move() {
|
||||||
bool bltouch_stow_proc() {
|
bool bltouch_stow_proc() {
|
||||||
// Do a STOW
|
// Do a STOW
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("BLTouch STOW requested");
|
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("BLTouch STOW requested");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// A STOW will clear a triggered condition in the probe (10ms pulse).
|
// A STOW will clear a triggered condition in the probe (10ms pulse).
|
||||||
|
@ -2182,7 +2182,7 @@ void clean_up_after_endstop_or_probe_move() {
|
||||||
if (_bltouch_stow_query_alarm()) {
|
if (_bltouch_stow_query_alarm()) {
|
||||||
// The stow might have failed
|
// The stow might have failed
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("BLTouch ALARM or TRIGGER after STOW, recovering");
|
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("BLTouch ALARM or TRIGGER after STOW, recovering");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
_bltouch_reset(); // This RESET will then also pull up the pin. If it doesn't
|
_bltouch_reset(); // This RESET will then also pull up the pin. If it doesn't
|
||||||
|
@ -2192,7 +2192,7 @@ void clean_up_after_endstop_or_probe_move() {
|
||||||
// Last attempt to STOW
|
// Last attempt to STOW
|
||||||
if (_bltouch_stow_query_alarm()) { // so if there is now STILL an ALARM condition:
|
if (_bltouch_stow_query_alarm()) { // so if there is now STILL an ALARM condition:
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("BLTouch Recovery Failed");
|
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("BLTouch Recovery Failed");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
SERIAL_ECHOLN(MSG_STOP_BLTOUCH); // Tell the user something is wrong, needs action
|
SERIAL_ECHOLN(MSG_STOP_BLTOUCH); // Tell the user something is wrong, needs action
|
||||||
|
@ -2203,7 +2203,7 @@ void clean_up_after_endstop_or_probe_move() {
|
||||||
}
|
}
|
||||||
|
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("bltouch.stow_proc() end");
|
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("bltouch.stow_proc() end");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return false; // report success to caller
|
return false; // report success to caller
|
||||||
|
@ -2216,7 +2216,7 @@ void clean_up_after_endstop_or_probe_move() {
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPAIR("BLTouch STATUS requested");
|
if (DEBUGGING(LEVELING)) SERIAL_ECHOLNPGM("BLTouch STATUS requested");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
_bltouch_set_SW_mode(); // Incidentally, _set_SW_mode() will also RESET any active alarm
|
_bltouch_set_SW_mode(); // Incidentally, _set_SW_mode() will also RESET any active alarm
|
||||||
|
@ -2279,8 +2279,8 @@ void clean_up_after_endstop_or_probe_move() {
|
||||||
#else
|
#else
|
||||||
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
||||||
if (DEBUGGING(LEVELING)) {
|
if (DEBUGGING(LEVELING)) {
|
||||||
DEBUG_ECHOLNPAIR("last_written_mode - ", (int)bltouch_last_written_mode);
|
SERIAL_ECHOPAIR("last_written_mode - ", int(bltouch_last_written_mode));
|
||||||
DEBUG_ECHOLNPGM("config mode - "
|
SERIAL_ECHOLNPGM("config mode - "
|
||||||
#if ENABLED(BLTOUCH_SET_5V_MODE)
|
#if ENABLED(BLTOUCH_SET_5V_MODE)
|
||||||
"BLTOUCH_SET_5V_MODE"
|
"BLTOUCH_SET_5V_MODE"
|
||||||
#else
|
#else
|
||||||
|
|
|
@ -972,12 +972,13 @@ void lcd_quick_feedback(const bool clear_buttons) {
|
||||||
#if ENABLED(BLTOUCH_LCD_VOLTAGE_MENU)
|
#if ENABLED(BLTOUCH_LCD_VOLTAGE_MENU)
|
||||||
void bltouch_report() {
|
void bltouch_report() {
|
||||||
SERIAL_ECHOLNPAIR("EEPROM Last BLTouch Mode - ", (int)bltouch_last_written_mode);
|
SERIAL_ECHOLNPAIR("EEPROM Last BLTouch Mode - ", (int)bltouch_last_written_mode);
|
||||||
SERIAL_ECHOPGM("Configuration BLTouch Mode - ");
|
SERIAL_ECHOLNPGM("Configuration BLTouch Mode - "
|
||||||
#if ENABLED(BLTOUCH_SET_5V_MODE)
|
#if ENABLED(BLTOUCH_SET_5V_MODE)
|
||||||
SERIAL_ECHOLNPGM("5V");
|
"5V"
|
||||||
#else
|
#else
|
||||||
SERIAL_ECHOLNPGM("OD");
|
"OD"
|
||||||
#endif
|
#endif
|
||||||
|
);
|
||||||
char mess[21];
|
char mess[21];
|
||||||
strcpy_P(mess, PSTR("BLTouch Mode - "));
|
strcpy_P(mess, PSTR("BLTouch Mode - "));
|
||||||
strcpy_P(&mess[15], bltouch_last_written_mode ? PSTR("5V") : PSTR("OD"));
|
strcpy_P(&mess[15], bltouch_last_written_mode ? PSTR("5V") : PSTR("OD"));
|
||||||
|
|
Loading…
Reference in a new issue