I'm having trouble with my formulas, I checked it many times but I dont seem to get the right codes to use.
I am trying to move one leg of my Hexapod with 3DOF with positions(X,Y,Z) as pos(5,3,2) to find the angles A(coxa), B(femur) and C(tibia) but it always has errors.
My guess is that, I dont have math.h library on my sketch. But when I tried to download for one, there ain't no ready made library and I dont know how to do it on ( .h ) file... so anyone has it? Or if there really is problem with my code. Here's my code: