A robot program generating device includes an allowable shock value setting unit for setting allowable shock values for the joints of the robot, a joint information calculation unit for simulating the execution of a robot program in a virtual space and calculating positions and joints of the joints in association with the time a shock determination unit for determining whether the calculated shock is an excessive impact exceeding the allowable shock values, a joint information identifying unit for identifying the joints and positions of the joints in which the excessive impacts are generated, and a robot program Adaptation unit for adapting the robot program by modifying a teaching position within the vicinity of the positions of the joints in which the excessive impacts are generated so that the joints of the identified joints become equal to or smaller than the permissible shock values.
展开▼