Two articulated robots working in a shared workspace can be programmed by planning the tip trajectory of each robot independently. To account for collision avoidance between links, a real-time velocity alteration strategy based on fast and accurate collision detection is proposed in this paper to determine the step of next motion of slave (low priority) robot for collision-free trajectory planning of two robots with priorities. The effectiveness of the method depends largely on a newly developed method of accurate estimate of distance between links. By using the enclosing and enclosed ellipsoids representations of polyhedral models of links of robots, the minimum distance estimate and collision detection between the links can be performed more efficiently and accurately. The proposed strategy is implemented in an environment where the geometric paths of robots are pre-planned and the preprogrammed velocities are piecewise constant but adjustable. Under the control of the proposed strategy, the master robot always moves at a constant speed. The slave robot moves at the selected velocity, selected by a tradeoff between collision trend index and velocity reduction in one collision checking time, to keep moving as far as possible and as fast as possible while avoid possible collisions along the path. The collision trend index is a fusion of distance and relative velocity between links of two robots to reflect the possibility of collision at present and in the future. Graphic simulations of two PUMA560 robot arms working in common workspace but with independent goals are conducted. Simulations demonstrate the collision avoidance capability of the proposed approach as compared to the approach based on bounding volumes. It shows that advantage of our approach is less number of speed alterations required to react to potential collisions.