Browse Source

Remove set-coordinate extension of G28

Scott Lahteine 10 years ago
parent
commit
35e79d56a5
1 changed files with 1 additions and 25 deletions
  1. 1
    25
      Marlin/Marlin_main.cpp

+ 1
- 25
Marlin/Marlin_main.cpp View File

1790
  *  Y   Home to the Y endstop
1790
  *  Y   Home to the Y endstop
1791
  *  Z   Home to the Z endstop
1791
  *  Z   Home to the Z endstop
1792
  *
1792
  *
1793
- * If numbers are included with XYZ set the position as with G92
1794
- * Currently adds the home_offset, which may be wrong and removed soon.
1795
- *
1796
- *  Xn  Home X, setting X to n + home_offset[X_AXIS]
1797
- *  Yn  Home Y, setting Y to n + home_offset[Y_AXIS]
1798
- *  Zn  Home Z, setting Z to n + home_offset[Z_AXIS]
1799
  */
1793
  */
1800
 inline void gcode_G28() {
1794
 inline void gcode_G28() {
1801
 
1795
 
1855
           homeY = code_seen(axis_codes[Y_AXIS]),
1849
           homeY = code_seen(axis_codes[Y_AXIS]),
1856
           homeZ = code_seen(axis_codes[Z_AXIS]);
1850
           homeZ = code_seen(axis_codes[Z_AXIS]);
1857
 
1851
 
1858
-    home_all_axis = !(homeX || homeY || homeZ) || (homeX && homeY && homeZ);
1852
+    home_all_axis = (!homeX && !homeY && !homeZ) || (homeX && homeY && homeZ);
1859
 
1853
 
1860
     if (home_all_axis || homeZ) {
1854
     if (home_all_axis || homeZ) {
1861
 
1855
 
1942
     // Home Y
1936
     // Home Y
1943
     if (home_all_axis || homeY) HOMEAXIS(Y);
1937
     if (home_all_axis || homeY) HOMEAXIS(Y);
1944
 
1938
 
1945
-    // Set the X position, if included
1946
-    if (code_seen(axis_codes[X_AXIS]) && code_has_value()) {
1947
-      if (code_value_long() != 0) // filter 0
1948
-        current_position[X_AXIS] = code_value();
1949
-    }
1950
-
1951
-    // Set the Y position, if included
1952
-    if (code_seen(axis_codes[Y_AXIS]) && code_has_value()) {
1953
-      if (code_value_long() != 0) // filter 0
1954
-        current_position[Y_AXIS] = code_value();
1955
-    }
1956
-
1957
     // Home Z last if homing towards the bed
1939
     // Home Z last if homing towards the bed
1958
     #if Z_HOME_DIR < 0
1940
     #if Z_HOME_DIR < 0
1959
 
1941
 
2037
 
2019
 
2038
     #endif // Z_HOME_DIR < 0
2020
     #endif // Z_HOME_DIR < 0
2039
 
2021
 
2040
-    // Set the Z position, if included
2041
-    if (code_seen(axis_codes[Z_AXIS]) && code_has_value()) {
2042
-      if (code_value_long() != 0) // filter 0
2043
-        current_position[Z_AXIS] = code_value();
2044
-    }
2045
-
2046
     #if defined(ENABLE_AUTO_BED_LEVELING) && (Z_HOME_DIR < 0)
2022
     #if defined(ENABLE_AUTO_BED_LEVELING) && (Z_HOME_DIR < 0)
2047
       if (home_all_axis || homeZ) current_position[Z_AXIS] += zprobe_zoffset;  // Add Z_Probe offset (the distance is negative)
2023
       if (home_all_axis || homeZ) current_position[Z_AXIS] += zprobe_zoffset;  // Add Z_Probe offset (the distance is negative)
2048
     #endif
2024
     #endif

Loading…
Cancel
Save