Ver código fonte

Corrected Z_PROBE_ALLEN_KEY behaviour.

maverikou 10 anos atrás
pai
commit
15345cc249
1 arquivos alterados com 8 adições e 2 exclusões
  1. 8
    2
      Marlin/Marlin_main.cpp

+ 8
- 2
Marlin/Marlin_main.cpp Ver arquivo

@@ -1311,8 +1311,10 @@ static void retract_z_probe() {
1311 1311
   #ifdef SERVO_ENDSTOPS
1312 1312
     if (servo_endstops[Z_AXIS] > -1)
1313 1313
     {
1314
+      #if Z_RAISE_AFTER_PROBING > 0
1314 1315
         do_blocking_move_to(current_position[X_AXIS], current_position[Y_AXIS], Z_RAISE_AFTER_PROBING);
1315 1316
         st_synchronize();
1317
+      #endif
1316 1318
     
1317 1319
       #if SERVO_LEVELING
1318 1320
         servos[servo_endstops[Z_AXIS]].attach(0);
@@ -1382,14 +1384,14 @@ static float probe_pt(float x, float y, float z_before, ProbeAction retract_acti
1382 1384
   do_blocking_move_to(current_position[X_AXIS], current_position[Y_AXIS], z_before);
1383 1385
   do_blocking_move_to(x - X_PROBE_OFFSET_FROM_EXTRUDER, y - Y_PROBE_OFFSET_FROM_EXTRUDER, current_position[Z_AXIS]);
1384 1386
 
1385
-  #if !defined(Z_PROBE_SLED)
1387
+  #if !defined(Z_PROBE_SLED) && !defined(Z_PROBE_ALLEN_KEY)
1386 1388
     if (retract_action & ProbeEngage) engage_z_probe();
1387 1389
   #endif
1388 1390
 
1389 1391
   run_z_probe();
1390 1392
   float measured_z = current_position[Z_AXIS];
1391 1393
 
1392
-  #if !defined(Z_PROBE_SLED)
1394
+  #if !defined(Z_PROBE_SLED) && !defined(Z_PROBE_ALLEN_KEY)
1393 1395
     if (retract_action & ProbeRetract) retract_z_probe();
1394 1396
   #endif
1395 1397
 
@@ -2231,6 +2233,8 @@ inline void gcode_G28() {
2231 2233
 
2232 2234
     #ifdef Z_PROBE_SLED
2233 2235
       dock_sled(false); // engage (un-dock) the probe
2236
+    #elif defined(Z_PROBE_ALLEN_KEY)
2237
+      engage_z_probe();
2234 2238
     #endif
2235 2239
 
2236 2240
     st_synchronize();
@@ -2472,6 +2476,8 @@ inline void gcode_G28() {
2472 2476
 
2473 2477
   #ifdef Z_PROBE_SLED
2474 2478
     dock_sled(true, -SLED_DOCKING_OFFSET); // dock the probe, correcting for over-travel
2479
+  #elif defined(Z_PROBE_ALLEN_KEY)
2480
+    retract_z_probe();
2475 2481
   #endif
2476 2482
     
2477 2483
   #ifdef Z_PROBE_END_SCRIPT

Carregando…
Cancelar
Salvar