{"action":"created","issue":{"url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/2962","repository_url":"https://api.github.com/repos/MarlinFirmware/Marlin","labels_url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/2962/labels{/name}","comments_url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/2962/comments","events_url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/2962/events","html_url":"https://github.com/MarlinFirmware/Marlin/issues/2962","id":130251048,"number":2962,"title":"Z probe servo endstop does not work unless auto leveling is turned on.","user":{"login":"Entr04y","id":785951,"avatar_url":"https://avatars.githubusercontent.com/u/785951?v=3","gravatar_id":"","url":"https://api.github.com/users/Entr04y","html_url":"https://github.com/Entr04y","followers_url":"https://api.github.com/users/Entr04y/followers","following_url":"https://api.github.com/users/Entr04y/following{/other_user}","gists_url":"https://api.github.com/users/Entr04y/gists{/gist_id}","starred_url":"https://api.github.com/users/Entr04y/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Entr04y/subscriptions","organizations_url":"https://api.github.com/users/Entr04y/orgs","repos_url":"https://api.github.com/users/Entr04y/repos","events_url":"https://api.github.com/users/Entr04y/events{/privacy}","received_events_url":"https://api.github.com/users/Entr04y/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2016-02-01T04:11:16Z","updated_at":"2016-03-08T22:14:02Z","closed_at":"2016-02-02T17:23:24Z","body":"I have a z probe with a servo as my z-min endstop (it is a bltouch)  I wish to use mesh leveling, but the servo code for the Z axis seems to require auto bed leveling to be turned on... which causes the head to crash into the bed because the probe doesn't deploy on homing.  I found the following in RC3 (around line 1838, which is in the function for homing a single axis):\r\n\r\n```\r\n#if ENABLED(Z_PROBE_SLED)\r\n      // Get Probe\r\n      if (axis == Z_AXIS) {\r\n        if (axis_home_dir < 0) dock_sled(false);\r\n      }\r\n#endif\r\n\r\n#if SERVO_LEVELING && DISABLED(Z_PROBE_SLED)\r\n\r\n      // Deploy a Z probe if there is one, and homing towards the bed\r\n      if (axis == Z_AXIS) {\r\n        if (axis_home_dir < 0) deploy_z_probe();\r\n      }\r\n\r\n#endif\r\n```\r\n\r\nIn Conditionals.h there is this:\r\n\r\n```\r\n#define SERVO_LEVELING (defined(AUTO_BED_LEVELING_FEATURE) && defined(Z_ENDSTOP_SERVO_NR))\r\n```\r\n\r\nHowever, for the X and Y axis, we have this:\r\n```\r\n#if HAS_SERVO_ENDSTOPS\r\n      // Engage Servo endstop if enabled\r\n      if (axis != Z_AXIS && servo_endstop_id[axis] >= 0)\r\n        servo[servo_endstop_id[axis]].move(servo_endstop_angle[axis][0]);\r\n    #endif\r\n```\r\n\r\nSo I think the end result is if you are homing X or Y, go ahead and use the servo, but if you are homing Z use the sled if there is one, but if its just a servo then don't use it unless auto bed leveling is enabled... because \"deploy_z_probe()\" is part of the auto leveling code, rather than an independent thing.\r\n\r\nIt seems to me that the code to use servo endstops should exist outside of and independent of the auto leveling code, regardless of which axis it is.  This would allow us to use mesh leveling, or just a servo for the endstop without any kind of leveling turned on."},"comment":{"url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/comments/193990714","html_url":"https://github.com/MarlinFirmware/Marlin/issues/2962#issuecomment-193990714","issue_url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/2962","id":193990714,"user":{"login":"samwyze","id":943581,"avatar_url":"https://avatars.githubusercontent.com/u/943581?v=3","gravatar_id":"","url":"https://api.github.com/users/samwyze","html_url":"https://github.com/samwyze","followers_url":"https://api.github.com/users/samwyze/followers","following_url":"https://api.github.com/users/samwyze/following{/other_user}","gists_url":"https://api.github.com/users/samwyze/gists{/gist_id}","starred_url":"https://api.github.com/users/samwyze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/samwyze/subscriptions","organizations_url":"https://api.github.com/users/samwyze/orgs","repos_url":"https://api.github.com/users/samwyze/repos","events_url":"https://api.github.com/users/samwyze/events{/privacy}","received_events_url":"https://api.github.com/users/samwyze/received_events","type":"User","site_admin":false},"created_at":"2016-03-08T22:14:02Z","updated_at":"2016-03-08T22:14:02Z","body":"I think z-probe variables like the offsets and the deploy and stow routines should be independent of auto bed leveling. This adds the possibility to use them in an auto mesh level routine and also to send manual deploy/stow g-code from a console...therefore I propose the way it is currently handled is a BUG and not a new feature/feature request. But that might just be me :)"}}