A free gait algorithm is proposed utilizing a new method of gait generation called primary/secondary gait. The primary gait is a fixed sequence of leg transfers with modified leg-end kinematic limits according to the obstacle presence, while the secondary gait is a flexible gait which is generated to adjust the leg-end position. The primary gait is generated considering the following four constraints: stability constraint, kinematic constraint, sequential constraint and neighboring constraints. Primary gait parameters are modified by the influence of the obstacle. Normally, the machine tends to move with the primary gait. When the primary gait cannot move the vehicle, the secondary
gait is adopted to serve as a complement of the primary gait. With the proposed primary/secondary gait, it is expected to improve the efficiency of free gait generation while maintaining the mobility of the vehicle. Simulation results are given to
demonstrate the efficiency of the proposed methodology.