Results 1 to 2 of 2

Thread: COLLADA 1.5 kinematics

  1. #1
    Francois
    Guest

    COLLADA 1.5 kinematics

    Hello everyone !

    Quote Originally Posted by Anton
    Should i use <translate> tag instead of <rotate> in case i have Prismatic joint?
    yes, I think

    As far as I'm concerned, I would like to write a function that returns which visual_node/node belongs to which link and the join of the link. I am using ColladaDom. I tried but it didn't manage.

    For example :

    I have this visual scene
    Code :
    <visual_scene id="VISUAL_SCENE">
    	<node id="GREIFER">
    		<node id="OBERARM">
    		<node id="UNTERARM">
    		<node id="SCHWENKER1">
    		<node id="SCHWENKER2">
    	</node>
    these links :
    Code :
    <link name="link1">
    	<attachment_full joint="KIN_GREIFER/j1">
    		<translate>525 0 0</translate>
    		<link name="link2">
    			<attachment_full joint="KIN_GREIFER/j2">
    				<translate>525 0 0</translate>
    				<link/>
    			</attachment_full>
    			<attachment_full joint="KIN_GREIFER/j3">
    				<translate>525 0 0</translate>
    				<rotate>1 0 0 180</rotate>
    				<link/>
    			</attachment_full>
    		</link>
    	</attachment_full>
    </link>
    and this
    Code :
    <instance_kinematics_scene url="#KIN_SCENE">
    	<bind_kinematics_model node="OBERARM">
    	<bind_joint_axis target="UNTERARM/j1_axis">
    	<bind_joint_axis target="SCHWENKER1/j1_axis">
    	<bind_joint_axis target="SCHWENKER1/j2_axis">
    	<bind_joint_axis target="SCHWENKER2/j1_axis">
    	<bind_joint_axis target="SCHWENKER2/j3_axis">
    </instance_kinematics_scene>
    If I give the parameter UNTERARM to the function, it returns <link name="link1"> or <attachment_full joint="KIN_GREIFER/j1">
    If I give the parameter SCHWENKER1 to the function, it returns <link name="link2"> or <attachment_full joint="KIN_GREIFER/j2">
    If I give the parameter SCHWENKER2 to the function, it returns <link name="link2"> or <attachment_full joint="KIN_GREIFER/j3">

    I know that :
    • with <bind_joint_axis target="UNTERARM/j1_axis"> I can reach the element <node id="UNTERARM"> (Using daeSidRef(bind_joint->getTarget(), visual_instance_scene->getUrl().getElement()).resolve().elt))[/*:m:2k0da5qi]
    • with <param>param.j1.axis</param>, I can reach the element <newparam sid="param.j1.axis"> in the <instance_kinematics_model url="#KIN_GREIFER" sid="inst_kin_greifer">[/*:m:2k0da5qi]


    How can I code this function ? Thanks for help !

  2. #2
    Member
    Join Date
    Mar 2009
    Location
    Tokyo, Japan
    Posts
    88

    Re: COLLADA 1.5 kinematics

    OpenRAVE's collada reader has a function called ExtractKinematicsVisualBindings which does something similar. The function itself is pretty isolated from the rest of the code, so you can copy it and use it for your own purposes, as long as you follow the LGPL license.

    https://openrave.svn.sourceforge.net/sv ... reader.cpp
    Rosen Diankov
    Department of Mechano-Informatics, University of Tokyo
    http://openrave.org

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •