The concept of a modular climbing caterpillar robot is inspired by the kinematics of the real caterpillar. Due to the fixed constraints between the suckers and wall, the gait of the caterpillar robot engages a changing kinematic chain which is from an open chain to a closed chain, and then to an open chain orderly. This paper investigates the joint control methods of the gait in detail. During the open chain periods, an Unsymmetrical Phase Method (UPM) is applied to ensure the reliable attachment of the passive suckers to the wall. But in the closed chain state, a four links kinematics model is adopted to fulfill the fixed constraints produced by the attached suckers. By combining the two methods together, we acquire complete joint control trajectories for a modular caterpillar robot with seven joints. At the end of this paper, on-site tests confirm the above principles and the validity of the climbing gait.