For highly complex embedded control systems, the use of traditional methods of design is very difficult to achieve satisfactory results. In a cooperative project of national 863 plans, the Matlab-based scheme in TDE (Total Development Environment) way was made to design the control system of free-flying space robot, an in-obit service satellite. It can overcome the shortcomings of traditional design to make greater system stability, improve the life of the equipment, speed up development and reduce development costs. In this paper, a development platform was built on Matlab for embedded control system of the manipulator onboard the free-flying space robot. The controller design and simulation was implemented on it. The entire development process is divided into algorithm design, system simulation, and automatic code generation. A test harness was created to test and verify the unit-under-test. The results of experiment show that Control accuracy of the simulation was satisfied with the practical requirements.