Setting Endstops

Set endstops using Repetier procedure.
You can find the repetier documentation at https://www.repetier.com/documentation/repetier-firmware/z-probing/

That procedure is: Clear existing endstop settings with G28 G131 M99 [X!Y!Z]0 [S10] M99 X0 S20 M99 Y0 S20 M99 Z0 S20 G132 S1
 * Get a metal rule or even a stiff stick that will fit between your printer base and your extruder carriage. I use a 30cm metal rule.
 * Disable each motor individually, one at a time, with
 * These M99 commands unlock the corresponding motor for 20 seconds. If you leave off the "S" parameter it defaults to 10 seconds. Enter the M99 commands one at a time and then move the tower trucks, slowly so as not to generate back currents, one at a time, to an exact position based on your ruler or stick just fitting between the truck and the base - careful of wires. i like to let the motor lock before pulling the ruler out. remember you can repeat a command in repetier with up arrow.
 * Issue the following command:
 * The carriages will move to the top, slowly, while the computer counts the number of steps that it takes for the carriage to get to the endstop. The difference is then calculated, and endstops that were higher than the lowest endstop have an offset applied, in steps.
 * Now the endstops are set. IMHO this is much simpler than the Marlin procedure.