summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Tonokip_Firmware/Tonokip_Firmware.pde3
1 files changed, 2 insertions, 1 deletions
diff --git a/Tonokip_Firmware/Tonokip_Firmware.pde b/Tonokip_Firmware/Tonokip_Firmware.pde
index 9615320..fcbad1d 100644
--- a/Tonokip_Firmware/Tonokip_Firmware.pde
+++ b/Tonokip_Firmware/Tonokip_Firmware.pde
@@ -658,9 +658,10 @@ inline void process_commands()
}
break;
case 106: //M106 Fan On
- if (code_seen('S'))
+ if (code_seen('S')){
digitalWrite(FAN_PIN, HIGH);
analogWrite(FAN_PIN,constrain(code_value(),0,255));
+ }
else
digitalWrite(FAN_PIN, HIGH);
break;