My robot hand's strong side is now ready and tested. It moves well and fast. Its commendable over serial using python program.
I'm using 3 byte packets for communication. First bit of each byte shows what type of byte it is. The whole packet contains address byte, and two number bytes. The address consists of two parts: 3 bit MCU address and 4 bit function address. I need address because I want to put several mcu-s on same communication line. The function address shows what function I want to use. Possible functions include: move x joint, ask where joint X is. Ask how much current the servos are using and so on. Number bytes are used to send one 14 bit number. So numbers from 0 to 16384 are supported. I could have used 7 bit numbers but I thought that 7 bit is not precise enough.
The hardware has potentiometers in each joint for feedback. I send the desired position over UART and software on atmega tries to move joint to there. I use soft acceleration and breaking but the software isn't perfect yet. Idea is to implement ROS support in it so I could use massive amount of inverse and forward kinematics code and 3D support in ROS.
The latest code can be downloaded from here.