Browse Source

removed unused HEATING_EARLY_FINISH_DEG_OFFSET

Simplified stepper inactive time
Erik van der Zalm 12 years ago
parent
commit
13e185d330
2 changed files with 9 additions and 16 deletions
  1. 1
    5
      Marlin/Configuration_adv.h
  2. 8
    11
      Marlin/Marlin.pde

+ 1
- 5
Marlin/Configuration_adv.h View File

@@ -25,9 +25,6 @@
25 25
 // if CooldownNoWait is defined M109 will not wait for the cooldown to finish
26 26
 #define CooldownNoWait true
27 27
 
28
-// Heating is finished if a temperature close to this degree shift is reached
29
-#define HEATING_EARLY_FINISH_DEG_OFFSET 1 //Degree
30
-
31 28
 //Do not wait for M109 to finish when printing from SD card
32 29
 //#define STOP_HEATING_WAIT_WHEN_SD_PRINTING
33 30
 
@@ -85,7 +82,6 @@
85 82
 
86 83
 //default stepper release if idle
87 84
 #define DEFAULT_STEPPER_DEACTIVE_TIME 60
88
-#define DEFAULT_STEPPER_DEACTIVE_COMMAND "M84 X Y E"  //z stays  powered
89 85
 
90 86
 #define DEFAULT_MINIMUMFEEDRATE       0.0     // minimum feedrate
91 87
 #define DEFAULT_MINTRAVELFEEDRATE     0.0
@@ -112,7 +108,7 @@
112 108
 
113 109
 
114 110
 #define SD_FINISHED_STEPPERRELEASE true  //if sd support and the file is finished: disable steppers?
115
-#define SD_FINISHED_RELEASECOMMAND "M84 X Y E" // no z because of layer shift.
111
+#define SD_FINISHED_RELEASECOMMAND "M84 X Y Z E" // no z because of layer shift.
116 112
 
117 113
 // The hardware watchdog should halt the Microcontroller, in case the firmware gets stuck somewhere. However:
118 114
 // the Watchdog is not working well, so please only enable this for testing

+ 8
- 11
Marlin/Marlin.pde View File

@@ -165,7 +165,6 @@ const int sensitive_pins[] = SENSITIVE_PINS; // Sensitive pin list for M42
165 165
 static unsigned long previous_millis_cmd = 0;
166 166
 static unsigned long max_inactive_time = 0;
167 167
 static unsigned long stepper_inactive_time = DEFAULT_STEPPER_DEACTIVE_TIME*1000l;
168
-static unsigned long last_stepperdisabled_time=30*1000; //first release check after 30 seconds
169 168
 
170 169
 static unsigned long starttime=0;
171 170
 static unsigned long stoptime=0;
@@ -1296,16 +1295,15 @@ void manage_inactivity(byte debug)
1296 1295
   if( (millis() - previous_millis_cmd) >  max_inactive_time ) 
1297 1296
     if(max_inactive_time) 
1298 1297
       kill(); 
1299
-  if(stepper_inactive_time)  
1300
-  if( (millis() - last_stepperdisabled_time) >  stepper_inactive_time ) 
1301
-  {
1302
-    if(previous_millis_cmd>last_stepperdisabled_time)
1303
-      last_stepperdisabled_time=previous_millis_cmd;
1304
-    else
1298
+  if(stepper_inactive_time)  {
1299
+    if( (millis() - previous_millis_cmd) >  stepper_inactive_time ) 
1305 1300
     {
1306
-      if(  (X_ENABLE_ON && (READ(X_ENABLE_PIN)!=0))  ||  (!X_ENABLE_ON && READ(X_ENABLE_PIN)==0)  )
1307
-        enquecommand(DEFAULT_STEPPER_DEACTIVE_COMMAND); 
1308
-      last_stepperdisabled_time=millis();
1301
+      disable_x();
1302
+      disable_y();
1303
+      disable_z();
1304
+      disable_e0();
1305
+      disable_e1();
1306
+      disable_e2();
1309 1307
     }
1310 1308
   }
1311 1309
   #ifdef EXTRUDER_RUNOUT_PREVENT
@@ -1323,7 +1321,6 @@ void manage_inactivity(byte debug)
1323 1321
      destination[E_AXIS]=oldedes;
1324 1322
      plan_set_e_position(oldepos);
1325 1323
      previous_millis_cmd=millis();
1326
-     //enquecommand(DEFAULT_STEPPER_DEACTIVE_COMMAND);
1327 1324
      st_synchronize();
1328 1325
      WRITE(E0_ENABLE_PIN,oldstatus);
1329 1326
     }

Loading…
Cancel
Save