1 package com.neuronrobotics.sdk.addons.kinematics;
3 import java.util.ArrayList;
6 import org.w3c.dom.Element;
10 import com.neuronrobotics.sdk.addons.kinematics.math.TransformNR;
11 import com.neuronrobotics.sdk.addons.kinematics.xml.XmlFactory;
65 private ArrayList<IDhLinkPositionListener>
dhlisteners =
new ArrayList<IDhLinkPositionListener>();
120 l.onLinkGlobalPositionChange(newPose);
155 return "\n\t<DHParameters>\n"+
156 "\t\t<Delta>"+
d+
"</Delta>\n"+
157 "\t\t<Theta>"+Math.toDegrees(
theta)+
"</Theta>\n"+
158 "\t\t<Radius>"+
radius+
"</Radius>\n"+
159 "\t\t<Alpha>"+Math.toDegrees(
alpha)+
"</Alpha>\n"+
161 "\t</DHParameters>\n";
227 public Matrix
DhStep(
double jointValue) {
230 return DhStep(0,jointValue);
232 return DhStep(jointValue,0);
247 public Matrix
DhStep(
double rotory,
double prismatic) {
271 Matrix step = end.times(
getRotX().inverse());
272 step = step.times(
getTransX().inverse());
273 step = step.times(
getRotZ().inverse());
274 step = step.times(
getTransZ().inverse());
343 transZ =
new Matrix(
new double [][] {
346 {0,0,1,
getD()+prismatic},
349 rotZ=
new Matrix(
new double [][] {
363 transX=
new Matrix(
new double [][] {
379 rotX=
new Matrix(
new double [][] {
432 rotZ_J =
new Matrix(
new double [][] {
435 {0,0,1,
getD()+prismatic },
438 transZ_J =
new Matrix(
new double [][] {
452 rotX_J =
new Matrix(
new double [][] {
468 transX_J=
new Matrix(
new double [][] {
504 s+=
" Theta = "+Math.toDegrees(
getTheta())+
" deg";
506 s+=
" Alpha = "+Math.toDegrees(
getAlpha())+
" deg";
542 void setRootListener(Object
listener) {
640 this.slaveMobileBase = embedableXml;
void setGlobalToFiducialTransform(TransformNR frameToBase, boolean fireUpdate)
ArrayList< IDhLinkPositionListener > dhlisteners
void addDhLinkPositionListener(IDhLinkPositionListener l)
void setLinkType(DhLinkType type)
void setJacobianMatrix(double rotory, double prismatic)
Matrix DhStepInverseRotory(double rotory)
void setTransX(Matrix transX)
void setListener(Object listener)
DHLink(double d, double theta, double r, double alpha)
Matrix DhStepInverse(Matrix end, double jointValue)
Matrix DhStep(double rotory, double prismatic)
DHLink(Element nNode, LinkConfiguration newLinkConf)
void setSlaveMobileBase(MobileBase embedableXml)
void fireOnLinkGlobalPositionChange(TransformNR newPose)
MobileBase slaveMobileBase
Matrix DhStepInversePrismatic(double prismatic)
void setMatrix(double rotory, double prismatic)
Matrix DhStepJacobian(double rotoryVelocity, double prismaticVelocity)
Matrix DhStep(double jointValue)
void setTheta(double theta)
void setAlpha(double alpha)
void setRadius(double radius)
void removeDhLinkPositionListener(IDhLinkPositionListener l)
Matrix DhStepInverse(double rotory, double prismatic)
void setRotX(Matrix rotX)
Matrix DhStepInverse(Matrix end, double rotory, double prismatic)
MobileBase getSlaveMobileBase()
LinkConfiguration newLinkConf
void setMobileBaseXml(MobileBase embedableXml)
static Double getTagValueDouble(String sTag, Element eElement)