Browse Source

Rename options with swap_ prefix

Scott Lahteine 8 years ago
parent
commit
4eff18854b

+ 2
- 2
Marlin/Marlin.h View File

389
                retract_zlift,                      // M207 Z - G10 Retract hop size
389
                retract_zlift,                      // M207 Z - G10 Retract hop size
390
                retract_recover_length,             // M208 S - G11 Recover length
390
                retract_recover_length,             // M208 S - G11 Recover length
391
                retract_recover_feedrate_mm_s,      // M208 F - G11 Recover feedrate
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
                swap_retract_recover_feedrate_mm_s; // M208 R - G11 Swap Recover feedrate
394
                swap_retract_recover_feedrate_mm_s; // M208 R - G11 Swap Recover feedrate
395
 #endif
395
 #endif
396
 
396
 

+ 8
- 8
Marlin/Marlin_main.cpp View File

565
         retract_zlift,                      // M207 Z - G10 Retract hop size
565
         retract_zlift,                      // M207 Z - G10 Retract hop size
566
         retract_recover_length,             // M208 S - G11 Recover length
566
         retract_recover_length,             // M208 S - G11 Recover length
567
         retract_recover_feedrate_mm_s,      // M208 F - G11 Recover feedrate
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
         swap_retract_recover_feedrate_mm_s; // M208 R - G11 Swap Recover feedrate
570
         swap_retract_recover_feedrate_mm_s; // M208 R - G11 Swap Recover feedrate
571
   #if EXTRUDERS > 1
571
   #if EXTRUDERS > 1
572
     bool retracted_swap[EXTRUDERS] = { false }; // Which extruders are swap-retracted
572
     bool retracted_swap[EXTRUDERS] = { false }; // Which extruders are swap-retracted
3165
 
3165
 
3166
       // Retract by moving from a faux E position back to the current E position
3166
       // Retract by moving from a faux E position back to the current E position
3167
       feedrate_mm_s = retract_feedrate_mm_s;
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
       sync_plan_position_e();
3169
       sync_plan_position_e();
3170
       prepare_move_to_destination();
3170
       prepare_move_to_destination();
3171
 
3171
 
3189
       // A retract multiplier has been added here to get faster swap recovery
3189
       // A retract multiplier has been added here to get faster swap recovery
3190
       feedrate_mm_s = swapping ? swap_retract_recover_feedrate_mm_s : retract_recover_feedrate_mm_s;
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
       current_position[E_AXIS] -= move_e / volumetric_multiplier[active_extruder];
3193
       current_position[E_AXIS] -= move_e / volumetric_multiplier[active_extruder];
3194
       sync_plan_position_e();
3194
       sync_plan_position_e();
3195
 
3195
 
8554
    * M207: Set firmware retraction values
8554
    * M207: Set firmware retraction values
8555
    *
8555
    *
8556
    *   S[+units]    retract_length
8556
    *   S[+units]    retract_length
8557
-   *   W[+units]    retract_length_swap (multi-extruder)
8557
+   *   W[+units]    swap_retract_length (multi-extruder)
8558
    *   F[units/min] retract_feedrate_mm_s
8558
    *   F[units/min] retract_feedrate_mm_s
8559
    *   Z[units]     retract_zlift
8559
    *   Z[units]     retract_zlift
8560
    */
8560
    */
8562
     if (parser.seen('S')) retract_length = parser.value_axis_units(E_AXIS);
8562
     if (parser.seen('S')) retract_length = parser.value_axis_units(E_AXIS);
8563
     if (parser.seen('F')) retract_feedrate_mm_s = MMM_TO_MMS(parser.value_axis_units(E_AXIS));
8563
     if (parser.seen('F')) retract_feedrate_mm_s = MMM_TO_MMS(parser.value_axis_units(E_AXIS));
8564
     if (parser.seen('Z')) retract_zlift = parser.value_linear_units();
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
    * M208: Set firmware un-retraction values
8569
    * M208: Set firmware un-retraction values
8570
    *
8570
    *
8571
    *   S[+units]    retract_recover_length (in addition to M207 S*)
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
    *   F[units/min] retract_recover_feedrate_mm_s
8573
    *   F[units/min] retract_recover_feedrate_mm_s
8574
    *   R[units/min] swap_retract_recover_feedrate_mm_s
8574
    *   R[units/min] swap_retract_recover_feedrate_mm_s
8575
    */
8575
    */
8577
     if (parser.seen('S')) retract_recover_length = parser.value_axis_units(E_AXIS);
8577
     if (parser.seen('S')) retract_recover_length = parser.value_axis_units(E_AXIS);
8578
     if (parser.seen('F')) retract_recover_feedrate_mm_s = MMM_TO_MMS(parser.value_axis_units(E_AXIS));
8578
     if (parser.seen('F')) retract_recover_feedrate_mm_s = MMM_TO_MMS(parser.value_axis_units(E_AXIS));
8579
     if (parser.seen('R')) swap_retract_recover_feedrate_mm_s = MMM_TO_MMS(parser.value_axis_units(E_AXIS));
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 View File

132
  *  513  M207 Z    retract_zlift                    (float)
132
  *  513  M207 Z    retract_zlift                    (float)
133
  *  517  M208 S    retract_recover_length           (float)
133
  *  517  M208 S    retract_recover_length           (float)
134
  *  521  M208 F    retract_recover_feedrate_mm_s    (float)
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
  *  533  M208 R    swap_retract_recover_feedrate_mm_s (float)
137
  *  533  M208 R    swap_retract_recover_feedrate_mm_s (float)
138
  *
138
  *
139
  * Volumetric Extrusion:                            21 bytes
139
  * Volumetric Extrusion:                            21 bytes
528
                   retract_zlift = 0,
528
                   retract_zlift = 0,
529
                   retract_recover_length = 0,
529
                   retract_recover_length = 0,
530
                   retract_recover_feedrate_mm_s = 0,
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
                   swap_retract_recover_feedrate_mm_s = 8;
533
                   swap_retract_recover_feedrate_mm_s = 8;
534
     #endif
534
     #endif
535
     EEPROM_WRITE(autoretract_enabled);
535
     EEPROM_WRITE(autoretract_enabled);
538
     EEPROM_WRITE(retract_zlift);
538
     EEPROM_WRITE(retract_zlift);
539
     EEPROM_WRITE(retract_recover_length);
539
     EEPROM_WRITE(retract_recover_length);
540
     EEPROM_WRITE(retract_recover_feedrate_mm_s);
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
     EEPROM_WRITE(swap_retract_recover_feedrate_mm_s);
543
     EEPROM_WRITE(swap_retract_recover_feedrate_mm_s);
544
 
544
 
545
     EEPROM_WRITE(volumetric_enabled);
545
     EEPROM_WRITE(volumetric_enabled);
920
         EEPROM_READ(retract_zlift);
920
         EEPROM_READ(retract_zlift);
921
         EEPROM_READ(retract_recover_length);
921
         EEPROM_READ(retract_recover_length);
922
         EEPROM_READ(retract_recover_feedrate_mm_s);
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
         EEPROM_READ(swap_retract_recover_feedrate_mm_s);
925
         EEPROM_READ(swap_retract_recover_feedrate_mm_s);
926
       #else
926
       #else
927
         EEPROM_READ(dummyb);
927
         EEPROM_READ(dummyb);
1292
     retract_zlift = RETRACT_ZLIFT;
1292
     retract_zlift = RETRACT_ZLIFT;
1293
     retract_recover_length = RETRACT_RECOVER_LENGTH;
1293
     retract_recover_length = RETRACT_RECOVER_LENGTH;
1294
     retract_recover_feedrate_mm_s = RETRACT_RECOVER_FEEDRATE;
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
     swap_retract_recover_feedrate_mm_s = RETRACT_RECOVER_FEEDRATE_SWAP;
1297
     swap_retract_recover_feedrate_mm_s = RETRACT_RECOVER_FEEDRATE_SWAP;
1298
   #endif // FWRETRACT
1298
   #endif // FWRETRACT
1299
 
1299
 
1747
       }
1747
       }
1748
       CONFIG_ECHO_START;
1748
       CONFIG_ECHO_START;
1749
       SERIAL_ECHOPAIR("  M207 S", LINEAR_UNIT(retract_length));
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
       SERIAL_ECHOPAIR(" F", MMS_TO_MMM(LINEAR_UNIT(retract_feedrate_mm_s)));
1751
       SERIAL_ECHOPAIR(" F", MMS_TO_MMM(LINEAR_UNIT(retract_feedrate_mm_s)));
1752
       SERIAL_ECHOLNPAIR(" Z", LINEAR_UNIT(retract_zlift));
1752
       SERIAL_ECHOLNPAIR(" Z", LINEAR_UNIT(retract_zlift));
1753
 
1753
 
1757
       }
1757
       }
1758
       CONFIG_ECHO_START;
1758
       CONFIG_ECHO_START;
1759
       SERIAL_ECHOPAIR("  M208 S", LINEAR_UNIT(retract_recover_length));
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
       SERIAL_ECHOLNPAIR(" F", MMS_TO_MMM(LINEAR_UNIT(retract_recover_feedrate_mm_s)));
1761
       SERIAL_ECHOLNPAIR(" F", MMS_TO_MMM(LINEAR_UNIT(retract_recover_feedrate_mm_s)));
1762
 
1762
 
1763
       if (!forReplay) {
1763
       if (!forReplay) {

+ 2
- 2
Marlin/language_zh_CN.h View File

134
 #define MSG_KILLED                          _UxGT("已杀掉")  //"KILLED. "
134
 #define MSG_KILLED                          _UxGT("已杀掉")  //"KILLED. "
135
 #define MSG_STOPPED                         _UxGT("已停止")  //"STOPPED. "
135
 #define MSG_STOPPED                         _UxGT("已停止")  //"STOPPED. "
136
 #define MSG_CONTROL_RETRACT                 _UxGT("回抽长度mm")  //"Retract mm" retract_length, retract length (positive mm)
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
 #define MSG_CONTROL_RETRACTF                _UxGT("回抽速率mm/s")  //"Retract  V" retract_feedrate_mm_s, feedrate for retracting (mm/s)
138
 #define MSG_CONTROL_RETRACTF                _UxGT("回抽速率mm/s")  //"Retract  V" retract_feedrate_mm_s, feedrate for retracting (mm/s)
139
 #define MSG_CONTROL_RETRACT_ZLIFT           _UxGT("Hop mm")  //"Hop mm" retract_zlift, retract Z-lift
139
 #define MSG_CONTROL_RETRACT_ZLIFT           _UxGT("Hop mm")  //"Hop mm" retract_zlift, retract Z-lift
140
 #define MSG_CONTROL_RETRACT_RECOVER         _UxGT("回抽恢复长度mm")  //"UnRet +mm" retract_recover_length, additional recover length (mm, added to retract length when recovering)
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
 #define MSG_CONTROL_RETRACT_RECOVERF        _UxGT("回抽恢复后进料速率mm/s")  //"UnRet  V" retract_recover_feedrate_mm_s, feedrate for recovering from retraction (mm/s)
142
 #define MSG_CONTROL_RETRACT_RECOVERF        _UxGT("回抽恢复后进料速率mm/s")  //"UnRet  V" retract_recover_feedrate_mm_s, feedrate for recovering from retraction (mm/s)
143
 #define MSG_AUTORETRACT                     _UxGT("自动抽回")  //"AutoRetr." autoretract_enabled,
143
 #define MSG_AUTORETRACT                     _UxGT("自动抽回")  //"AutoRetr." autoretract_enabled,
144
 #define MSG_FILAMENTCHANGE                  _UxGT("更换丝料")  //"Change filament"
144
 #define MSG_FILAMENTCHANGE                  _UxGT("更换丝料")  //"Change filament"

+ 2
- 2
Marlin/language_zh_TW.h View File

134
 #define MSG_KILLED                          _UxGT("已殺掉")  //"KILLED. "
134
 #define MSG_KILLED                          _UxGT("已殺掉")  //"KILLED. "
135
 #define MSG_STOPPED                         _UxGT("已停止")  //"STOPPED. "
135
 #define MSG_STOPPED                         _UxGT("已停止")  //"STOPPED. "
136
 #define MSG_CONTROL_RETRACT                 _UxGT("回抽長度mm")  //"Retract mm" retract_length, retract length (positive mm)
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
 #define MSG_CONTROL_RETRACTF                _UxGT("回抽速率mm/s")  //"Retract  V" retract_feedrate_mm_s, feedrate for retracting (mm/s)
138
 #define MSG_CONTROL_RETRACTF                _UxGT("回抽速率mm/s")  //"Retract  V" retract_feedrate_mm_s, feedrate for retracting (mm/s)
139
 #define MSG_CONTROL_RETRACT_ZLIFT           _UxGT("Hop mm")  //"Hop mm" retract_zlift, retract Z-lift
139
 #define MSG_CONTROL_RETRACT_ZLIFT           _UxGT("Hop mm")  //"Hop mm" retract_zlift, retract Z-lift
140
 #define MSG_CONTROL_RETRACT_RECOVER         _UxGT("回抽恢複長度mm")  //"UnRet +mm" retract_recover_length, additional recover length (mm, added to retract length when recovering)
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
 #define MSG_CONTROL_RETRACT_RECOVERF        _UxGT("回抽恢複後進料速率mm/s")  //"UnRet  V" retract_recover_feedrate_mm_s, feedrate for recovering from retraction (mm/s)
142
 #define MSG_CONTROL_RETRACT_RECOVERF        _UxGT("回抽恢複後進料速率mm/s")  //"UnRet  V" retract_recover_feedrate_mm_s, feedrate for recovering from retraction (mm/s)
143
 #define MSG_AUTORETRACT                     _UxGT("自動抽回")  //"AutoRetr." autoretract_enabled,
143
 #define MSG_AUTORETRACT                     _UxGT("自動抽回")  //"AutoRetr." autoretract_enabled,
144
 #define MSG_FILAMENTCHANGE                  _UxGT("更換絲料")  //"Change filament"
144
 #define MSG_FILAMENTCHANGE                  _UxGT("更換絲料")  //"Change filament"

+ 2
- 2
Marlin/ultralcd.cpp View File

3373
       MENU_ITEM_EDIT(bool, MSG_AUTORETRACT, &autoretract_enabled);
3373
       MENU_ITEM_EDIT(bool, MSG_AUTORETRACT, &autoretract_enabled);
3374
       MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT, &retract_length, 0, 100);
3374
       MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT, &retract_length, 0, 100);
3375
       #if EXTRUDERS > 1
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
       #endif
3377
       #endif
3378
       MENU_ITEM_EDIT(float3, MSG_CONTROL_RETRACTF, &retract_feedrate_mm_s, 1, 999);
3378
       MENU_ITEM_EDIT(float3, MSG_CONTROL_RETRACTF, &retract_feedrate_mm_s, 1, 999);
3379
       MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_ZLIFT, &retract_zlift, 0, 999);
3379
       MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_ZLIFT, &retract_zlift, 0, 999);
3380
       MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_RECOVER, &retract_recover_length, -100, 100);
3380
       MENU_ITEM_EDIT(float52, MSG_CONTROL_RETRACT_RECOVER, &retract_recover_length, -100, 100);
3381
       #if EXTRUDERS > 1
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
       #endif
3383
       #endif
3384
       MENU_ITEM_EDIT(float3, MSG_CONTROL_RETRACT_RECOVERF, &retract_recover_feedrate_mm_s, 1, 999);
3384
       MENU_ITEM_EDIT(float3, MSG_CONTROL_RETRACT_RECOVERF, &retract_recover_feedrate_mm_s, 1, 999);
3385
       END_MENU();
3385
       END_MENU();

Loading…
Cancel
Save