You are a bit short on detail.
Have you got a machine - how big is it, what are your motors, have you accurately set your steps per unit for your motors. Is you machine set up in millimeters or inches. Start with that and we will try and help. It will be a setting up problem, usually.
Reading your post, you say the motors run from the keyboard - i.e. do you mean you can jog them. At what steps per, speed and acc are your motors set to.