MarlinFirmware / Marlin

Marlin is an optimized firmware for RepRap 3D printers based on the Arduino platform. Many commercial 3D printers come with Marlin installed. Check with your vendor if you need source code for your specific machine.
https://marlinfw.org
GNU General Public License v3.0
16.25k stars 19.23k forks source link

[FR] Joystick ~ Respect BedSize , endstops. NO_MOTION_BEFORE_HOMING #19855

Open bmatusiak opened 4 years ago

bmatusiak commented 4 years ago

i love the joystick for positioning. but i want to protect the machine ware.

it currently does not respect these options

hoping someone could include some protection for "out of bounds" moves and position accuracy for pre-printing setup when using JOYSTICK

extra notes.. joystick im using Joystick

config im using in Configuration_adv.h

#define JOYSTICK
#if ENABLED(JOYSTICK)
  #define JOY_X_PIN    5  // RAMPS: Suggested pin A5  on AUX2
  #define JOY_Y_PIN   10  // RAMPS: Suggested pin A10 on AUX2
  //#define JOY_Z_PIN   12  // RAMPS: Suggested pin A12 on AUX2
  #define JOY_EN_PIN  44  // RAMPS: Suggested pin D44 on AUX2

  //#define INVERT_JOY_X  // Enable if X direction is reversed
  //#define INVERT_JOY_Y  // Enable if Y direction is reversed
  //#define INVERT_JOY_Z  // Enable if Z direction is reversed

  // Use M119 with JOYSTICK_DEBUG to find reasonable values after connecting:
  #define JOY_X_LIMITS { 0, 8848-100, 8848+100, 16368 } // min, deadzone start, deadzone end, max
  #define JOY_Y_LIMITS { 0, 8125-100, 8175+100, 16368 }
  #define JOY_Z_LIMITS { 0, 0, 0 ,0} //{ 4800, 8080-100, 8080+100, 11550 }
  #define JOYSTICK_DEBUG
#endif
violetbp commented 3 years ago

after homing it respects the normal software endstops