The "full blown" gives PID control over speed parameter, pretty much as the "Cruse Control" feature found on modern cars.When mechanicaly loaded, the system will increase PWM in an attempt to maintain "actual speed" at "target speed" level.This is the only way to run at low speed (20 RPM) while maintaining a high torque"Actual speed" is computed based upon the encoder informations, acquired in an interrupt routine.Voltage ("low bat" warning) and current (overheating) are also continuously monitoredSpeed and direction of rotation are adjustable through computer keyboard

Robot body is nearly finished, waiting for the 12V battery to be placed on the top

Angle measurement is performed with a 5 DOF IMU (2 axis Gyroscope + 3 axis accelerometer)http://www.sparkfun.com/commerce/product_info.php?products_id=9268The sensors board is located between the wheels, near the rotation axis

Actually motor encoding is not required for balancing.This feature can be added later on to prevent robot from drifting forward or backward

wheel encoder: http://www.mindspring.com/~tom2000/Delphi/Codewheel.htmlKalman filter: http://en.wikipedia.org/wiki/Kalman_filterPID conrol: http://en.wikipedia.org/wiki/PID_controllerthose documents are "hard theory" and do not need to be fully understood for implementing the project

Accelerometers are used to sense both static (gravity) and dynamic (sudden starts/stops) acceleration - in m/s² or g. Gyroscopes measure angular velocity, how fast something is spinning about an axis - in RPM, or degrees per second.Accelerometer data are noisy, Gyros tend to drift; the combination (data fusing) gives usable information

I know you are going to get swarmed for your code for the Kalman, but I am really struggling getting this to work. Can you detail how you went about this? Was the programming intensive? ...

Hi Gibby623, sorry, I just got your PM'sIf your robot rolls about the x axis, you only need GYR_X, ACC_Y and ACC_ZI notice that signal quality is much better when the sensor is upward, apparently, the IMU does not appreciate to be up side downI will publish the full code pretty soon