|
@@ -1892,6 +1892,14 @@ void MarlinSettings::reset(PORTARG_SOLO) {
|
1892
|
1892
|
|
1893
|
1893
|
#define CONFIG_ECHO_START do{ if (!forReplay) SERIAL_ECHO_START_P(port); }while(0)
|
1894
|
1894
|
|
|
1895
|
+ #if HAS_TRINAMIC
|
|
1896
|
+ void say_M906() { SERIAL_ECHOPGM_P(port, " M906 "); }
|
|
1897
|
+ void say_M913() { SERIAL_ECHOPGM_P(port, " M913 "); }
|
|
1898
|
+ #if ENABLED(SENSORLESS_HOMING)
|
|
1899
|
+ void say_M914() { SERIAL_ECHOPGM_P(port, " M914 "); }
|
|
1900
|
+ #endif
|
|
1901
|
+ #endif
|
|
1902
|
+
|
1895
|
1903
|
#if ENABLED(ADVANCED_PAUSE_FEATURE)
|
1896
|
1904
|
void say_M603() { SERIAL_ECHOPGM_P(port, " M603 "); }
|
1897
|
1905
|
#endif
|
|
@@ -2373,34 +2381,51 @@ void MarlinSettings::reset(PORTARG_SOLO) {
|
2373
|
2381
|
SERIAL_ECHOLNPGM_P(port, "Stepper driver current:");
|
2374
|
2382
|
}
|
2375
|
2383
|
CONFIG_ECHO_START;
|
2376
|
|
- SERIAL_ECHOPGM_P(port, " M906");
|
2377
|
2384
|
#if X_IS_TRINAMIC
|
2378
|
|
- SERIAL_ECHOPAIR_P(port, " X", stepperX.getCurrent());
|
2379
|
|
- #elif X2_IS_TRINAMIC
|
2380
|
|
- SERIAL_ECHOPAIR_P(port, " X", stepperX2.getCurrent());
|
|
2385
|
+ say_M906();
|
|
2386
|
+ SERIAL_ECHOLNPAIR_P(port, "X", stepperX.getCurrent());
|
|
2387
|
+ #endif
|
|
2388
|
+ #if X2_IS_TRINAMIC
|
|
2389
|
+ say_M906();
|
|
2390
|
+ SERIAL_ECHOLNPAIR_P(port, "I1 X", stepperX2.getCurrent());
|
2381
|
2391
|
#endif
|
2382
|
2392
|
#if Y_IS_TRINAMIC
|
2383
|
|
- SERIAL_ECHOPAIR_P(port, " Y", stepperY.getCurrent());
|
2384
|
|
- #elif Y2_IS_TRINAMIC
|
2385
|
|
- SERIAL_ECHOPAIR_P(port, " Y", stepperY2.getCurrent());
|
|
2393
|
+ say_M906();
|
|
2394
|
+ SERIAL_ECHOLNPAIR_P(port, "Y", stepperY.getCurrent());
|
|
2395
|
+ #endif
|
|
2396
|
+ #if Y2_IS_TRINAMIC
|
|
2397
|
+ say_M906();
|
|
2398
|
+ SERIAL_ECHOLNPAIR_P(port, "I1 Y", stepperY2.getCurrent());
|
2386
|
2399
|
#endif
|
2387
|
2400
|
#if Z_IS_TRINAMIC
|
2388
|
|
- SERIAL_ECHOPAIR_P(port, " Z", stepperZ.getCurrent());
|
2389
|
|
- #elif Z2_IS_TRINAMIC
|
2390
|
|
- SERIAL_ECHOPAIR_P(port, " Z", stepperZ2.getCurrent());
|
|
2401
|
+ say_M906();
|
|
2402
|
+ SERIAL_ECHOLNPAIR_P(port, "Z", stepperZ.getCurrent());
|
|
2403
|
+ #endif
|
|
2404
|
+ #if Z2_IS_TRINAMIC
|
|
2405
|
+ say_M906();
|
|
2406
|
+ SERIAL_ECHOLNPAIR_P(port, "I1 Z", stepperZ2.getCurrent());
|
2391
|
2407
|
#endif
|
2392
|
2408
|
#if E0_IS_TRINAMIC
|
2393
|
|
- SERIAL_ECHOPAIR_P(port, " E", stepperE0.getCurrent());
|
2394
|
|
- #elif E1_IS_TRINAMIC
|
2395
|
|
- SERIAL_ECHOPAIR_P(port, " E", stepperE1.getCurrent());
|
2396
|
|
- #elif E2_IS_TRINAMIC
|
2397
|
|
- SERIAL_ECHOPAIR_P(port, " E", stepperE2.getCurrent());
|
2398
|
|
- #elif E3_IS_TRINAMIC
|
2399
|
|
- SERIAL_ECHOPAIR_P(port, " E", stepperE3.getCurrent());
|
2400
|
|
- #elif E4_IS_TRINAMIC
|
2401
|
|
- SERIAL_ECHOPAIR_P(port, " E", stepperE4.getCurrent());
|
2402
|
|
- #endif
|
2403
|
|
- SERIAL_EOL();
|
|
2409
|
+ say_M906();
|
|
2410
|
+ SERIAL_ECHOLNPAIR_P(port, "T0 E", stepperE0.getCurrent());
|
|
2411
|
+ #endif
|
|
2412
|
+ #if E_STEPPERS > 1 && E1_IS_TRINAMIC
|
|
2413
|
+ say_M906();
|
|
2414
|
+ SERIAL_ECHOLNPAIR_P(port, "T1 E", stepperE1.getCurrent());
|
|
2415
|
+ #endif
|
|
2416
|
+ #if E_STEPPERS > 2 && E2_IS_TRINAMIC
|
|
2417
|
+ say_M906();
|
|
2418
|
+ SERIAL_ECHOLNPAIR_P(port, "T2 E", stepperE2.getCurrent());
|
|
2419
|
+ #endif
|
|
2420
|
+ #if E_STEPPERS > 3 && E3_IS_TRINAMIC
|
|
2421
|
+ say_M906();
|
|
2422
|
+ SERIAL_ECHOLNPAIR_P(port, "T3 E", stepperE3.getCurrent());
|
|
2423
|
+ #endif
|
|
2424
|
+ #if E_STEPPERS > 4 && E4_IS_TRINAMIC
|
|
2425
|
+ say_M906();
|
|
2426
|
+ SERIAL_ECHOLNPAIR_P(port, "T4 E", stepperE4.getCurrent());
|
|
2427
|
+ #endif
|
|
2428
|
+ SERIAL_EOL_P(port);
|
2404
|
2429
|
|
2405
|
2430
|
/**
|
2406
|
2431
|
* TMC2130 / TMC2208 / TRAMS Hybrid Threshold
|
|
@@ -2410,34 +2435,51 @@ void MarlinSettings::reset(PORTARG_SOLO) {
|
2410
|
2435
|
SERIAL_ECHOLNPGM_P(port, "Hybrid Threshold:");
|
2411
|
2436
|
}
|
2412
|
2437
|
CONFIG_ECHO_START;
|
2413
|
|
- SERIAL_ECHOPGM_P(port, " M913");
|
2414
|
2438
|
#if X_IS_TRINAMIC
|
2415
|
|
- SERIAL_ECHOPAIR_P(port, " X", TMC_GET_PWMTHRS(X, X));
|
2416
|
|
- #elif X2_IS_TRINAMIC
|
2417
|
|
- SERIAL_ECHOPAIR_P(port, " X", TMC_GET_PWMTHRS(X, X2));
|
|
2439
|
+ say_M913();
|
|
2440
|
+ SERIAL_ECHOLNPAIR_P(port, "X", TMC_GET_PWMTHRS(X, X));
|
|
2441
|
+ #endif
|
|
2442
|
+ #if X2_IS_TRINAMIC
|
|
2443
|
+ say_M913();
|
|
2444
|
+ SERIAL_ECHOLNPAIR_P(port, "I1 X", TMC_GET_PWMTHRS(X, X2));
|
2418
|
2445
|
#endif
|
2419
|
2446
|
#if Y_IS_TRINAMIC
|
2420
|
|
- SERIAL_ECHOPAIR_P(port, " Y", TMC_GET_PWMTHRS(Y, Y));
|
2421
|
|
- #elif Y2_IS_TRINAMIC
|
2422
|
|
- SERIAL_ECHOPAIR_P(port, " Y", TMC_GET_PWMTHRS(Y, Y2));
|
|
2447
|
+ say_M913();
|
|
2448
|
+ SERIAL_ECHOLNPAIR_P(port, "Y", TMC_GET_PWMTHRS(Y, Y));
|
|
2449
|
+ #endif
|
|
2450
|
+ #if Y2_IS_TRINAMIC
|
|
2451
|
+ say_M913();
|
|
2452
|
+ SERIAL_ECHOLNPAIR_P(port, "I1 Y", TMC_GET_PWMTHRS(Y, Y2));
|
2423
|
2453
|
#endif
|
2424
|
2454
|
#if Z_IS_TRINAMIC
|
2425
|
|
- SERIAL_ECHOPAIR_P(port, " Z", TMC_GET_PWMTHRS(Z, Z));
|
2426
|
|
- #elif Z2_IS_TRINAMIC
|
2427
|
|
- SERIAL_ECHOPAIR_P(port, " Z", TMC_GET_PWMTHRS(Z, Z2));
|
|
2455
|
+ say_M913();
|
|
2456
|
+ SERIAL_ECHOLNPAIR_P(port, "Z", TMC_GET_PWMTHRS(Z, Z));
|
|
2457
|
+ #endif
|
|
2458
|
+ #if Z2_IS_TRINAMIC
|
|
2459
|
+ say_M913();
|
|
2460
|
+ SERIAL_ECHOLNPAIR_P(port, "I1 Z", TMC_GET_PWMTHRS(Z, Z2));
|
2428
|
2461
|
#endif
|
2429
|
2462
|
#if E0_IS_TRINAMIC
|
2430
|
|
- SERIAL_ECHOPAIR_P(port, " E", TMC_GET_PWMTHRS(E, E0));
|
2431
|
|
- #elif E1_IS_TRINAMIC
|
2432
|
|
- SERIAL_ECHOPAIR_P(port, " E", TMC_GET_PWMTHRS(E, E1));
|
2433
|
|
- #elif E2_IS_TRINAMIC
|
2434
|
|
- SERIAL_ECHOPAIR_P(port, " E", TMC_GET_PWMTHRS(E, E2));
|
2435
|
|
- #elif E3_IS_TRINAMIC
|
2436
|
|
- SERIAL_ECHOPAIR_P(port, " E", TMC_GET_PWMTHRS(E, E3));
|
2437
|
|
- #elif E4_IS_TRINAMIC
|
2438
|
|
- SERIAL_ECHOPAIR_P(port, " E", TMC_GET_PWMTHRS(E, E4));
|
2439
|
|
- #endif
|
2440
|
|
- SERIAL_EOL();
|
|
2463
|
+ say_M913();
|
|
2464
|
+ SERIAL_ECHOLNPAIR_P(port, "T0 E", TMC_GET_PWMTHRS(E, E0));
|
|
2465
|
+ #endif
|
|
2466
|
+ #if E_STEPPERS > 1 && E1_IS_TRINAMIC
|
|
2467
|
+ say_M913();
|
|
2468
|
+ SERIAL_ECHOLNPAIR_P(port, "T1 E", TMC_GET_PWMTHRS(E, E1));
|
|
2469
|
+ #endif
|
|
2470
|
+ #if E_STEPPERS > 2 && E2_IS_TRINAMIC
|
|
2471
|
+ say_M913();
|
|
2472
|
+ SERIAL_ECHOLNPAIR_P(port, "T2 E", TMC_GET_PWMTHRS(E, E2));
|
|
2473
|
+ #endif
|
|
2474
|
+ #if E_STEPPERS > 3 && E3_IS_TRINAMIC
|
|
2475
|
+ say_M913();
|
|
2476
|
+ SERIAL_ECHOLNPAIR_P(port, "T3 E", TMC_GET_PWMTHRS(E, E3));
|
|
2477
|
+ #endif
|
|
2478
|
+ #if E_STEPPERS > 4 && E4_IS_TRINAMIC
|
|
2479
|
+ say_M913();
|
|
2480
|
+ SERIAL_ECHOLNPAIR_P(port, "T4 E", TMC_GET_PWMTHRS(E, E4));
|
|
2481
|
+ #endif
|
|
2482
|
+ SERIAL_EOL_P(port);
|
2441
|
2483
|
|
2442
|
2484
|
/**
|
2443
|
2485
|
* TMC2130 Sensorless homing thresholds
|
|
@@ -2448,29 +2490,37 @@ void MarlinSettings::reset(PORTARG_SOLO) {
|
2448
|
2490
|
SERIAL_ECHOLNPGM_P(port, "Sensorless homing threshold:");
|
2449
|
2491
|
}
|
2450
|
2492
|
CONFIG_ECHO_START;
|
2451
|
|
- SERIAL_ECHOPGM_P(port, " M914");
|
2452
|
2493
|
#ifdef X_HOMING_SENSITIVITY
|
2453
|
2494
|
#if ENABLED(X_IS_TMC2130) || ENABLED(IS_TRAMS)
|
2454
|
|
- SERIAL_ECHOPAIR_P(port, " X", stepperX.sgt());
|
2455
|
|
- #elif ENABLED(X2_IS_TMC2130)
|
2456
|
|
- SERIAL_ECHOPAIR_P(port, " X", stepperX2.sgt());
|
|
2495
|
+ say_M914();
|
|
2496
|
+ SERIAL_ECHOLNPAIR_P(port, "X", stepperX.sgt());
|
|
2497
|
+ #endif
|
|
2498
|
+ #if ENABLED(X2_IS_TMC2130)
|
|
2499
|
+ say_M914();
|
|
2500
|
+ SERIAL_ECHOLNPAIR_P(port, "I1 X", stepperX2.sgt());
|
2457
|
2501
|
#endif
|
2458
|
2502
|
#endif
|
2459
|
2503
|
#ifdef Y_HOMING_SENSITIVITY
|
2460
|
2504
|
#if ENABLED(Y_IS_TMC2130) || ENABLED(IS_TRAMS)
|
2461
|
|
- SERIAL_ECHOPAIR_P(port, " Y", stepperY.sgt());
|
2462
|
|
- #elif ENABLED(Y2_IS_TMC2130)
|
2463
|
|
- SERIAL_ECHOPAIR_P(port, " Y", stepperY2.sgt());
|
|
2505
|
+ say_M914();
|
|
2506
|
+ SERIAL_ECHOLNPAIR_P(port, "Y", stepperY.sgt());
|
|
2507
|
+ #endif
|
|
2508
|
+ #if ENABLED(Y2_IS_TMC2130)
|
|
2509
|
+ say_M914();
|
|
2510
|
+ SERIAL_ECHOLNPAIR_P(port, "I1 Y", stepperY2.sgt());
|
2464
|
2511
|
#endif
|
2465
|
2512
|
#endif
|
2466
|
2513
|
#ifdef Z_HOMING_SENSITIVITY
|
2467
|
2514
|
#if ENABLED(Z_IS_TMC2130) || ENABLED(IS_TRAMS)
|
2468
|
|
- SERIAL_ECHOPAIR_P(port, " Z", stepperZ.sgt());
|
2469
|
|
- #elif ENABLED(Z2_IS_TMC2130)
|
2470
|
|
- SERIAL_ECHOPAIR_P(port, " Z", stepperZ2.sgt());
|
|
2515
|
+ say_M914();
|
|
2516
|
+ SERIAL_ECHOLNPAIR_P(port, "Z", stepperZ.sgt());
|
|
2517
|
+ #endif
|
|
2518
|
+ #if ENABLED(Z2_IS_TMC2130)
|
|
2519
|
+ say_M914();
|
|
2520
|
+ SERIAL_ECHOLNPAIR_P(port, "I1 Z", stepperZ2.sgt());
|
2471
|
2521
|
#endif
|
2472
|
2522
|
#endif
|
2473
|
|
- SERIAL_EOL();
|
|
2523
|
+ SERIAL_EOL_P(port);
|
2474
|
2524
|
#endif
|
2475
|
2525
|
|
2476
|
2526
|
#endif // HAS_TRINAMIC
|