Here are a few videos to keep you going: http://www.youtube.com/watch?v=engi16bLJe0 http://www.youtube.com/watch?v=engi16bLJe0&feature=mfu_in_order&list=UL http://www.youtube.com/watch?v=w6dUuGo2TO8&feature=BF&list=ULWzfGzFby4qI&index=13 http://www.youtube.com/watch?v=ygX7ukAIWn0&feature=BF&list=ULWzfGzFby4qI&index=14 http://www.youtube.com/watch?v=MyQ-N-pxh10&feature=BF&list=ULWzfGzFby4qI&index=15 http://www.youtube.com/watch?v=Xtb4wUItBFQ&feature=BF&list=ULWzfGzFby4qI&index=18 The one that started it all: http://www.youtube.com/watch?v=HGbbag9dklU&feature=related
NOTE March 2014: See link on title page to my newer Instructable on how to wire one of these up to an Arduino, with code.
Original text: There is a 5 degree of freedom inertial measurement unit (IMU) from Sparkfun. This is cheapest one they do that will do the job - a situation that is always changing by the way.
It has a 3 axis accelerometer. We will only use one of these. It has 2 solid state gyroscopes. One is used with the accelerometer (using a "combination" filter) to make the thing balance.
The other is used to allow machine to resist sudden changes in direction (one wheel hitting a pebble for example) so it does not spin you off. This is easier and more reliable possibly than using wheel speed encoders which is the other way to do this.
I like ribbon cable as it is neat. I also use blu-tack when doing this sort of soldering as it holds wire in exactly the right spot as well as holding the little circuit board still.
I tin the wire ends then solder them to the holes.