Gait generator for legged mobile robot