Abstract. In this paper, a walking in-pipe robot is studied. The robot has six legs, each consisting of 3 links connected via rotary joints. The legs are attached to the robot's body. The work is focused on the problem of generating desired position and orientation for the robot's body, using a given footstep sequence. An iterative geometric algorithm for generating orientation sequence is proposed. The problem of finding the desired position of the center of mass of the robot's body is formulated as a problem of minimizing stretching of the robot's legs during steps. Also, an analytical solution for inverse kinematics problem has been given. All proposed algorithms do not require extensive calculation and use basic algebraic operations.