You are on page 1of 6

Design of Kokone, a Small Humanoid Robot

Vctor E. Gonzlez1, Jos G. Ramrez2


2

Department of Computer Science, CINVESTAV-IPN, Mexico D.F., Mxico Laboratory of Information Technologies CINVESTAV-TAMAULIPAS, Cd. Victoria Tamaulipas, Mxico Phone (834) 316-6600 Fax (834) 316-6900 E-mail: vgonzalez@tamps.cinvestav.mx In the other hand, there is no systematic method to solve the inverse kinematic problem. Even when for mechanical devices with few DoF an analytical solution is possible, the general problem is difficult. For devices with a high number of degrees of freedom, the inverse kinematics can be solved via nonlinear programming methods, which we can mention Genetic Algorithms [11], Artificial Neural Network (ANN) [12] and, Simulating Annealing (SA) [13]. In this work we present the design and first results of our small humanoid robot, Kokone, developed as a robotic platform for testing our research works in the fields of locomotion, navigation and robotic vision. This paper is organized as follows: the hardware of the robot is described in section II, along with mechanical parts and control electronics. In section III the forward kinematic model is established using the Denavit-Hartenberg parameters. The inverse kinematic problem is solved using a genetic algorithm, described in section IV. The current experimental results are shown in section V. Finally, conclusions and future work are discussed in section VI. II. KOKONES DESIGN A robot is a mechatronic system that involves mechanical parts, electronic components and control software. The main goal is to achieve that all subsystems works properly for a common goal. Since Kokone must be a small-sized humanoid robot, there are some considerations to take into account: the mechanical parts must be lightweight and allow easy assemblage with other pieces and the actuators must provide the required torque to perform the movement. The interface between software and actuators will be provided by an embedded electronic control board. This component receives control commands from PC and translates it to electric control signals to be send it to the actuators. A. Mechanical Design Kokone is a small-sized robot (37 cm. heighth) and weighs about 1.2 Kg. It has 22 DoF distributed as follows: 12 in the legs, 8 in both arms and 2 for the head. The 6 degrees of freedom of each leg allow to freely moving the feet to any position and orientation in the reachable workspace. The head can make pan-and-tilt motions. The body of the robot is made of 45 aluminum pieces. Each piece was designed as functional as possible minimizing their proportions and avoiding redundant parts.

Abstract In this paper we present the design of Kokone, a small humanoid robot. Kokone (kid in nhuatl, a mexican dialect), has 22 degrees of freedom (DoF), with an aluminum structure (1.5 mm thickness). A PC sends control signals to the robot via a serial link. The forward kinematics model is obtained with the Denavit-Hertenberg method. The inverse kinematics problem is solved using a genetic algorithm (GA). The solutions obtained by the GA are then plotted in order to verify their suitability, and show a good performance. Our main objective with this project is to obtain as affordable robotic platform for the development of robotic vision algorithms and navigation strategies. Keywords Biped locomotion, inverse kinematic, genetic algorithm, humanoid robot.

I. INTRODUCTION In the last years, there are many progress made on the construction of specialized robots, particularly humanoid robots. Humanoid robots are very interesting for many reasons, like adaptability and human interaction. Indeed, a wheeled mobile robot is not well suited to navigate through a common human environment, where stairs and moving objects are difficult to consider. Also, people seem more open to interact with a robot with human appearance [1]. The new technologies on materials and the increase of computing performance have allowed the development of advanced robots like ASIMO [2], HUBO [3], HRP-3 [4] and REEM-B [5]. A main drawback of these robots is their high cost, so very few research institutes can afford these machines. For this reason, small humanoids robots are a very good choice for testing control strategies, interaction schemes and navigation algorithms. We can cite, among others, HR-2 robot [6], TAO-PIE-PIE robot [7], ZORC robot [8] and Andy Droid robot [9]. These robots were built with low cost materials and affordable electronic devices. A robot (or a part of it) can be modeled as a chain of links connected by joints (rotative or prismatic). The motion of the end-effector depends of the motions of the links, and generally the number of joints corresponds to number of degrees of freedom (DoF) of the robot. A frequent topic in robotics is to obtain the localization of the end-effector when the joint positions are known (forward kinematics), and to determine the joint positions for a given localization of the end-effector (inverse kinematics). In [10], Denavit J. and Hartenber R. proposed a systematic method to assign local frames to the links in order to obtain the forward kinematic model of an open kinematic chain.

Since one of our main objectives is to design a low cost robot, the pieces are cut from commercially available aluminum profiles, so no additional machining is required. The motors are mounted on bridles, and the bridles are assembled to form the arms and legs of the robot. The Kokones general concept and the design in CAD software are show in Fig. 1. The distribution of the motor was made to obtain an anthropomorphic design, as well as to reduce the number of pieces and an easy assembly. The type of motor used in our robot is Blue-Bird 1 servomotor BMS380MAX. Some features of this motor are shown in Table 1. B. Electronics The control of the motors is made by a SSC-32 Lynxmotion 2 servo controller board mounted on the robots back. The board is based on an Atmega168 ATMEL 3 microcontroller, and provides the pulse width modulation (PWM) required to control the position of each of the 22 servomotors. The PWM signal consists of positive going pulses ranging from 0.9 to 2.1mS. (milliseconds) long, repeated 50 times a second (every 20mS). A position value of 500 corresponds to 0.50mS pulse, and a position value of 2500 corresponds to a 2.50mS pulse. The positions commands for the motor are received from a PC via a serial link at 115200 baud rate.

TABLE I SOME FEATURES OF BMS-380MAX SERVOMOTOR


BMS-380MAX Servomotor Item Weight Torque at 4.8 Volts Speed at 4.8 Volts Running current Metal gears Value 16.4 4.2 Kg/cm. 0.16/60 290 mA. Yes

The motors are driven using a switched power supply, while the control board is driven by a 9VDC battery, in order to avoid the noise on the voltage line, caused by PWM required by the motors. On the PC side, the positions commands are computed by a program (written in C language) and send to the control board via the serial link. The format of a position command in ASCII is the following: #<ch>P<pw>S<spd> . . . #<ch>P<pw>S<spd>T<time> <cr> <ch> = Chanel number in decimal, 0 31. <pw> = Pulse width in microseconds, 500 2500. <spd> = Movement speed in S per second for one channel. (Optional). <time> = Time in mS for the entire move, affects all channels, 65535. (Optional). <cr> = Carriage return character, ASCII 13 (Required to initiate action). III. FORWARD KINEMATICS For Kokone, during a walk we need a mathematical model to describe the position and orientation of feet in respect to the body, such that when the bodys position is given, the whole robots configurations is defined. In order to obtain this model we use Denavit-Hartenberg method to establish the local frames for each link in the kinematic chains (legs). The local frames are shown in Fig. 2. A homogeneous transformation matrix T is a 4x4 matrix that transform a vector in homogeneous coordinates from a reference system to another reference system. We can see T like a matrix composed by 4 submatrices:

Fig. 1. The Kokones general concept and the design in CAD software.

T=
1 2

r3x3 p3x1 Rotation Traslation = f1x3 w1x1 Perspective Scaling

(1)

http://www.blue-bird-model.com http://www.lynxmotion.com 3 http://www.atmel.com/

Where r3x3 is the rotation matrix, p3x1 is the translation vector, f1x3 represents a perspective vector and w1x1 is a scale factor. In our case, the components of f1x3 are considered 0, and the w1x1 is 1. With this tool we can know exact location at in a single mathematical structure.

TABLE II DH PARAMETERS OF BOTH LEGS OF KOKONE i Left Right d a Legs 1 0.0 0.0 90 1 2 90 -4.3 0.0 2 3 0.0 -6.1 90 3 4 0.0 -6.1 90 4 5 0.0 -3.3 90 5 6 0.0 -2.0 90 6 AL0 = 6 AR0 = 6
i-1 i=6 i=1 ALi i-1 i=6 i=1 ARi

(3) (4)

In order to model the homogeneous transformation 0 between the feet and the robots body, the AL0 and 6 6 matrices should multiplied by 2 translation matrices ALT and ART , in order to attach them to the robots body. Equations 5 and 6 shows above.
Fig. 2. Local frames for each link in the kinematic chains (legs), obtained by D-H method.

ABL = ALT AL0 6 ABR = ART AR0 6

(5) (6)

By using the Deneavit- Hartenberg method, we obtain the homogenous transformation matrices between two successive links i - 1 and i for each kinematic chain. These matrices are given by the equation 2. cos i - cos i sin i sin i sin i ai cos i sin i cos i cos i - sin i cos i ai sin i 0 sin i cos i di 0 0 0 1
i-1 Ai

When the robots body position and orientation with respect the world frame ABody is known, we can establish the orientation and position of the feet with respect to the world frame: ALFoot = ABody ABL ARFoot = ABody ABR (7) (8)

i-1 Ai =

(2)

Where: i = is the angle formed by the Xi-1 and Xi measured in a plane perpendicular to the Zi-1 axis using the right hand rule. di = is the distance along the Zi-1 axis from the origin of i-1 reference system to the intersection of Zi-1 with Xi . ai = is the distance along Xi axis from the intersection of Zi-1 with Xi to the i reference system. i = is the angle of separation between Zi-1 axis and Zi , measured on perpendicular plane to the Xi axis using the right hand rule. For Kokone, the D-H parameters are given in Table 2. At the end, we obtain two kinematic models: one which describes the position and orientation of the frame attached to the right foot with respect to the base frame (attached to the right hip), and one which describes position and orientation of the left foot with respect to the base frame. Indeed, we calculate the AL0 and AR0 matrices with respect n n to the reference system 0, using equations 3 and 4. Now, with given values for the articular parameters = 1 , 2 , n for each leg, we can find the exact location of both feet with respect to the reference system of real world. IV. INVERSE KINEMATICS In our case the problem of inverse kinematics is to find a = 1 , 2 , for a specific location of the robots feet and body. The location of the left foot, right foot and the body, with respect to the world frame, are defined by ALFoot , ARFoot and ABody respectively. We can compute the relative position and orientation of both feet with respect to the bodys frame: AL0 = ALFoot -1 ABody 6 AR0 = ARFoot -1 ABody 6 (9) (10)

The inverse kinematic problem has been treaty by GA since 1989 [14] obtaining good performance. We use this technique for its easy implementation and good results. A. Genetic Algorithm Given the position and orientation of the robots body and feet on the world frame, the inverse kinematic problem involves a nonlinear equations system with 12 parameters. We propose the use of a genetic algorithm to solve this problem. A genetic algorithm (GA) is an iterative search method based on the theory of evolution and natural selection proposed by Charles Darwin. Given an environment that can host only a limited number of individuals, natural selection favours those individuals that are better adapted or fit to the environmental conditions best [15]. This ability to survive is stored in chromosomes, the genetic structures of the individual. Given a way to represent n chromosomes of length L and an evaluation function the GA must find values for the chromosomes that enhance the ability of individuals. This is achieved by applying genetic operations (crossing, mutation, selection and elitism) on individuals of the population. The general approach of a genetic algorithm is shown in Algorithm 1. ALGORITHM I
GENERAL APPROACH OF A GENETIC ALGORITHM

B. Solving Inverse Kinematics For Kokone, the individuals of the GA are represented by 12 chromosomes, one for each DoF of the legs. Due to the type of movements that the human leg can make, we narrow the range of variables in order to obtain consistent movements. The ranges of each variable are given in Table 3. The evaluation function (how good an individual is, or fitness) is given by the error between the position and orientation of feet represented by the individual, and the given position of feet All figures, tables, and equations must be included in-line with the text. Do not use links to external files. AL0 -ALFoot _1 ABody + AR0 -ARFoot _1 ABody 6 6 (11)

Algorithm 1
Require: pm and pc t0 Initialize(Xt ) {Initialize population ramdomly} repeat F = Fitnes(Xt ) {For all individuals} ' X = Selection(X, F) {Selects the best individuals according to their fitness} ' ' X = Crosses(X , Pc) {For all individuals according to Pc} ' ' X = Mutate(X , Pm) {For all individuals according to Pm} tt+1 ' Xt = New_population(X ) until Stop condition

In our implementation of the genetic algorithm, we use a two points crossover operation. Randomly we choose two numbers among 0 and the number of chromosomes; these are the points that indicate which sets of chromosomes will be merged. We use a probability of crossing Pc = 0.7. In order to find accurate solutions we use a modified mutation. The main idea is to narrow the search space generating a Gaussian number and using the chromosomes of the best individual as a mean. To define the value of standard deviation , we add some knowledge about the problem to the mutation. If the fitness of the individual is greater than fitness 1.0 we consider = 0.1 in other case we consider = . 1.5 Based on the experiments we calculate these values by obtaining good performance. The probability of mutation is Pm = 0.3 and the population consists of 100 individuals. When the fitness of the best solution is less than 0.007 the genetic algorithm stops and the inverse kinematic problem is solved. We consider 0.007 as a good approximation based on the resolution of the servomotors. TABLE III RANGES VARIABLES
1, 2 3, 4 5, 6 7, 8 9, 10 11, 12 Value 45 to 135 45 to 135 45 to 135 -90 to 0 -45 to 45 -45 to 45

Crossing is a binary operation that merges chromosomes (information) from two parents into one or two offspring. Is a stochastic operation in two ways: the choice of when applying the operation and what chromosomes are combined. The mutation is a variation in one or more chromosomes of the individual. Similarly to crossing, is a stochastic operation, the choice of when applying the operation and what chromosome is changed. The role of survivor selection is to distinguish individuals based on their quality, in particular, to allow the better individuals to become parents of the next generation. Elitism is to preserve the best individual in the population for all generations.

IV. QUASI-STATIC MOTION At present, the desired At present, the desired positions and orientations for robots feet and body are obtained from concepts of static bipedal walking, as a sequence of values for a quasi-static motion.

As stability criteria, static biped walking keep the projection of the center of mass within the support polygon of the foot at all time, these concepts are shown in Fig. 3. A walking cycle can be divided into single support phase and double support phase. In the single support phase, One foot support the robots weight while the other foot is moving on the air from backward to forward. The simple support phase begins when the foot in movement leaves the floor and lift on the air and finishes when returns to the floor. The double support phase begins when the foot in movement (at single support phase) touches the floor and ends when the foot at the floor (at single support phase) leaves the floor [16]. To achieve Kokone make a simple walking gait, we use a number of stable positions and the locomotion is performed by repeating these positions.

To lower the robots body 0.5 cm. we define the homogeneous transformation matrices 12, 13 and 14. These matrices are the location of the feet and robots body. The solutions found by the genetic algorithm are shown in Table 4. TABLE IV
RANGES VALUES 1, 2 3, 4 5, 6 7, 8 11, 12 Value 90 90 107 -32 0

0.0 0.0 1.0 0.0

0.0 -1.0 0.0 0.0

1.0 0.0 0.0 0.0

0.0 0.0 21.3 1.0

(12)

0.0 0.0 0.0 -1.0 1.0 0.0 0.0 0.0 0.0 0.0 0.0 -1.0 1.0 0.0 0.0 0.0

1.0 0.0 0.0 -2.25 0.0 0.0 0.0 1.0 1.0 0.0 0.0 0.0 0.0 2.25 0.0 1.0

(13)

Fig. 3. Concepts of static biped walking

(14)

V. RESULTS For each stable position of the static walking, the genetic algorithm solves the inverse kinematic problem. In order to verify whether the solutions are correct, we plotted by a Matlab program. To draw all links of the legs, the program replace solutions into the 12 homogeneous transformation matrices obtaining the exact location of each link. The main goal is to ensure that solutions are consistent before they are sent to the robot. Some solutions of a simple static walking are shown in Fig. 4.

A. Implementing Solutions on Kokone. After verify solutionss suitability, they are ready to be sent. A program written in C translates solutions to positions values for every servomotor. The command position is formed by the positions and the time in mS for the entire move, and then the command position is send to the robot by serial link. Fig. 5 and Fig. 6 shown some moves performed by the robot.

VI. CONCLUSIONS AND FUTURE WORK The design of Kokone, a small humanoid robot was presented. The main goal is to build a low cost and lightweight robot. The embedded servo controller board provides an abstraction of the low level control, allow us focus on kinematics problems. We use the DenavitHartenberg method to obtain the forward kinematics model. We proposed a genetic algorithm to solve the inverse kinematic problem of the robot. In order to achieve accurate results, we add some knowledge to the algorithm when mutation is applied with good results.
Fig. 4. Some solutions of a simple static walking.

To calculate the positions and orientations of the feet and robots body we use static biped walking, for that reason walking is a bit slow and every step take several seconds. One advantage of using nonlinear programming methods for solving inverse kinematics is that we can use a better heuristic to find solutions quickly. The robot Kokone can be used as an educational test platform for the development of robotic vision algorithms, navigation strategies and biped walking controllers. One or two cameras can be mounted on the robots head to provide a robotic vision system, the robots head is ready to perform pan and tilt movements. In order to improve biped walking some strategies can be implemented. We can use a model based on inverted pendulum to calculate the position and orientation of the robots body, moreover, Kokone is able to use an external sensors, like accelerometers and gyros. The embedded control board has 4 inputs that can be configured as digital or analog inputs.

REFERENCES
[1] M. Wahde and J. Pettersson, A brief review of bipedal robotics research, 8th Mechatronics Forum International Conference, pp. 480-488, 2002. [2] Y. Sakagami, R. Watanabe, C. Aoyama, S. Matsunaga, N. Higaki and K. Fujimura, The intelligent ASIMO: System overview and integration IEEE International Conference on Intelligent Robots and Systems, Lausanne Switzerland, pp. 24782483, 2002. [3] J.-Y. Kim, I.-W. Park and J.-H. Oh, Online biped walking pattern generation for humanoid robot KHR-3 (Kaist Humanoid Robot3: Hubo), Humanoid Robots, 6th IEEE-RAS International Conference on, pp. 398403, 2006. [4] F. K. G. M. Kenji KANEKO, Kensuke HARADA and K. AKACHI, Humanoid robot hrp-3, in IEEE/RSJ International Conference on Intelligent Robots and Systems, Sept, 22-26 2008. [5] S. Garca, et al. REMM-B: An autonomous lightweight humansize robot, 8th IEEE-RAS International Conference on Humanoid Robots, pp. 462-464, 2008. [6] A. Heralic, Design and control of the prototype humanoid robot hr-2, Chalmers University of Technology, Tech. Rep. 2005. [7] J. B. Sara McGrath and J. Anderson, Active balancing using gyroscopes for a small humanoid robot, in second International Conference on Autonomous Robots and Agents (ICARA), S. C Mukhopadhyay and G.S. Gupta Eds., December 2004, pp. 470475. [8] J. Ziegler, K Wolff, P. Nordin and W. Banzhaf Constructing a small humanoid walking robot a as platform for the genetic evolution of walking in Proceedings of 5th International Heinz Nixdorf Symposium: Autonomous Minirobots for Research and Edutainment, U. Rckert J. Sitte, and Witkowski, Eds., No 97. Heinz Nixdorf Institute 2001, pp. 51-59. [9] A. Boeing, S. Hanham, T. Brunl, Evolving autonomous biped control from simulation to reality, International Conference on Autonomous Robots and Agents, ICARA, Palmerston North, New Zealand, pp. 440-445(6) Dec. 2004. [10] D. J. and H. R. a kinematic notation for lower-pair mechanism on matrices, ASME Journal of Applied Mechanics, pp. 215221, 1955. [11] L. F. Giraldo, E. Delgado, G. Castellanos, Inverse kinematics of a robot arm using genetic algorithm, (in Spanish), Avances en sistemas e informtica, vol. 3, no. 1, pp. 29-34, 2006. [12] Z. Bingul, H. M. Ertunc and C. Oysu Applying neural network to inverse kinematic problem for 6r robot manipulator with offset wrist, Adaptive and Neural Computing Algorithms International Conference Coimbra, Portugal, pp. 112-115 2005. [13] M. S. Dutra, I. L. Salcedo, L. M. Prieto, New technique for inverse kinematics problem using simulated annealing, International Conference on Engineering Optimization EngOpt, Rio de Janeiro, Brazil, 2008. [14] J. K. Parker, A. R. Khoogar, D. E. Goldberg, Inverse kinematics of redundant robots using genetic algorithms, Robotics and Automation IEEE International Conference on, pp. 271-276 vol. 1. May 1989. [15] A. Eiben and J. Smith, Introduction to evolutionary computing. Springer 2003. [16] R. R Erikc Cuevas Daniel Zaldvar, Walking trajectory control of a biped robot Universidad de Guadalajara, CUCEI, Tech report B-04-18 2004.

Fig. 5. Start position.

Fig. 6. Left leg up.

You might also like