Kondo KHR 3 Robot Mods

A good start to building robots

An Introduction

This was my first official robot project. I bought this bipedal humanoid robotics kit at one of the many Robot Shops in Akihabara, Tokyo during a trip to Japan on my 2nd sabbatical in 2010. When I returned from Japan and started assembling this kit, I realized a few things. I realized that this robot was just the beginning, and that I could spend a lot of time modifying, adding, and learning about technologies that could be used to enhance my robot. 

Early Work

After finding the latest English translations of the software and assembly instructions, I spent about 11 hours assembling the standard unit. Once assembled, I started to find the limitations of the basic kit. I wanted to expand it. 

Expanding the KHR3

I began checking out other controllers that I might add to the KHR3’s backpack. I looked at things like the Arduino Pro Mini, different sensors, cameras, etc. I learned the pros and cons of different platforms and ecosystems. I needed something pretty powerful to add balance, vision, and higher level functions. I ended up with an ARM based Gumstix board (Overo-Fire). This was just before the Raspberry Pi was introduced in 2012.

What’s the Goal?

This robot was always meant as a learning vehicle for me. It really was what got me started in the “making” space, Linux, Python, and a host of other things. I purchased a CNC shortly after to build aluminum parts for accessories for the KHR3. It’s amazing what one small project can be the seeds for. I’ll continue working on the KHR3 and from time to time update this project page. Stay tuned.

I can’t overstate the importance, to me, of this project. It kicked off so many valuable experiences over the last 10 years of my journey into Robotics. From my experience at the Intel Galileo product launch at the Rome Makerfaire, to the creation of the Intel Joule microcontroller. Not to mention all the technologies that I was exposed to, mentioned above. And really, that’s just a start, there are so many other experiences I’ve had because of this little guy. Let me know if you have any questions. mwalker@icecodeatl.com

This project was overall about Robotics, but it really made me understand the interdependence between software and hardware. Robotics is all of the servos, and sensors, and PID loops, and system design, but it is also, maybe more importantly, getting those things to work together and integrate in such a way that the whole system works to meet your goal. It’s a complex system and has to be looked at from that perspective. With that idea in mind, I ended up taking the Architecture of Complex Systems, MIT Professional Education online course. It really helped clarify the idea of a seemingly simple robot being a complex system.

I really dug into motors here, and in particular, servos. Before this I was pretty aware of servos, stepper motors and regular brushed motors, but this really hyper focused on servos. In particular, the Kondo servos are serial based, as opposed to PWM controlled. The Kondo servos are small, fast, and pretty powerful. They require a particular controller, but give lots of feedback data to manage their movement, power draw, etc. You almost have to use this type of servo, as opposed to hobby (PWM) servos to accurately control a robot. Once I completed the KHR-3 kit, I was able to hook up the robot to a host computer running the Heart-2-Heart software, and get the robot to do some of the pre-programmed movements. It could walk forward and backward a number of steps, sideways, do a headstand, get up from a fall, etc. This was great seeing it move, but I wanted it to do more.

Interfacing Protocols (I2C, SPI, USB, Wifi, BT)

After getting the basic kit up and running, and controlling it via a host computer, I wanted to figure out how to shrink the host computer and put it in the KHR-3’s backpack. I started looking into various controllers that might be able to fit, and might be able to control the unit. The KHR-3 comes with a built in Renasas based I/O controller to output to each servo, and manage power. All other controls are done by the host. I started with various Arduino based controllers, then moved to a small ARM based controller (Gumstix Overo Fire). The Overo, was very functional and was able to do quite a bit. It also forced me to understand how to interface between the I/O controller, the additional I2C based sensors, USB camera, and I2C based IMU sensors. 

Python, C, C++

Around this same time, I was looking for a computer programming language that would be best to learn for Robotics. I was already pretty familar with C and C++. I had known and been working with C since high school! and C++ since college, although, I never really considered myself a programmer. In order to make things work some code was needed. I couldn’t really afford to not dive into the coding. Some things were written in C/C++, some things came in a new language that I encountered – Python. Python was a welcome addition to my coding skillset. Not quite as fast as C/C++ but really powerful and, as I discovered, has tons of extending libraries and extensions. Python is a great language to learn if you plan on building robots.

Computer Vision

One of my big goals was to give the KHR-3 the ability to “see”. By adding a USB camera to the Gumstix Overo Fire microcontroller, I could get basic images into the system. From there I need some way to determine what the robot was seeing and make it to react to those images. I happened upon the OpenCV framework and was able to write a few programs illustrating the capability to look around and detect a potential direction to move. An example of this was if the robot was put in front of a lined path, such as common line-follower course, it would be able to determine the direction to walk and follow the line. Using the Hough lines transform in OpenCV the KHR-3 could capture an image from the Webcam, then pick out the line immediately in front of the robot, and move in that direction and repeat until done. 


PID controllers or algorithms are very powerful in Robotics. Figuring out how to make a robot, or other robotic device balance, for example, is where PIDs are critical. I wanted to make the KHR-3 more robust when walking. I wanted it to be able to take a bit of a jar without immediately falling over. I wrote a basic ‘P’ (just the porportional portion) routine in C that read the IMU and controlled the servos based on the goal of keeping the robot upright. It sorta, worked! I thought it was pretty amazing until too much of a push caused the servo to oscillate back and forth almost out of control. I needed something else. I needed the other letters in the PID controller, the ID. I was able to crudely code a PI controller that was able to stablize the robot standing still more quickly and without the runaway servo issue. This was just the first steps and visibility into the world of Kinematics. More to come in the ROS section.


When I first interfaced the Gumstix Overo Fire to the KHR-3’s I/O controller, I needed some software that would run on the Overo to allow it to talk to the I/O controller. I was able to find libkondo (https://bitbucket.org/vo/libkondo4/) that was being written by Christopher Vo to interface with the I/O controller. (You can see some of my committs above :)) This was an amazing find, and was exactly what I needed to really dig into the KHR-3. This started the deep dive into programming the robot outside of Heart2Heart.


Another huge discovery for me around this time was that there was a whole ecosystem of software and tools that could be used to program, monitor, simulate, debug, share capabilities and network the robot with other sensors and platforms on a network. This was amazing to me. This is one of the reasons ROS (Robot Operating System) is critical in the Robotics world. It is notorious for having a steep learning curve, but after working with it for a couple of years I’ve become pretty proficient. ROS led me to enroll and complete the Udacity Robotics Engineer Nanodegree. The experience from which has been indispensable. 


Heart 2 Heart is the original software that comes with the Kondo KHR-3 robot. It runs on a Windows based host platform and allows you to control the KHR-3, run preprogrammed actions. My goal was to make my KHR-3 somewhat autonomous. I had to replace H2H with my own software and host computer in order to add functionality.