Hi Uffi,
Regarding my implementation: no, I am working on a C-code implementation for the ATMEGA16 to be compiled with win-avr or gcc, resp.
Oh crap, yet another C implementation....and not even for PIC... ;-) I've started to look at C for PIC's but that's not a topic for this forum.

Yes, the Kalman code comes from the UAV project. I have not had time to work on implementing your formulas yet but thanks for the pointer on the sign of the acceleromter readings. I'm not sure the accelerometer formulas will work with the sensor I got now. It is a two axis accelerometer, X and Y but I'm not sure how it will respond if mounted so it "becomes" X & Z. I will have to experiment with that too.

I got the SHARP sensors yesterday and managed to get the robot balancing fairly well. It's still a little "nervous" but I think I'll get it better by filtering the readings and/or experimenting with the sensors mounting. The goal, however, is the acceleromter/gyro aproach since the SHARP sensors introduce too many drawbacks IMO. But hey, atleast it works!

Thanks!
/Henrik Olsson.