瀏覽代碼

Add DEBUG_LEVELING output for gcode_T

Scott Lahteine 9 年之前
父節點
當前提交
63d8893f5d
共有 1 個檔案被更改,包括 21 行新增0 行删除
  1. 21
    0
      Marlin/Marlin_main.cpp

+ 21
- 0
Marlin/Marlin_main.cpp 查看文件

@@ -6183,10 +6183,31 @@ inline void gcode_T(uint8_t tmp_extruder) {
6183 6183
                                                extruder_offset[Y_AXIS][active_extruder],
6184 6184
                                                extruder_offset[Z_AXIS][active_extruder]),
6185 6185
                      offset_vec = tmp_offset_vec - act_offset_vec;
6186
+
6187
+            #if ENABLED(DEBUG_LEVELING_FEATURE)
6188
+              if (DEBUGGING(LEVELING)) {
6189
+                SERIAL_ECHOLNPGM(">>> gcode_T");
6190
+                tmp_offset_vec.debug("tmp_offset_vec");
6191
+                act_offset_vec.debug("act_offset_vec");
6192
+                offset_vec.debug("offset_vec (BEFORE)");
6193
+                DEBUG_POS("BEFORE rotation", current_position);
6194
+              }
6195
+            #endif
6196
+
6186 6197
             offset_vec.apply_rotation(plan_bed_level_matrix.transpose(plan_bed_level_matrix));
6198
+
6187 6199
             current_position[X_AXIS] += offset_vec.x;
6188 6200
             current_position[Y_AXIS] += offset_vec.y;
6189 6201
             current_position[Z_AXIS] += offset_vec.z;
6202
+
6203
+            #if ENABLED(DEBUG_LEVELING_FEATURE)
6204
+              if (DEBUGGING(LEVELING)) {
6205
+                offset_vec.debug("offset_vec (AFTER)");
6206
+                DEBUG_POS("AFTER rotation", current_position);
6207
+                SERIAL_ECHOLNPGM("<<< gcode_T");
6208
+              }
6209
+            #endif
6210
+
6190 6211
           #else // !AUTO_BED_LEVELING_FEATURE
6191 6212
             // Offset extruder (only by XY)
6192 6213
             for (int i=X_AXIS; i<=Y_AXIS; i++)

Loading…
取消
儲存