summaryrefslogtreecommitdiff
path: root/Tonokip_Firmware/Tonokip_Firmware.pde
diff options
context:
space:
mode:
authorEmanuele Caruso <emanuele.caruso@gmail.com>2011-06-05 04:22:57 +0200
committerEmanuele Caruso <emanuele.caruso@gmail.com>2011-06-05 04:22:57 +0200
commit08e61b287f5cddce693a722a467bceeaadb60d2d (patch)
treec738b8d58fb2fa17d2aa0aa984e92222721260eb /Tonokip_Firmware/Tonokip_Firmware.pde
parent1139131f72f97ac5d6de72ada5030d82fc98eb9f (diff)
Added debugging code for heat management. Changed acceleration values to more reliable ones
Diffstat (limited to 'Tonokip_Firmware/Tonokip_Firmware.pde')
-rw-r--r--Tonokip_Firmware/Tonokip_Firmware.pde11
1 files changed, 10 insertions, 1 deletions
diff --git a/Tonokip_Firmware/Tonokip_Firmware.pde b/Tonokip_Firmware/Tonokip_Firmware.pde
index bf82ae3..ced29d9 100644
--- a/Tonokip_Firmware/Tonokip_Firmware.pde
+++ b/Tonokip_Firmware/Tonokip_Firmware.pde
@@ -277,6 +277,7 @@ void setup()
initsd();
#endif
+
}
@@ -1255,6 +1256,10 @@ inline void manage_heater()
previous_millis_heater = millis();
#ifdef HEATER_USES_THERMISTOR
current_raw = analogRead(TEMP_0_PIN);
+ #ifdef DEBUG_HEAT_MGMT
+ log_int("_HEAT_MGMT - analogRead(TEMP_0_PIN)", current_raw);
+ log_int("_HEAT_MGMT - NUMTEMPS", NUMTEMPS);
+ #endif
// When using thermistor, when the heater is colder than targer temp, we get a higher analog reading than target,
// this switches it up so that the reading appears lower than target for the control logic.
current_raw = 1023 - current_raw;
@@ -1317,7 +1322,11 @@ inline void manage_heater()
#ifdef BED_USES_THERMISTOR
- current_bed_raw = analogRead(TEMP_1_PIN);
+ current_bed_raw = analogRead(TEMP_1_PIN);
+ #ifdef DEBUG_HEAT_MGMT
+ log_int("_HEAT_MGMT - analogRead(TEMP_1_PIN)", current_bed_raw);
+ log_int("_HEAT_MGMT - BNUMTEMPS", BNUMTEMPS);
+ #endif
// If using thermistor, when the heater is colder than targer temp, we get a higher analog reading than target,
// this switches it up so that the reading appears lower than target for the control logic.