diff options
author | condac <burns.nu@gmail.com> | 2011-09-04 11:49:14 +0300 |
---|---|---|
committer | condac <burns.nu@gmail.com> | 2011-09-04 11:49:14 +0300 |
commit | 66288464faf1dea592cdea360bcbb830ef017058 (patch) | |
tree | 257ef93003f6ae567b08f26a242df2e3f9c9e50a | |
parent | 731907b880e57d209d26646ef7efb55d3ec04643 (diff) |
New and improved On and Off for FAN_PIN
-rw-r--r-- | Sprinter/Sprinter.pde | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/Sprinter/Sprinter.pde b/Sprinter/Sprinter.pde index 364393e..857d652 100644 --- a/Sprinter/Sprinter.pde +++ b/Sprinter/Sprinter.pde @@ -808,16 +808,14 @@ inline void process_commands() WRITE(FAN_PIN, HIGH); analogWrite(FAN_PIN, constrain(code_value(),0,255) ); } - else + else { WRITE(FAN_PIN, HIGH); + analogWrite(FAN_PIN, 255 ); + } break; case 107: //M107 Fan Off - if (code_seen('S')){ analogWrite(FAN_PIN, 0); - } - else { - WRITE(FAN_PIN, LOW); - } + WRITE(FAN_PIN, LOW); break; #endif #if (PS_ON_PIN > -1) |