# I'm looking for a simplified control scheme for a game-rendered robotic arm

I'm a programmer, but not savvy with robotics (to lay a baseline for my lack of knowledge). I have a game-simulated arm that allows me to set joint angles which it will automatically move the joints to match, unless blocked. Thus this is a very high-level control scheme; I don't need to worry about forces and actuators directly. For my use-case I also needn't concern myself with how fast the arm can react or the servo delay.

What I need to understand is how I translate joint measurements and allowed angles into linear equations / matrices, and then how to plug in the desired end-effector location/orientation to those matrices to get the set of joint angles as an output (or an error if the desired coordinate cannot be reached with the given arm constraints). I know the full answer must be involved and long, involving multiple chapters of a robotics textbook; a high level explanation plus a pointer to freely published resources is all I'm expecting.

## 1 Answer

If I understand correctly you are not looking for a control scheme, you are tryin to solve the (inverse) kinematics problem.

In robotics, kinematics is preoccupied with motions, disregarding forces. The simplest kinematic problem, which applies in your case is the forward kinematics problem, which can be formulated as: How to calculate the position and orientation of the end effector ($$X$$) from the joint angles ($$Q$$): $$X = f(Q)$$

Solving this problem is straight forward for serial robots (the kind that you have). Explanation here

The inverse kinematics problem is the opposite of this, how to calculate the joint angles, given the end effector position and orientation: $$Q = f^{-1}(X)$$

Now this a a bit more complicates then the forward kinematics. there may or may not exist a closed form solution. In your case at the first sight it seems that you will need a numerical solution. You can take a look at Cyclical Coordinate Descent as a simple numerical way to solve the inverse kinematics problem, and advance to more advanced ways to solve it if needed.