In this study, we propose a dual-arm robot torque control strategy for real-time self-collision avoidance to avoid self-collision during the dual-arm robot motion. We construct the dynamic skeleton surround box of the dual-arm robot considering the forward kinematics of the robot arm and use it to simplify the calculation of the minimum distance between joints. According to the impedance control rule of the robot arm joint space, we design a torque control algorithm based on the distance between joints to convert it into motion to generate a collision-avoidance torque. Next, we add the collision avoidance torque to the desired torque of other tasks to obtain the actual torque to control the dual-arm motion of the robot. The experiments show that when the set rods of the dual-arm robot are close to each other and reach the collision avoidance distance, the proposed self-collision avoidance strategy generates a set of smooth collision avoidance torque for the moving joints of the robot in time to avoid the collision with itself. This verifies the effectiveness and practicality of the proposed algorithm.