Browse Source

Merge pull request #1034 from DerFlob/Marlin_v1

Fix reseting CHDK pin to LOW
Erik van der Zalm 11 years ago
parent
commit
8b52eff2c1
1 changed files with 1 additions and 2 deletions
  1. 1
    2
      Marlin/Marlin_main.cpp

+ 1
- 2
Marlin/Marlin_main.cpp View File

@@ -3516,10 +3516,9 @@ void manage_inactivity()
3516 3516
   }
3517 3517
   
3518 3518
   #ifdef CHDK //Check if pin should be set to LOW after M240 set it to HIGH
3519
-    if (chdkActive)
3519
+    if (chdkActive && (millis() - chdkHigh > CHDK_DELAY))
3520 3520
     {
3521 3521
       chdkActive = false;
3522
-      if (millis()-chdkHigh < CHDK_DELAY) return;
3523 3522
       WRITE(CHDK, LOW);
3524 3523
     }
3525 3524
   #endif

Loading…
Cancel
Save