2008-06-15

Motoman robot controlled by two Wiimotes



Some time ago I controlled a robot with a Haptic.

Inspired by Johnny Chung Lee I started to work on controlling the Motoman industrial robot using two Wiimote infrared cameras. It's a bit less accurate method than using Haptic, but it's much cheaper.


What you need:

  • a robot (or whatever you'd like to control)
  • two Wiimote devices
  • a software (okay, here's the source, but beware, it's beta, work in progress, not finished and hackish)
  • a pen with two infrared diodes
The main problem is that normal infrared diodes are directional. But for this project we need to see the diodes from the side. Normal diodes are only seen from the front. I found that the diode CQY36 is perfect (the first pen below, black one). The other solution is to use two SMD KP-3216F3C diodes (the second pen below).


Both pens have a meomentary switch, so I can turn the leds on when I want to move the robot arm. Unfortunately on the videos you can't see when the leds are lighting, so it can be confusing that sometimes the move of a pen is moving the robot and sometimes not.

First video (rotation on the Y axis is flipped and the video ends with a robot failure):


Other videos:



8 comments:

Christopher said...

That is pretty cool. I am interested to know what the interface between the robot and the computers is; is it serial? And are you able to control the robot from a Linux box?

majek said...

> That is pretty cool.
Thanks! I also like this project very much.
The funny thing is that the guys from
University of Cambridge did the same thing.
(okay, the wiimote part, not the robot part)

> I am interested to know what the interface
> between the robot and the computers is; is
>it serial? And are you able to control
> the robot from a Linux box?

That is a bit complicated.
Most of the industrial robots can't be controlled
from a computer. Fortunately our robots have additional board, which is programmable. Using this board and a serial connection to we are able to control the robot from a computer.

Christopher said...

You are using a Turbo Function card or similar? The reason I ask is that I am a PhD student in Australia, and I have access to a Motoman arm with an NX100 controller. I want true real-time control and I don't want to do it with Windows (I'm a Linux programmer more than a Windows one!).

majek said...

> You are using a Turbo Function card or similar?

Yes. I thought that nobody else really knows what it is. I was really tired with compiling software for Turbo card on old windows. So I moved the compiler stack to Linux.

The Turbo card has "realtime mode", so you can control a robot in dynamic way.

If you have the Turbo card and if the card is similar to ours, I'd be happy to help you.

Try to catch me using Google Talk gadget.

Unknown said...

Wow! You have done a lot of integral things on the Motoman! I recently wrote a website interface for the Motoman XRC for my final year project.
I used a Barionet automation device (www.barix.com) that can run it's own code and has a serial port interface. Took me a while to get the communication going!

I was wondering: why don't you try and use the accelerometer of the Wiimote to move the motoman? It has pitch, roll and three axis. Might be interesting to take that approach.

Good luck with all your other projects!

majek said...

> I was wondering: why don't you try
> and use the accelerometer of the
> Wiimote to move the motoman? It has
> pitch, roll and three axis. Might
> be interesting to take that approach.

The problem with Wiimote accelerometer is it's low accuracy. I returns only a byte (256 values) for range of something like 10G acceleration. It's not enough to get any reliable data. You really can get only rough information that a Wiimote has been shaken.

Unknown said...

Great Job!

have you considered, maybe putting the wii-mote underneath the table? from the videos, it seems like the robot had some difficulties interpreting some of the motions.

majek said...


> pk_volt said...
have you considered, maybe putting the wii-mote underneath the table? from the videos, it seems like the robot had some difficulties interpreting some of the motions


I haven't thought about that! That's a very good idea. Hooking up 3rd wiimote is also not difficult.