Skip to content

Commit

Permalink
fix #38
Browse files Browse the repository at this point in the history
  • Loading branch information
ursoft committed Mar 11, 2020
1 parent 1d944a7 commit 550489c
Show file tree
Hide file tree
Showing 8 changed files with 56 additions and 25 deletions.
49 changes: 34 additions & 15 deletions Marlin/Configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -881,7 +881,12 @@
*
* Enable this option for a probe connected to the Z Min endstop pin.
*/
#define Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN
#if (GITHUB_USER==URSOFT)
#undef Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN
#define Z_MIN_PROBE_PIN P1_26
#else
#define Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN
#endif

/**
* Z_MIN_PROBE_PIN
Expand Down Expand Up @@ -937,8 +942,9 @@
/**
* The BLTouch probe uses a Hall effect sensor and emulates a servo.
*/
//#define BLTOUCH

#if (GITHUB_USER==URSOFT)
#define BLTOUCH
#endif
/**
* Touch-MI Probe by hotends.fr
*
Expand Down Expand Up @@ -1001,7 +1007,11 @@
*
* Specify a Probe position as { X, Y, Z }
*/
#define NOZZLE_TO_PROBE_OFFSET { 10, 10, 0 }
#if (GITHUB_USER==URSOFT)
#define NOZZLE_TO_PROBE_OFFSET { 5, 37, 0 }
#else
#define NOZZLE_TO_PROBE_OFFSET { 10, 10, 0 }
#endif

// Most probes should stay away from the edges of the bed, but
// with NOZZLE_AS_PROBE this can be negative for a wider probing area.
Expand Down Expand Up @@ -1043,9 +1053,9 @@
* But: `M851 Z+1` with a CLEARANCE of 2 => 2mm from bed to nozzle.
*/
#define Z_CLEARANCE_DEPLOY_PROBE 10 // Z Clearance for Deploy/Stow
#define Z_CLEARANCE_BETWEEN_PROBES 0 // Z Clearance between probe points
#define Z_CLEARANCE_MULTI_PROBE 5 // Z Clearance between multiple probes
//#define Z_AFTER_PROBING 5 // Z position after probing is done
#define Z_CLEARANCE_BETWEEN_PROBES 10 // Z Clearance between probe points
#define Z_CLEARANCE_MULTI_PROBE 10 // Z Clearance between multiple probes
#define Z_AFTER_PROBING 10 // Z position after probing is done

#define Z_PROBE_LOW_POINT -2 // Farthest distance below the trigger-point to go before stopping

Expand All @@ -1054,7 +1064,9 @@
#define Z_PROBE_OFFSET_RANGE_MAX 20

// Enable the M48 repeatability test to test probe accuracy
//#define Z_MIN_PROBE_REPEATABILITY_TEST
#if (GITHUB_USER==URSOFT)
#define Z_MIN_PROBE_REPEATABILITY_TEST
#endif

// Before deploy/stow pause for user confirmation
//#define PAUSE_BEFORE_DEPLOY_STOW
Expand Down Expand Up @@ -1166,7 +1178,11 @@
#if ENABLED(MIN_SOFTWARE_ENDSTOPS)
#define MIN_SOFTWARE_ENDSTOP_X
#define MIN_SOFTWARE_ENDSTOP_Y
#define MIN_SOFTWARE_ENDSTOP_Z
#if (GITHUB_USER==URSOFT)
#undef MIN_SOFTWARE_ENDSTOP_Z
#else
#define MIN_SOFTWARE_ENDSTOP_Z
#endif
#endif

// Max software endstops constrain movement within maximum coordinate bounds
Expand Down Expand Up @@ -1255,8 +1271,11 @@
//#define AUTO_BED_LEVELING_LINEAR
//#define AUTO_BED_LEVELING_BILINEAR
//#define AUTO_BED_LEVELING_UBL
#define MESH_BED_LEVELING

#if (GITHUB_USER==URSOFT)
#define AUTO_BED_LEVELING_BILINEAR
#else
#define MESH_BED_LEVELING
#endif
/**
* Normally G28 leaves leveling disabled on completion. Enable
* this option to have G28 restore the prior leveling state.
Expand All @@ -1268,7 +1287,7 @@
* Turn on with the command 'M111 S32'.
* NOTE: Requires a lot of PROGMEM!
*/
//#define DEBUG_LEVELING_FEATURE
#define DEBUG_LEVELING_FEATURE

#if ANY(MESH_BED_LEVELING, AUTO_BED_LEVELING_BILINEAR, AUTO_BED_LEVELING_UBL)
// Gradually reduce leveling correction until a set height is reached,
Expand All @@ -1285,11 +1304,11 @@
/**
* Enable the G26 Mesh Validation Pattern tool.
*/
//#define G26_MESH_VALIDATION
#define G26_MESH_VALIDATION
#if ENABLED(G26_MESH_VALIDATION)
#define MESH_TEST_NOZZLE_SIZE 0.4 // (mm) Diameter of primary nozzle.
#define MESH_TEST_LAYER_HEIGHT 0.2 // (mm) Default layer height for the G26 Mesh Validation Tool.
#define MESH_TEST_HOTEND_TEMP 205 // (°C) Default nozzle temperature for the G26 Mesh Validation Tool.
#define MESH_TEST_HOTEND_TEMP 200 // (°C) Default nozzle temperature for the G26 Mesh Validation Tool.
#define MESH_TEST_BED_TEMP 60 // (°C) Default bed temperature for the G26 Mesh Validation Tool.
#define G26_XY_FEEDRATE 20 // (mm/s) Feedrate for XY Moves for the G26 Mesh Validation Tool.
#define G26_RETRACT_MULTIPLIER 1.0 // G26 Q (retraction) used by default between mesh test elements.
Expand Down Expand Up @@ -1330,7 +1349,7 @@
//========================= Unified Bed Leveling ============================
//===========================================================================

//#define MESH_EDIT_GFX_OVERLAY // Display a graphics overlay while editing the mesh
#define MESH_EDIT_GFX_OVERLAY // Display a graphics overlay while editing the mesh

#define MESH_INSET 1 // Set Mesh bounds as an inset region of the bed
#define GRID_MAX_POINTS_X 10 // Don't use more than 15 points per axis, implementation limited.
Expand Down
16 changes: 12 additions & 4 deletions Marlin/Configuration_adv.h
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,11 @@
#define CHAMBER_AUTO_FAN_PIN -1

#define EXTRUDER_AUTO_FAN_TEMPERATURE 50
#define EXTRUDER_AUTO_FAN_SPEED 200 // 255 == full speed
#if (GITHUB_USER==URSOFT)
#define EXTRUDER_AUTO_FAN_SPEED 100
#else
#define EXTRUDER_AUTO_FAN_SPEED 200 // 255 == full speed
#endif
#define EXTRUDER_AUTO_FAN_SPEED_CONFIGURABLE
//#define CHAMBER_AUTO_FAN_TEMPERATURE 30
//#define CHAMBER_AUTO_FAN_SPEED 255
Expand Down Expand Up @@ -1479,11 +1483,13 @@

#define BABYSTEP_DISPLAY_TOTAL // Display total babysteps since last G28

//#define BABYSTEP_ZPROBE_OFFSET // Combine M851 Z and Babystepping
#if (GITHUB_USER==URSOFT)
#define BABYSTEP_ZPROBE_OFFSET // Combine M851 Z and Babystepping
#if ENABLED(BABYSTEP_ZPROBE_OFFSET)
//#define BABYSTEP_HOTEND_Z_OFFSET // For multiple hotends, babystep relative Z offsets
//#define BABYSTEP_ZPROBE_GFX_OVERLAY // Enable graphical overlay on Z-offset editor
#define BABYSTEP_ZPROBE_GFX_OVERLAY // Enable graphical overlay on Z-offset editor
#endif
#endif
#endif

// @section extruder
Expand Down Expand Up @@ -3150,7 +3156,9 @@
//
// M43 - display pin status, toggle pins, watch pins, watch endstops & toggle LED, test servo probe
//
//#define PINS_DEBUGGING
#if (GITHUB_USER==URSOFT)
#define PINS_DEBUGGING
#endif

// Enable Marlin dev mode which adds some special commands
//#define MARLIN_DEV_MODE
2 changes: 1 addition & 1 deletion Marlin/Version.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
/**
* Marlin release version identifier
*/
#define SHORT_BUILD_VERSION "bf-2.0.x.4" //last is build No
#define SHORT_BUILD_VERSION "bf-2.0.x.5" //last is build No

/**
* Verbose version identifier which should contain a reference to the location
Expand Down
4 changes: 4 additions & 0 deletions Marlin/src/feature/bltouch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,12 @@ void BLTouch::init(const bool set_voltage/*=false*/) {
// This mode will stay active until manual SET_OD_MODE or power cycle
// BLTOUCH V3.1: SET_5V_MODE or SET_OD_MODE (if enabled).
// At power on, the probe will default to the eeprom settings configured by the user
#if (GITHUB_USER==URSOFT)
stow_proc();
#else
_reset();
_stow();
#endif

#if ENABLED(BLTOUCH_FORCE_MODE_SET)

Expand Down
2 changes: 1 addition & 1 deletion Marlin/src/inc/Conditionals_LCD.h
Original file line number Diff line number Diff line change
Expand Up @@ -497,7 +497,7 @@
#undef DEACTIVATE_SERVOS_AFTER_MOVE
#if NUM_SERVOS == 1
#undef SERVO_DELAY
#define SERVO_DELAY { 50 }
#define SERVO_DELAY { 750 }
#endif

// Always disable probe pin inverting for BLTouch
Expand Down
2 changes: 1 addition & 1 deletion Marlin/src/lcd/menu/menu_motion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ void menu_motion() {
#endif

#if ENABLED(Z_MIN_PROBE_REPEATABILITY_TEST)
GCODES_ITEM(MSG_M48_TEST, PSTR("G28\nM48 P10"));
GCODES_ITEM(MSG_M48_TEST, PSTR("G28\nM48 P10 X20 Y50"));
#endif

//
Expand Down
4 changes: 2 additions & 2 deletions Marlin/src/module/endstops.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -820,8 +820,8 @@ void Endstops::update() {
if (true
#if ENABLED(Z_MIN_PROBE_USES_Z_MIN_ENDSTOP_PIN)
&& z_probe_enabled
#elif HAS_CUSTOM_PROBE_PIN
&& !z_probe_enabled
//#elif HAS_CUSTOM_PROBE_PIN /* stop on Zmin also, not only probe */
// && !z_probe_enabled
#endif
) PROCESS_ENDSTOP_Z(MIN);
#endif
Expand Down
2 changes: 1 addition & 1 deletion Marlin/src/module/probe.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -617,7 +617,7 @@ float Probe::run_z_probe(const bool sanity_check/*=true*/) {
{
// Probe downward slowly to find the bed
if (probe_down_to_z(z_probe_low_point, MMM_TO_MMS(Z_PROBE_SPEED_SLOW)) // No probe trigger?
|| (sanity_check && current_position.z > -offset.z + _MAX(Z_CLEARANCE_MULTI_PROBE, 4) / 2) // Probe triggered too high?
|| (sanity_check && current_position.z > -offset.z + _MAX(Z_CLEARANCE_MULTI_PROBE, 4) / 2.0) // Probe triggered too high?
) {
if (DEBUGGING(LEVELING)) {
DEBUG_ECHOLNPGM("SLOW Probe fail!");
Expand Down

0 comments on commit 550489c

Please sign in to comment.