From 58f467825361ea657beab91ee871a617a5260688 Mon Sep 17 00:00:00 2001 From: Markus Hitter Date: Tue, 30 Aug 2011 11:54:38 +0200 Subject: [PATCH] Catch by RobertFach: compatibility option for RepRap Host 20110509. --- config.gen3.h | 3 ++- config.gen6.h | 3 ++- config.h.dist | 3 ++- config.ramps-v1.2.h | 3 ++- config.ramps-v1.3.h | 3 ++- temp.c | 6 +++++- 6 files changed, 15 insertions(+), 6 deletions(-) diff --git a/config.gen3.h b/config.gen3.h index 15a192b..2d6bbf2 100644 --- a/config.gen3.h +++ b/config.gen3.h @@ -342,7 +342,8 @@ DEFINE_TEMP_SENSOR(bed, TT_INTERCOM, 1, 0) Undefine it for best human readability, set it to an old date for compatibility with hosts before August 2010 */ // #define REPRAP_HOST_COMPATIBILITY 19750101 -#define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20110509 // #define REPRAP_HOST_COMPATIBILITY /** diff --git a/config.gen6.h b/config.gen6.h index f344b5e..24a940e 100644 --- a/config.gen6.h +++ b/config.gen6.h @@ -320,7 +320,8 @@ DEFINE_HEATER(extruder, PD6) Undefine it for best human readability, set it to an old date for compatibility with hosts before August 2010 */ // #define REPRAP_HOST_COMPATIBILITY 19750101 -#define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20110509 // #define REPRAP_HOST_COMPATIBILITY /** diff --git a/config.h.dist b/config.h.dist index 2a6cf15..a299510 100644 --- a/config.h.dist +++ b/config.h.dist @@ -327,7 +327,8 @@ DEFINE_HEATER(bed, PB4) Undefine it for best human readability, set it to an old date for compatibility with hosts before August 2010 */ // #define REPRAP_HOST_COMPATIBILITY 19750101 -#define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20110509 // #define REPRAP_HOST_COMPATIBILITY /** diff --git a/config.ramps-v1.2.h b/config.ramps-v1.2.h index 781ae93..ece327b 100644 --- a/config.ramps-v1.2.h +++ b/config.ramps-v1.2.h @@ -334,7 +334,8 @@ DEFINE_HEATER(fan, PH6) Undefine it for best human readability, set it to an old date for compatibility with hosts before August 2010 */ // #define REPRAP_HOST_COMPATIBILITY 19750101 -#define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20110509 // #define REPRAP_HOST_COMPATIBILITY /** diff --git a/config.ramps-v1.3.h b/config.ramps-v1.3.h index cbb1457..e67e289 100644 --- a/config.ramps-v1.3.h +++ b/config.ramps-v1.3.h @@ -335,7 +335,8 @@ DEFINE_HEATER( extruder, PB4) Undefine it for best human readability, set it to an old date for compatibility with hosts before August 2010 */ // #define REPRAP_HOST_COMPATIBILITY 19750101 -#define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20100806 +// #define REPRAP_HOST_COMPATIBILITY 20110509 // #define REPRAP_HOST_COMPATIBILITY /** diff --git a/temp.c b/temp.c index b32b91b..99553bc 100644 --- a/temp.c +++ b/temp.c @@ -349,7 +349,11 @@ void temp_print(temp_sensor_t index) { c = (temp_sensors_runtime[index].last_read_temp & 3) * 25; - sersendf_P(PSTR("\nT:%u.%u"), temp_sensors_runtime[index].last_read_temp >> 2, c); + #if REPRAP_HOST_COMPATIBILITY >= 20110509 + sersendf_P(PSTR("T:%u.%u"), temp_sensors_runtime[index].last_read_temp >> 2, c); + #else + sersendf_P(PSTR("\nT:%u.%u"), temp_sensors_runtime[index].last_read_temp >> 2, c); + #endif #ifdef HEATER_BED uint8_t b = 0; b = (temp_sensors_runtime[HEATER_BED].last_read_temp & 3) * 25;