The spraying operation is one of the most important processes in which industrial robots should be used, the most important of which is spraying for the purpose of painting walls, cars, and devices, in addition to spraying insecticides on plants to get rid of agricultural pests and others. An autonomous spraying robot is intended to alleviate numerous challenges associated with hand spraying. The proposed robot is a wall painting cartesian robot's conceptual design, which includes a paint object with a spray gun and a vision system. The cartesian robot has three links which are X, Y, and Z axes. The spray gun is connected to a screw, which causes the link to move linearly. When the spray gun reaches a particular limit, the camera detects it. The robot needs an appropriate trajectory to prevent collisions with other objects, pass a defined point in spatial coordinates, and accomplish rapid and precise mobility. Through the camera, the robot coordinates mapping, identifies non-sprayable places such as windows or doors and then inspects the spraying effect. The experimental results were applied to four maps (flat map, door map, window map, door and window map, and door and window map), and the corner locations for each map were identified using the vision system. Finally, by comparing the results to the actual distance, the lengths between the corners were computed.