Browse Source

Disable PROBE_MANUALLY for UBL

Plus some other UBL tweaks.
Scott Lahteine 7 years ago
parent
commit
75badae2f8
4 changed files with 28 additions and 11 deletions
  1. 7
    0
      Marlin/Conditionals_LCD.h
  2. 3
    0
      Marlin/Marlin.h
  3. 10
    6
      Marlin/SanityCheck.h
  4. 8
    5
      Marlin/ubl_G29.cpp

+ 7
- 0
Marlin/Conditionals_LCD.h View File

374
   #define HAS_Z_SERVO_ENDSTOP (defined(Z_ENDSTOP_SERVO_NR) && Z_ENDSTOP_SERVO_NR >= 0)
374
   #define HAS_Z_SERVO_ENDSTOP (defined(Z_ENDSTOP_SERVO_NR) && Z_ENDSTOP_SERVO_NR >= 0)
375
 
375
 
376
   /**
376
   /**
377
+   * UBL has its own manual probing, so this just causes trouble.
378
+   */
379
+  #if ENABLED(AUTO_BED_LEVELING_UBL)
380
+    #undef PROBE_MANUALLY
381
+  #endif
382
+
383
+  /**
377
    * Set a flag for any enabled probe
384
    * Set a flag for any enabled probe
378
    */
385
    */
379
   #define PROBE_SELECTED (ENABLED(PROBE_MANUALLY) || ENABLED(FIX_MOUNTED_PROBE) || ENABLED(Z_PROBE_ALLEN_KEY) || HAS_Z_SERVO_ENDSTOP || ENABLED(Z_PROBE_SLED) || ENABLED(SOLENOID_PROBE))
386
   #define PROBE_SELECTED (ENABLED(PROBE_MANUALLY) || ENABLED(FIX_MOUNTED_PROBE) || ENABLED(Z_PROBE_ALLEN_KEY) || HAS_Z_SERVO_ENDSTOP || ENABLED(Z_PROBE_SLED) || ENABLED(SOLENOID_PROBE))

+ 3
- 0
Marlin/Marlin.h View File

351
   void refresh_zprobe_zoffset(const bool no_babystep=false);
351
   void refresh_zprobe_zoffset(const bool no_babystep=false);
352
   #define DEPLOY_PROBE() set_probe_deployed(true)
352
   #define DEPLOY_PROBE() set_probe_deployed(true)
353
   #define STOW_PROBE() set_probe_deployed(false)
353
   #define STOW_PROBE() set_probe_deployed(false)
354
+#else
355
+  #define DEPLOY_PROBE()
356
+  #define STOW_PROBE()
354
 #endif
357
 #endif
355
 
358
 
356
 #if ENABLED(HOST_KEEPALIVE_FEATURE)
359
 #if ENABLED(HOST_KEEPALIVE_FEATURE)

+ 10
- 6
Marlin/SanityCheck.h View File

463
   #if ENABLED(BLTOUCH)
463
   #if ENABLED(BLTOUCH)
464
     + 1
464
     + 1
465
   #endif
465
   #endif
466
-  #if ENABLED(Z_PROBE_ALLEN_KEY)
466
+  #if ENABLED(SOLENOID_PROBE)
467
     + 1
467
     + 1
468
   #endif
468
   #endif
469
-  #if ENABLED(Z_PROBE_SLED)
469
+  #if ENABLED(Z_PROBE_ALLEN_KEY)
470
     + 1
470
     + 1
471
   #endif
471
   #endif
472
-  #if ENABLED(SOLENOID_PROBE)
472
+  #if ENABLED(Z_PROBE_SLED)
473
     + 1
473
     + 1
474
   #endif
474
   #endif
475
-  , "Please enable only one probe: PROBE_MANUALLY, FIX_MOUNTED_PROBE, Z Servo, BLTOUCH, Z_PROBE_ALLEN_KEY, or Z_PROBE_SLED."
475
+  , "Please enable only one probe option: PROBE_MANUALLY, FIX_MOUNTED_PROBE, BLTOUCH, SOLENOID_PROBE, Z_PROBE_ALLEN_KEY, Z_PROBE_SLED, or Z Servo."
476
 );
476
 );
477
 
477
 
478
 
478
 
547
    * Require some kind of probe for bed leveling and probe testing
547
    * Require some kind of probe for bed leveling and probe testing
548
    */
548
    */
549
   #if HAS_ABL
549
   #if HAS_ABL
550
-    #error "Auto Bed Leveling requires a probe! Define a Z Servo, Z_PROBE_ALLEN_KEY, Z_PROBE_SLED, or FIX_MOUNTED_PROBE."
550
+    #if ENABLED(AUTO_BED_LEVELING_UBL)
551
+      #error "Unified Bed Leveling requires a probe: FIX_MOUNTED_PROBE, BLTOUCH, SOLENOID_PROBE, Z_PROBE_ALLEN_KEY, Z_PROBE_SLED, or Z Servo."
552
+    #else
553
+      #error "Auto Bed Leveling requires one of these: PROBE_MANUALLY, FIX_MOUNTED_PROBE, BLTOUCH, SOLENOID_PROBE, Z_PROBE_ALLEN_KEY, Z_PROBE_SLED, or a Z Servo."
554
+    #endif
551
   #elif ENABLED(Z_MIN_PROBE_REPEATABILITY_TEST)
555
   #elif ENABLED(Z_MIN_PROBE_REPEATABILITY_TEST)
552
-    #error "Z_MIN_PROBE_REPEATABILITY_TEST requires a probe! Define a Z Servo, Z_PROBE_ALLEN_KEY, Z_PROBE_SLED, or FIX_MOUNTED_PROBE."
556
+    #error "Z_MIN_PROBE_REPEATABILITY_TEST requires a probe: FIX_MOUNTED_PROBE, BLTOUCH, SOLENOID_PROBE, Z_PROBE_ALLEN_KEY, Z_PROBE_SLED, or Z Servo."
553
   #endif
557
   #endif
554
 
558
 
555
 #endif
559
 #endif

+ 8
- 5
Marlin/ubl_G29.cpp View File

640
         ubl.state.z_offset = code_value_float();   // do the simple case. Just lock in the specified value
640
         ubl.state.z_offset = code_value_float();   // do the simple case. Just lock in the specified value
641
       else {
641
       else {
642
         ubl.save_ubl_active_state_and_disable();
642
         ubl.save_ubl_active_state_and_disable();
643
-        //measured_z = probe_pt(x_pos + X_PROBE_OFFSET_FROM_EXTRUDER, y_pos + Y_PROBE_OFFSET_FROM_EXTRUDER, ProbeDeployAndStow, g29_verbose_level);
643
+        //float measured_z = probe_pt(x_pos + X_PROBE_OFFSET_FROM_EXTRUDER, y_pos + Y_PROBE_OFFSET_FROM_EXTRUDER, ProbeDeployAndStow, g29_verbose_level);
644
 
644
 
645
         ubl.has_control_of_lcd_panel = true;     // Grab the LCD Hardware
645
         ubl.has_control_of_lcd_panel = true;     // Grab the LCD Hardware
646
-        measured_z = 1.5;
646
+        float measured_z = 1.5;
647
         do_blocking_move_to_z(measured_z);  // Get close to the bed, but leave some space so we don't damage anything
647
         do_blocking_move_to_z(measured_z);  // Get close to the bed, but leave some space so we don't damage anything
648
                                             // The user is not going to be locking in a new Z-Offset very often so
648
                                             // The user is not going to be locking in a new Z-Offset very often so
649
                                             // it won't be that painful to spin the Encoder Wheel for 1.5mm
649
                                             // it won't be that painful to spin the Encoder Wheel for 1.5mm
1185
       SERIAL_PROTOCOL_F(planner.z_fade_height, 4);
1185
       SERIAL_PROTOCOL_F(planner.z_fade_height, 4);
1186
       SERIAL_EOL;
1186
       SERIAL_EOL;
1187
     #endif
1187
     #endif
1188
-    SERIAL_PROTOCOLPGM("zprobe_zoffset: ");
1189
-    SERIAL_PROTOCOL_F(zprobe_zoffset, 7);
1190
-    SERIAL_EOL;
1188
+
1189
+    #if HAS_BED_PROBE
1190
+      SERIAL_PROTOCOLPGM("zprobe_zoffset: ");
1191
+      SERIAL_PROTOCOL_F(zprobe_zoffset, 7);
1192
+      SERIAL_EOL;
1193
+    #endif
1191
 
1194
 
1192
     SERIAL_ECHOLNPAIR("UBL_MESH_MIN_X  " STRINGIFY(UBL_MESH_MIN_X) "=", UBL_MESH_MIN_X);
1195
     SERIAL_ECHOLNPAIR("UBL_MESH_MIN_X  " STRINGIFY(UBL_MESH_MIN_X) "=", UBL_MESH_MIN_X);
1193
     SERIAL_ECHOLNPAIR("UBL_MESH_MIN_Y  " STRINGIFY(UBL_MESH_MIN_Y) "=", UBL_MESH_MIN_Y);
1196
     SERIAL_ECHOLNPAIR("UBL_MESH_MIN_Y  " STRINGIFY(UBL_MESH_MIN_Y) "=", UBL_MESH_MIN_Y);

Loading…
Cancel
Save