From 884fdf5c256f6a947a12dff35e1e3a8926a77e29 Mon Sep 17 00:00:00 2001 From: Markus Hitter Date: Sat, 3 Jul 2010 23:58:12 +0200 Subject: [PATCH] Achieve RepRap Host compatibility for temperature readouts as well. --- mendel/temp.c | 4 ++++ mendel/temp.h | 3 +++ 2 files changed, 7 insertions(+) diff --git a/mendel/temp.c b/mendel/temp.c index 913b91c..c1310b9 100644 --- a/mendel/temp.c +++ b/mendel/temp.c @@ -159,7 +159,11 @@ void temp_print() { c = (current_temp & 3) * 25; t = (target_temp & 3) * 25; + #ifdef REPRAP_HOST_COMPATIBILITY + sersendf_P(PSTR("T: %u.%u\n"), current_temp >> 2, c); + #else sersendf_P(PSTR("T: %u.%u/%u.%u :%u\n"), current_temp >> 2, c, target_temp >> 2, t, temp_residency); + #endif } } diff --git a/mendel/temp.h b/mendel/temp.h index 71902fd..44c3acd 100644 --- a/mendel/temp.h +++ b/mendel/temp.h @@ -3,6 +3,9 @@ #include +// RepRap host software isn't exactly tolerant on what it ready back. +#define REPRAP_HOST_COMPATIBILITY + // extruder heater PID factors // google "PID without a PHD" if you don't understand this PID stuff extern int32_t p_factor;