From 453cbfe55078996d8a6ebbe44bf06c90080adece Mon Sep 17 00:00:00 2001 From: AnHardt Date: Fri, 12 Jun 2015 11:22:33 +0200 Subject: [PATCH] THERMAL_RUNAWAY_PROTECTION for bed alone in Release (PR#2284) Fix for #2253 - second issue __Release__ branch!!! --- Marlin/temperature.cpp | 2 +- Marlin/temperature.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Marlin/temperature.cpp b/Marlin/temperature.cpp index 8c148ba705..0b5599fa8c 100644 --- a/Marlin/temperature.cpp +++ b/Marlin/temperature.cpp @@ -1013,7 +1013,7 @@ void setWatch() #endif } -#if defined (THERMAL_RUNAWAY_PROTECTION_PERIOD) && THERMAL_RUNAWAY_PROTECTION_PERIOD > 0 +#if (defined (THERMAL_RUNAWAY_PROTECTION_PERIOD) && THERMAL_RUNAWAY_PROTECTION_PERIOD > 0) || (defined (THERMAL_RUNAWAY_PROTECTION_BED_PERIOD) && THERMAL_RUNAWAY_PROTECTION_BED_PERIOD > 0) void thermal_runaway_protection(int *state, unsigned long *timer, float temperature, float target_temperature, int heater_id, int period_seconds, int hysteresis_degc) { /* diff --git a/Marlin/temperature.h b/Marlin/temperature.h index 95c3514890..e63910a365 100644 --- a/Marlin/temperature.h +++ b/Marlin/temperature.h @@ -162,7 +162,7 @@ void disable_heater(); void setWatch(); void updatePID(); -#if defined (THERMAL_RUNAWAY_PROTECTION_PERIOD) && THERMAL_RUNAWAY_PROTECTION_PERIOD > 0 +#if (defined (THERMAL_RUNAWAY_PROTECTION_PERIOD) && THERMAL_RUNAWAY_PROTECTION_PERIOD > 0) || (defined (THERMAL_RUNAWAY_PROTECTION_BED_PERIOD) && THERMAL_RUNAWAY_PROTECTION_BED_PERIOD > 0) void thermal_runaway_protection(int *state, unsigned long *timer, float temperature, float target_temperature, int heater_id, int period_seconds, int hysteresis_degc); static int thermal_runaway_state_machine[3]; // = {0,0,0}; static unsigned long thermal_runaway_timer[3]; // = {0,0,0};