diff options
author | kliment <kliment.yanev@gmail.com> | 2012-02-24 13:59:59 -0800 |
---|---|---|
committer | kliment <kliment.yanev@gmail.com> | 2012-02-24 13:59:59 -0800 |
commit | 0ed514e153a7fe6fa6d9810e7373798ac4088dff (patch) | |
tree | 98031e82be19065afbcc73bf98f0a6a0c17b2252 /Sprinter/heater.cpp | |
parent | 89180de4bfd598298f4d5e77889c57a250e35084 (diff) | |
parent | eb421e6a653d12221d17d3c515b0ac54010dd253 (diff) |
Merge pull request #144 from midopple/experimental
Fix Comment, Optimize, remove Unused code, fix makefile
Diffstat (limited to 'Sprinter/heater.cpp')
-rw-r--r-- | Sprinter/heater.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Sprinter/heater.cpp b/Sprinter/heater.cpp index 65f52e4..9d494b2 100644 --- a/Sprinter/heater.cpp +++ b/Sprinter/heater.cpp @@ -48,7 +48,7 @@ int current_bed_raw = 0; unsigned long previous_millis_heater, previous_millis_bed_heater, previous_millis_monitor; #ifdef PIDTEMP - int g_heater_pwm_val = 0; + volatile unsigned char g_heater_pwm_val = 0; unsigned char PWM_off_time = 0; unsigned char PWM_out_on = 0; @@ -402,7 +402,7 @@ int read_max6675() heater_duty = constrain(heater_duty, 0, HEATER_CURRENT); #ifdef PID_SOFT_PWM - g_heater_pwm_val = heater_duty; + g_heater_pwm_val = (unsigned char)heater_duty; #else analogWrite(HEATER_0_PIN, heater_duty); |