The leadscrew drive structure is built in two previous examples. Limit switches can be added the same way as in belt drive example.
Electronics are also connected the same way as in belt drive, except that with leadscrew and lead nut made of metal, it's not necessary to have a ground wire connecting sliding element and the frame.
The firmware configuration is the same as in belt drive example with the exception of a couple of _init.pde values (assuming standard 1/4"-20TPI all-thread rod as a leadscrew):
#define X_STEPS_PER_INCH 8000
#define FAST_XY_FEEDRATE_INCH 20
#define MAX_ACCEL_INCH 50