1-iam using a dc motor on the shoulder of the robot's arm

2- iam using ultra sonic with a servo motor to Calculate the distance and find a container
3- the problem is how to let he dc motor moves to the place where the ultrasonic and the servo is looking at and stop at this point Automatic
need help with that