Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5

Instruction MoveC target

#1
Hi!

I'm writing a custom post processor.  I wrote a small function which calculates the tool paths' lengths. For this I use the RDK Instruction() function. It works well with Joint and Linear movements. 
If the movement type is Circular, I get "NONE" value. 

How could I get the MoveC instruction's target poses?
#2
You should use Cartesian targets for your MoveC commands, not Joint targets.

Alternatively, you can force generating Cartesian targets by specifying it with your settings here:
  1. Select Tools-Options
  2. Select the Program tab
  3. Set Output for circular movements to Cartesian data
#3
Thank you for the suggestions.

We already use Cartesian targets for the MoveC commands in the post. 

I also tried to set the Output for circular movements to Cartesian Data in RoboDK (then restarted the program)

Neither of these work, I still get None :(
#4
Can you share the post processor and a test RDK file to reproduce this issue? We can help you better.
#5
I've uploaded the rdk, the post and also a generated fanuc program file.

For this sample RDK there is a square with 50mm side lengths and a circle with 50mm diameter. 


In the post I've added some "addline" functions for debug purposes to write the informations in the program file. 

In this generated program file you can see the following:

Code:
  3:  Instruction: MoveL 7 | Target pose: Pose(37.932, 80.553, -0.000,  -180.000, -0.000, 180.000):
[[ -1.000, -0.000, -0.000, 37.932 ],
[ -0.000, 1.000, 0.000, 80.553 ],
[ 0.000, 0.000, -1.000, -0.000 ],
[ 0.000, 0.000, 0.000, 1.000 ]]

  4:  Instruction: MoveL 8 | Target pose: Pose(37.932, 130.553, 0.000,  180.000, 0.000, -180.000):
[[ -1.000, 0.000, 0.000, 37.932 ],
[ -0.000, 1.000, -0.000, 130.553 ],
[ -0.000, -0.000, -1.000, 0.000 ],
[ 0.000, 0.000, 0.000, 1.000 ]]

  5:  Instruction: MoveL 9 | Target pose: Pose(-12.068, 130.553, -0.000,  -180.000, 0.000, -180.000):
[[ -1.000, 0.000, 0.000, -12.068 ],
[ 0.000, 1.000, 0.000, 130.553 ],
[ -0.000, 0.000, -1.000, -0.000 ],
[ 0.000, 0.000, 0.000, 1.000 ]]

  6:  Instruction: MoveL 10 | Target pose: Pose(-12.068, 80.553, 0.000,  -180.000, 0.000, -180.000):
[[ -1.000, 0.000, 0.000, -12.068 ],
[ 0.000, 1.000, 0.000, 80.553 ],
[ -0.000, -0.000, -1.000, 0.000 ],
[ 0.000, 0.000, 0.000, 1.000 ]]

  7:  Instruction: MoveC 15 | Target pose: None
  8:  Instruction: MoveC 16 | Target pose: None
  9:  Length: 200.0
 10:  Length: 0
If the Instruction is MoveL, it contains pose informations. 
If the Instruction is MoveC, it does not contain anything, just gives back "None".
For the square with MoveL instructions it was able to calculate the path length which is 200 mm. 
For the circle with MoveC instructions it gave me 0 length because it has no target informations.


Attached Files
.rdk   Square_Circle.rdk (Size: 2.99 MB / Downloads: 223)
.py   Fanuc_R30iA_Delta.py (Size: 46.37 KB / Downloads: 180)
.txt   Square_Cir.txt (Size: 6.37 KB / Downloads: 177)
#6
The post processor you shared seems to work on my end with the RDK project you shared. I used the default settings in RoboDK.

You can try with the default settings by selecting:
  1. Tools-Options
  2. Select Set default settings
You should get the joints and the pose as None if the movement has no target linked to it. And you should get only the pose as None for Joint targets.
#7
I tried the default settings and got the same result. MoveC target pose is None in the program.
#8
Are you using the latest version of RoboDK?

Otherwise, updating RoboDK to the latest version should fix the issue:
https://robodk.com/download
#9
Yes, I am using the latest version of RoboDK (5.5.4).
  




Users browsing this thread:
1 Guest(s)