Current TCP Mismatch when RobHeld
The following code has pose1 and pose3 being offset by 1 to 2 mm, but with matching orientations.
Is this code incorrect to produce the desired equivalent targets?
Is this a 24 bit precision issue? If so, can I get CRobT or poseinv to work in dnum?
Is something funny happening in CRobT?
I have motions that must reliably position to 1.3mm spaced objects, so calculation error on this order of magnitude needs to be fixed. For reference, the base frame of the robot is not at [0,0,0],[1,0,0,0], so that's why the target can be at this location.
Hopefully it's just a problem between the keyboard and chair.
Is this code incorrect to produce the desired equivalent targets?
Is this a 24 bit precision issue? If so, can I get CRobT or poseinv to work in dnum?
Is something funny happening in CRobT?
I have motions that must reliably position to 1.3mm spaced objects, so calculation error on this order of magnitude needs to be fixed. For reference, the base frame of the robot is not at [0,0,0],[1,0,0,0], so that's why the target can be at this location.
Hopefully it's just a problem between the keyboard and chair.
PERS tooldata tool0_not_held:=[FALSE,[[0,0,0],[1,0,0,0]],[0.001,[0,0,0.001],[1,0,0,0],0,0,0]]; PERS wobjdata wobj0_held:=[TRUE, TRUE, "",[[0,0,0],[1,0,0,0]],[[0,0,0],[1,0,0,0]]]; PERS pose pose1:=[[0.000420381,-0.000173362,-0.00047082],[6.84647E-8,-2.61491E-8,-1,4.38235E-7]]; PERS pose pose2:=[[0.0335204,-0.362375,1.27074],[6.84647E-8,2.61491E-8,1,-4.38235E-7]]; PERS pose pose3:=[[0.0335206,0.362376,1.27074],[6.84647E-8,-2.61491E-8,-1,4.38235E-7]]; PROC main () pose1 := target_TO_POSE(CRobT(\Tool:= tool0, \WObj:=wobj0)); pose2 := target_TO_POSE(CRobT(\Tool:= tool0_not_held, \WObj:=wobj0_held)); pose3 := poseinv(pose2); ENDPROC FUNC pose target_TO_POSE (robtarget target) RETURN [target.trans, target.rot]; ENDFUNC
Tagged:
0
Answers
-
Hello,Can you add intermediate data so
PERS tooldata tool0_not_held:=[FALSE,[[0,0,0],[1,0,0,0]],[0.001,[0,0,0.001],[1,0,0,0],0,0,0]]; PERS wobjdata wobj0_held:=[TRUE, TRUE, "",[[0,0,0],[1,0,0,0]],[[0,0,0],[1,0,0,0]]];
PERS robtarget p_CRobT1:=[[0,0,0],[0,0,0,0],[0,0,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]]; PERS robtarget p_CRobT2:=[[0,0,0],[0,0,0,0],[0,0,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]]; PERS robtarget p_CRobT3:=[[0,0,0],[0,0,0,0],[0,0,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]]; PERS pose pose1:=[[0.000420381,-0.000173362,-0.00047082],[6.84647E-8,-2.61491E-8,-1,4.38235E-7]]; PERS pose pose2:=[[0.0335204,-0.362375,1.27074],[6.84647E-8,2.61491E-8,1,-4.38235E-7]]; PERS pose pose3:=[[0.0335206,0.362376,1.27074],[6.84647E-8,-2.61491E-8,-1,4.38235E-7]]; PROC main ()
p_CRobT1 := CRobT(\Tool:= tool0, \WObj:=wobj0); pose1 := target_TO_POSE(p_CRobT1); p_CRobT2 := CRobT(\Tool:= tool0, \WObj:=wobj0); p_CRobT3 := CRobT(\Tool:= tool0_not_held, \WObj:=wobj0_held); pose2 := target_TO_POSE(p_CRobT3); pose3 := poseinv(pose2); ENDPROC FUNC pose target_TO_POSE (robtarget target) RETURN [target.trans, target.rot]; ENDFUNCSo if p_CRobT1=p_CRobT2, then you're sure robot don't move between two lines.☑️2024 - RobotStudio® User Group0 -
The robot is definitely not moving between lines, as this is a non-motion task and the motion tasks are all set to not run. Re-running the code multiple times produces the same result.
I did some tests (below) with joint configurations also and I am getting the same weirdness. I thought it might have to do with some load compensation, so I tried setting a GripLoad with the same load as the tool for the work object, but no change resulted (not shown below).PERS tooldata tool0_held:=[TRUE,[[0,0,0],[1,0,0,0]],[0.001,[0,0,0.001],[1,0,0,0],0,0,0]];PERS tooldata tool0_not_held:=[FALSE,[[0,0,0],[1,0,0,0]],[0.001,[0,0,0.001],[1,0,0,0],0,0,0]];PERS wobjdata wobj0_not_held:=[FALSE, TRUE, "",[[0,0,0],[1,0,0,0]],[[0,0,0],[1,0,0,0]]];PERS wobjdata wobj0_held:=[TRUE, TRUE, "",[[0,0,0],[1,0,0,0]],[[0,0,0],[1,0,0,0]]];PERS robtarget crobt1 := [[0.000420381,-0.000173362,-0.00047082],[6.84647E-8,-2.61491E-8,-1,4.38235E-7],[0,-1,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]];PERS pose pose1 := [[0.000420381,-0.000173362,-0.00047082],[6.84647E-8,-2.61491E-8,-1,4.38235E-7]];PERS robtarget crobt2 := [[0.0335204,-0.362375,1.27074],[6.84647E-8,2.61491E-8,1,-4.38235E-7],[0,-1,0,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]];PERS pose pose2 := [[0.0335204,-0.362375,1.27074],[6.84647E-8,2.61491E-8,1,-4.38235E-7]];PERS pose pose3 := [[0.0335206,0.362376,1.27074],[6.84647E-8,-2.61491E-8,-1,4.38235E-7]];PERS jointtarget joints := [[66.08,76.9836,-11.6418,-0.101755,24.6229,80.7455],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]];PERS jointtarget jointpos1 := [[66.0795,76.9842,-11.6434,-0.101754,24.6238,-99.255],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]];PERS jointtarget jointpos2 := [[66.0742,77.0359,-11.6693,-0.101763,24.5981,-99.2603],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]];PERS robtarget target1 := [[0.000362654,-0.000178661,-0.000482582],[4.38419E-7,1,-2.19963E-8,-6.85313E-8],[0,-1,-2,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]];PERS robtarget target2 := [[0.137095,0.288492,1.2703],[4.38419E-7,-1,2.19963E-8,6.85313E-8],[0,-1,-2,0],[9E+9,9E+9,9E+9,9E+9,9E+9,9E+9]];PROC main ()VAR robtarget zero_target:=[[0,0,0],[0,-1,0,0],[0,0,0,0],[9E9,9E9,9E9,9E9,9E9,9E9]];crobt1 := CRobT(\TaskName:="T_ROB1", \Tool:= tool0_held, \WObj:=wobj0_not_held);crobt2 := CRobT(\TaskName:="T_ROB1", \Tool:= tool0_not_held, \WObj:=wobj0_held);pose1 := target_TO_POSE(crobt1);pose2 := target_TO_POSE(crobt2);pose3 := poseinv(pose2);joints := CJointT(\TaskName:="T_ROB1");jointpos1 := CalcJointT(zero_target, tool0_held, \WObj:=wobj0_not_held);jointpos2 := CalcJointT(zero_target, tool0_not_held, \WObj:=wobj0_held);target1 := CalcRobT(jointpos1, tool0_held \WObj:=wobj0_not_held);target2 := CalcRobT(jointpos1, tool0_not_held \WObj:=wobj0_held);ENDPROC0 -
Very weird...Can you give your RobotWare's version and robot type?☑️2024 - RobotStudio® User Group0
Categories
- All Categories
- 5.5K RobotStudio
- 396 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 250 ScreenMaker
- 2.8K Robot Controller
- 316 IRC5
- 61 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 798 RAPID Programming
- AppStudio
- 3 RobotStudio AR Viewer
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 5 Job listings