technician13 / quadrupedinversekinematic Goto Github PK
View Code? Open in Web Editor NEWInverse Kinematic of Quadruped Robot Leg
Inverse Kinematic of Quadruped Robot Leg
个人背景:四足机器人小白,在学习正逆运动学相关的概念
我在运行正运动学https://github.com/Technician13/QuadrupedForwardKinematic代码后,将计算的结果直接赋值代入逆运动学代码https://github.com/Technician13/QuadrupedInverseKinematic,发现两者并不相等,十分疑惑,恳请赐教!
我假设的单腿参数为h=5,hu=20,hl=20
,开始状态的三个电机值都为0,即gamma=alpha=beta=0
运行正运动学,得到的结果如下:
The result is:
LEFT:
The X-axis: 5.35898e-07
The Y-axis: 5
The Z-axis: -40
RIGHT:
The X-axis: 5.35898e-07
The Y-axis: -5
The Z-axis: -40
Press any key to continue . . .
根据这个结果,我认为这个时候的腿的初始状态是竖直下垂的。如readme中的图所示一样
但是,我把上述的数据(选择了右腿RIGHT)代入逆运动学的代码。赋值如下
pos_x=5.35898e-07;
pos_y=-5;
pos_z=-40;
h=5;
hu=20;
hl=20;
运行后得出以下结果
The result is:
LEFT:
The first joint angle rotation angle L_gamma: 0.24871
The second joint angle rotation angle alpha: -0.785398
The third joint angle rotation angle beta: 0.000604872
RIGHT:
The first joint angle rotation angle R_gamma: -7.45058e-09
The second joint angle rotation angle alpha: -0.785398
The third joint angle rotation angle beta: 0.000604872
Press any key to continue . . .
将弧度值换成角度值,有R_gamma= -4.26887e-07,alpha= -45,beta= 0.0346566
其中的alpha
的值明显不是正运动学设定的0。
对于两者正逆运动学对比的结果不一致,我不是很理解,还是说逆运动学解算的初始位置并不是竖直下垂的,而是有一定的角度值偏移?恳请赐教,万分感谢!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.