first of all, make sure your robot is stable and behaves correctly when passive. This is not at all the case in your situation: the various links collide with each other, and the masses/inertias of the various links is not correct. Make sure to carefully read this page, mainly design considerations 1, 2, 3, 7 and 8. Also, this tutorial might be helpful.