Pi Robot

I have made a pi robot that is controlled by a wii remote. It’s quite slow and doesn’t move straight but I might be able to fix that. I started with a pi robot kit and bluetooth adaptor from ryanteck, a raspberry pi 2, a pi battery, and a wii remote. I learnt how to hack wii remotes from a book called Raspberry Pi Projects for the Evil Genius. This isn’t the finished robot though, I’m planning to add a lego case and some LEDs that act like headlights.

How to use:

  • Once the robot starts spinning, press the 1 and 2 buttons on your wii remote and make sure the remote LEDs stay flashing until either the robot stops or the wii remote starts vibrating.
  • If the wii remote vibrates, you have connected successfully; wait until the remote stops vibrating, then you are in control.
  • If the robot stops and the remote didn’t vibrate, you have failed to connect and you should reboot the pi.
  • Once you are in control, you can use the following controls:
    Button to press what happens
    Control pad Moves/turns in the appropriate direction(as of holding the remote sideways)
    A Lets robot wander until you press B (this automaticly happens when you leave the robot idle for long enough as well)
    plus Releases control until you hold minus for long enough
     B  Lets you choose and run a pre-made program
     –  Enters debug mode, this means that status messages will be printed to the terminal while disabling the actions of A and B. In debug mode, if the robot is idle for long enough, instead of wandering, it will simply release control like you pressed +
    home  Exits the program


Power required to run pi 5V 1A
Power required for motors 4×1.5V AA battery
Approx. forward speed 8 cm/s
Approx. turning speed 90 degrees/s

Information about the program

The program has been written in two different programming languages, C and python.
The main control program has been written in python and it calls the C programs that control the robot.


7 thoughts on “Pi Robot

  1. This is really great!

    I love the way that if you ignore the robot it gets bored and goes wondering around. I’m pretty much the same myself.

    Of the two programming languages (C and Python) which do you prefer and why?

    Liked by 1 person

    1. Hi HackerJimbo. I’d say I prefer python because it’s very hard to change variables to different types in C, and also that reading input is hard with C as well. Python isn’t this strict and has many useful functions built-in, unlike C which requires you to have iostream.h installed just for text output.


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.