Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
ik.h
00001 /* meArmIK - York Hackspace May 2014 00002 * Inverse Kinematics solver for three degrees of freedom 00003 * created for Phenoptix' meArm robot arm 00004 */ 00005 #ifndef IK_H_INCLUDED 00006 #define IK_H_INCLUDED 00007 00008 extern float L1, L2, L3; 00009 00010 // Get polar coords from cartesian ones 00011 void cart2polar(float a, float b, float& r, float& theta); 00012 00013 // Get angle from a triangle using cosine rule 00014 bool cosangle(float opp, float adj1, float adj2, float& theta); 00015 00016 // Solve angles! 00017 bool solve(float x, float y, float z, float& a0, float& a1, float& a2); 00018 00019 #endif // IK_H_INCLUDED
Generated on Tue Jul 12 2022 11:35:54 by
1.7.2