Sfoglia il codice sorgente

Rename options with swap_ prefix

Scott Lahteine 6 anni fa
parent
commit
4eff18854b

+ 2
- 2
Marlin/Marlin.h Vedi File

@@ -389,8 +389,8 @@ extern float soft_endstop_min[XYZ], soft_endstop_max[XYZ];
389 389
                retract_zlift,                      // M207 Z - G10 Retract hop size
390 390
                retract_recover_length,             // M208 S - G11 Recover length
391 391
                retract_recover_feedrate_mm_s,      // M208 F - G11 Recover feedrate
392
-               retract_length_swap,                // M207 W - G10 Swap Retract length
393
-               retract_recover_length_swap,        // M208 W - G11 Swap Recover length
392
+               swap_retract_length,                // M207 W - G10 Swap Retract length
393
+               swap_retract_recover_length,        // M208 W - G11 Swap Recover length
394 394
                swap_retract_recover_feedrate_mm_s; // M208 R - G11 Swap Recover feedrate
395 395
 #endif
396 396
 

+ 8
- 8
Marlin/Marlin_main.cpp Vedi File

@@ -565,8 +565,8 @@ static uint8_t target_extruder;
565 565
         retract_zlift,                      // M207 Z - G10 Retract hop size
566 566
         retract_recover_length,             // M208 S - G11 Recover length
567 567
         retract_recover_feedrate_mm_s,      // M208 F - G11 Recover feedrate
568
-        retract_length_swap,                // M207 W - G10 Swap Retract length
569
-        retract_recover_length_swap,        // M208 W - G11 Swap Recover length
568
+        swap_retract_length,                // M207 W - G10 Swap Retract length
569
+        swap_retract_recover_length,        // M208 W - G11 Swap Recover length
570 570
         swap_retract_recover_feedrate_mm_s; // M208 R - G11 Swap Recover feedrate
571 571
   #if EXTRUDERS > 1
572 572
     bool retracted_swap[EXTRUDERS] = { false }; // Which extruders are swap-retracted
@@ -3165,7 +3165,7 @@ static void homeaxis(const AxisEnum axis) {
3165 3165
 
3166 3166
       // Retract by moving from a faux E position back to the current E position
3167 3167
       feedrate_mm_s = retract_feedrate_mm_s;
3168
-      current_position[E_AXIS] += (swapping ? retract_length_swap : retract_length) / volumetric_multiplier[active_extruder];
3168
+      current_position[E_AXIS] += (swapping ? swap_retract_length : retract_length) / volumetric_multiplier[active_extruder];
3169 3169
       sync_plan_position_e();
3170 3170
       prepare_move_to_destination();
3171 3171
 
@@ -3189,7 +3189,7 @@ static void homeaxis(const AxisEnum axis) {
3189 3189
       // A retract multiplier has been added here to get faster swap recovery
3190 3190
       feedrate_mm_s = swapping ? swap_retract_recover_feedrate_mm_s : retract_recover_feedrate_mm_s;
3191 3191
 
3192
-      const float move_e = swapping ? retract_length_swap + retract_recover_length_swap : retract_length + retract_recover_length;
3192
+      const float move_e = swapping ? swap_retract_length + swap_retract_recover_length : retract_length + retract_recover_length;
3193 3193
       current_position[E_AXIS] -= move_e / volumetric_multiplier[active_extruder];
3194 3194
       sync_plan_position_e();
3195 3195
 
@@ -8554,7 +8554,7 @@ inline void gcode_M205() {
8554 8554
    * M207: Set firmware retraction values
8555 8555
    *
8556 8556
    *   S[+units]    retract_length
8557
-   *   W[+units]    retract_length_swap (multi-extruder)
8557
+   *   W[+units]    swap_retract_length (multi-extruder)
8558 8558
    *   F[units/min] retract_feedrate_mm_s
8559 8559
    *   Z[units]     retract_zlift
8560 8560
    */
@@ -8562,14 +8562,14 @@ inline void gcode_M205() {
8562 8562
     if (parser.seen('S')) retract_length = parser.value_axis_units(E_AXIS);
8563 8563
     if (parser.seen('F')) retract_feedrate_mm_s = MMM_TO_MMS(parser.value_axis_units(E_AXIS));
8564 8564
     if (parser.seen('Z')) retract_zlift = parser.value_linear_units();
8565
-    if (parser.seen('W')) retract_length_swap = parser.value_axis_units(E_AXIS);
8565
+    if (parser.seen('W')) swap_retract_length = parser.value_axis_units(E_AXIS);
8566 8566
   }
8567 8567
 
8568 8568
   /**
8569 8569
    * M208: Set firmware un-retraction values
8570 8570
    *
8571 8571
    *   S[+units]    retract_recover_length (in addition to M207 S*)
8572
-   *   W[+units]    retract_recover_length_swap (multi-extruder)
8572
+   *   W[+units]    swap_retract_recover_length (multi-extruder)
8573 8573
    *   F[units/min] retract_recover_feedrate_mm_s
8574 8574
    *   R[units/min] swap_retract_recover_feedrate_mm_s
8575 8575
    */
@@ -8577,7 +8577,7 @@ inline void gcode_M205() {
8577 8577
     if (parser.seen('S')) retract_recover_length = parser.value_axis_units(E_AXIS);
8578 8578
     if (parser.seen('F')) retract_recover_feedrate_mm_s = MMM_TO_MMS(parser.value_axis_units(E_AXIS));
8579 8579
     if (parser.seen('R')) swap_retract_recover_feedrate_mm_s = MMM_TO_MMS(parser.value_axis_units(E_AXIS));
8580
-    if (parser.seen('W')) retract_recover_length_swap = parser.value_axis_units(E_AXIS);
8580
+    if (parser.seen('W')) swap_retract_recover_length = parser.value_axis_units(E_AXIS);
8581 8581
   }
8582 8582
 
8583 8583
   /**

+ 12
- 12
Marlin/configuration_store.cpp Vedi File

@@ -132,8 +132,8 @@
132 132
  *  513  M207 Z    retract_zlift                    (float)
133 133
  *  517  M208 S    retract_recover_length           (float)
134 134
  *  521  M208 F    retract_recover_feedrate_mm_s    (float)
135
- *  525  M207 W    retract_length_swap              (float)
136
- *  529  M208 W    retract_recover_length_swap      (float)
135
+ *  525  M207 W    swap_retract_length              (float)
136
+ *  529  M208 W    swap_retract_recover_length      (float)
137 137
  *  533  M208 R    swap_retract_recover_feedrate_mm_s (float)
138 138
  *
139 139
  * Volumetric Extrusion:                            21 bytes
@@ -528,8 +528,8 @@ void MarlinSettings::postprocess() {
528 528
                   retract_zlift = 0,
529 529
                   retract_recover_length = 0,
530 530
                   retract_recover_feedrate_mm_s = 0,
531
-                  retract_length_swap = 13,
532
-                  retract_recover_length_swap = 0,
531
+                  swap_retract_length = 13,
532
+                  swap_retract_recover_length = 0,
533 533
                   swap_retract_recover_feedrate_mm_s = 8;
534 534
     #endif
535 535
     EEPROM_WRITE(autoretract_enabled);
@@ -538,8 +538,8 @@ void MarlinSettings::postprocess() {
538 538
     EEPROM_WRITE(retract_zlift);
539 539
     EEPROM_WRITE(retract_recover_length);
540 540
     EEPROM_WRITE(retract_recover_feedrate_mm_s);
541
-    EEPROM_WRITE(retract_length_swap);
542
-    EEPROM_WRITE(retract_recover_length_swap);
541
+    EEPROM_WRITE(swap_retract_length);
542
+    EEPROM_WRITE(swap_retract_recover_length);
543 543
     EEPROM_WRITE(swap_retract_recover_feedrate_mm_s);
544 544
 
545 545
     EEPROM_WRITE(volumetric_enabled);
@@ -920,8 +920,8 @@ void MarlinSettings::postprocess() {
920 920
         EEPROM_READ(retract_zlift);
921 921
         EEPROM_READ(retract_recover_length);
922 922
         EEPROM_READ(retract_recover_feedrate_mm_s);
923
-        EEPROM_READ(retract_length_swap);
924
-        EEPROM_READ(retract_recover_length_swap);
923
+        EEPROM_READ(swap_retract_length);
924
+        EEPROM_READ(swap_retract_recover_length);
925 925
         EEPROM_READ(swap_retract_recover_feedrate_mm_s);
926 926
       #else
927 927
         EEPROM_READ(dummyb);
@@ -1292,8 +1292,8 @@ void MarlinSettings::reset() {
1292 1292
     retract_zlift = RETRACT_ZLIFT;
1293 1293
     retract_recover_length = RETRACT_RECOVER_LENGTH;
1294 1294
     retract_recover_feedrate_mm_s = RETRACT_RECOVER_FEEDRATE;
1295
-    retract_length_swap = RETRACT_LENGTH_SWAP;
1296
-    retract_recover_length_swap = RETRACT_RECOVER_LENGTH_SWAP;
1295
+    swap_retract_length = RETRACT_LENGTH_SWAP;
1296
+    swap_retract_recover_length = RETRACT_RECOVER_LENGTH_SWAP;
1297 1297
     swap_retract_recover_feedrate_mm_s = RETRACT_RECOVER_FEEDRATE_SWAP;
1298 1298
   #endif // FWRETRACT
1299 1299
 
@@ -1747,7 +1747,7 @@ void MarlinSettings::reset() {
1747 1747
       }
1748 1748
       CONFIG_ECHO_START;
1749 1749
       SERIAL_ECHOPAIR("  M207 S", LINEAR_UNIT(retract_length));
1750
-      SERIAL_ECHOPAIR(" W", LINEAR_UNIT(retract_length_swap));
1750
+      SERIAL_ECHOPAIR(" W", LINEAR_UNIT(swap_retract_length));
1751 1751
       SERIAL_ECHOPAIR(" F", MMS_TO_MMM(LINEAR_UNIT(retract_feedrate_mm_s)));
1752 1752
       SERIAL_ECHOLNPAIR(" Z", LINEAR_UNIT(retract_zlift));
1753 1753
 
@@ -1757,7 +1757,7 @@ void MarlinSettings::reset() {
1757 1757
       }
1758 1758
       CONFIG_ECHO_START;
1759 1759
       SERIAL_ECHOPAIR("  M208 S", LINEAR_UNIT(retract_recover_length));
1760
-      SERIAL_ECHOPAIR(" W", LINEAR_UNIT(retract_recover_length_swap));
1760
+      SERIAL_ECHOPAIR(" W", LINEAR_UNIT(swap_retract_recover_length));
1761 1761
       SERIAL_ECHOLNPAIR(" F", MMS_TO_MMM(LINEAR_UNIT(retract_recover_feedrate_mm_s)));
1762 1762
 
1763 1763
       if (!forReplay) {

+ 2
- 2
Marlin/language_zh_CN.h Vedi File

@@ -134,11 +134,11 @@
134 134
 #define MSG_KILLED                          _UxGT("已杀掉")  //"KILLED. "
135 135
 #define MSG_STOPPED                         _UxGT("已停止")  //"STOPPED. "
136 136
 #define MSG_CONTROL_RETRACT                 _UxGT("回抽长度mm")  //"Retract mm" retract_length, retract length (positive mm)
137
-#define MSG_CONTROL_RETRACT_SWAP            _UxGT("换手回抽长度mm")  //"Swap Re.mm" retract_length_swap, swap retract length (positive mm), for extruder change
137
+#define MSG_CONTROL_RETRACT_SWAP            _UxGT("换手回抽长度mm")  //"Swap Re.mm" swap_retract_length, swap retract length (positive mm), for extruder change
138 138
 #define MSG_CONTROL_RETRACTF                _UxGT("回抽速率mm/s")  //"Retract  V" retract_feedrate_mm_s, feedrate for retracting (mm/s)
139 139
 #define MSG_CONTROL_RETRACT_ZLIFT           _UxGT("Hop mm")  //"Hop mm" retract_zlift, retract Z-lift
140 140
 #define MSG_CONTROL_RETRACT_RECOVER         _UxGT("回抽恢复长度mm")  //"UnRet +mm" retract_recover_length, additional recover length (mm, added to retract length when recovering)
141
-#define MSG_CONTROL_RETRACT_RECOVER_SWAP    _UxGT("换手回抽恢复长度mm")  //"S UnRet+mm" retract_recover_length_swap, additional swap recover length (mm, added to retract length when recovering from extruder change)
141
+#define MSG_CONTROL_RETRACT_RECOVER_SWAP    _UxGT("换手回抽恢复长度mm")  //"S UnRet+mm" swap_retract_recover_length, additional swap recover length (mm, added to retract length when recovering from extruder change)
142 142
 #define MSG_CONTROL_RETRACT_RECOVERF        _UxGT("回抽恢复后进料速率mm/s")  //"UnRet  V" retract_recover_feedrate_mm_s, feedrate for recovering from retraction (mm/s)
143 143
 #define MSG_AUTORETRACT                     _UxGT("自动抽回")  //"AutoRetr." autoretract_enabled,
144 144
 #define MSG_FILAMENTCHANGE                  _UxGT("更换丝料")  //"Change filament"

+ 2
- 2
Marlin/language_zh_TW.h Vedi File

@@ -134,11 +134,11 @@
134 134
 #define MSG_KILLED                          _UxGT("已殺掉")  //"KILLED. "
135 135
 #define MSG_STOPPED                         _UxGT("已停止")  //"STOPPED. "
136 136
 #define MSG_CONTROL_RETRACT                 _UxGT("回抽長度mm")  //"Retract mm" retract_length, retract length (positive mm)
137
-#define MSG_CONTROL_RETRACT_SWAP            _UxGT("換手回抽長度mm")  //"Swap Re.mm" retract_length_swap, swap retract length (positive mm), for extruder change
137
+#define MSG_CONTROL_RETRACT_SWAP            _UxGT("換手回抽長度mm")  //"Swap Re.mm" swap_retract_length, swap retract length (positive mm), for extruder change
138 138
 #define MSG_CONTROL_RETRACTF                _UxGT("回抽速率mm/s")  //"Retract  V" retract_feedrate_mm_s, feedrate for retracting (mm/s)
139 139
 #define MSG_CONTROL_RETRACT_ZLIFT           _UxGT("Hop mm")  //"Hop mm" retract_zlift, retract Z-lift
140 140
 #define MSG_CONTROL_RETRACT_RECOVER         _UxGT("回抽恢複長度mm")  //"UnRet +mm" retract_recover_length, additional recover length (mm, added to retract length when recovering)
141
-#define MSG_CONTROL_RETRACT_RECOVER_SWAP    _UxGT("換手回抽恢複長度mm")  //"S UnRet+mm" retract_recover_length_swap, additional swap recover length (mm, added to retract length when recovering from extruder change)
141
+#define MSG_CONTROL_RETRACT_RECOVER_SWAP    _UxGT("換手回抽恢複長度mm")  //"S UnRet+mm" swap_retract_recover_length, additional swap recover length (mm, added to retract length when recovering from extruder change)
142 142
 #define MSG_CONTROL_RETRACT_RECOVERF        _UxGT("回抽恢複後進料速率mm/s")  //"UnRet  V" retract_recover_feedrate_mm_s, feedrate for recovering from retraction (mm/s)
143 143
 #define MSG_AUTORETRACT                     _UxGT("自動抽回")  //"AutoRetr." autoretract_enabled,
144 144
 #define MSG_FILAMENTCHANGE                  _UxGT("更換絲料")  //"Change filament"

+ 2
- 2
Marlin/ultralcd.cpp Vedi File

@@ -3373,13 +3373,13 @@ void kill_screen(const char* lcd_msg) {
3373 3373
       MENU_ITEM_EDIT(bool, MSG_AUTORETRACT, &autoretract_enabled);
3374 3374
       MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT, &retract_length, 0, 100);
3375 3375
       #if EXTRUDERS > 1
3376
-        MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_SWAP, &retract_length_swap, 0, 100);
3376
+        MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_SWAP, &swap_retract_length, 0, 100);
3377 3377
       #endif
3378 3378
       MENU_ITEM_EDIT(float3, MSG_CONTROL_RETRACTF, &retract_feedrate_mm_s, 1, 999);
3379 3379
       MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_ZLIFT, &retract_zlift, 0, 999);
3380 3380
       MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_RECOVER, &retract_recover_length, -100, 100);
3381 3381
       #if EXTRUDERS > 1
3382
-        MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_RECOVER_SWAP, &retract_recover_length_swap, -100, 100);
3382
+        MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_RECOVER_SWAP, &swap_retract_recover_length, -100, 100);
3383 3383
       #endif
3384 3384
       MENU_ITEM_EDIT(float3, MSG_CONTROL_RETRACT_RECOVERF, &retract_recover_feedrate_mm_s, 1, 999);
3385 3385
       END_MENU();

Loading…
Annulla
Salva