Step 19: Electronics
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.