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

NACHi Post Format Error and Correction Example

#1
Hi all,

I need help modifying the post processor for a NACHi robot. I think I know what is happening.

This is related to other posts such as:
//www.sinclairbody.com/forum/Thread-Nachi-Ge...ight=Nachi

The suggestion to make the post processor to use the user coordinate system by
  1. 打开文件:C: / RoboDK /文章/ OTC.py
  2. Comment the line self.REF_FRAME = pose (around line 260, just add the # character in front)
will produce the correct numerical values for the Cartesian coordinate in the post, but still with the wrong format.

I attached 3 zip files here for you to review:
1) the RoboDK file following the spray paint program from the tutorial (yes, I am still learning from those).
2) the post from RoboDK after commenting the line #260ish following instruction above to use user coordinate system. The main program 110 will call 111, 112, 113
3) the post I edited manually to get them working

Here is what I did:
1) Using the teach pendent, I added User Coordinate Frame 1 (same location as the work piece frame in RoboDK) to the robot controller, and also added Tool 1 geometry (same definition as in RoboDK).
2) 110年,在调用子程序之前,我插入ed the line CHGCOORD 1 to use user coordinate frame 1. I inserted the line CHGCOORD 0 to user the robot base frame before ending the program. (It is probably a good idea insert these two lines in ALL subprogram though. CHGCOORD is fn113. It should be called before the move(s).)
3) Add a "U" to MOVEX lines. (Note: MOVEX M1J doesn't need it because it is joint move.) For example, in 111
before
MOVEX M1X,L,(222.258,199.775,333.893,0.000,-0.000,0.000),S=200.00,H=1,MS
after
MOVEX M1X,L,(222.258,199.775,333.893,0.000,-0.000,0.000)U,S=200.00,H=1,MS

Note the U after ')'

And that's how I get the program to work. I also compiled and ran these on FD on DESK II before i sent to the robot.

So, my question is: how do I modify the post processor to do these steps automatically?

Thanks!


Attached Files
.rdk NACHi 1.rdk(Size: 1.78 MB / Downloads: 429)
.zip RoboDK output edited.zip(Size: 1.75 KB / Downloads: 409)
.zip RoboDK output.zip(Size: 1.73 KB / Downloads: 427)
#2
Thank you for your feedback. This helps us improve our default post processor for Nachi and OTC robots.

Taking a look at your modifications, I attached an updated post processor for OTC and Nachi robots to handle the following:
  1. Use the CHGCOORD with all set reference frame instructions: the id of the reference will be 0 by default if you don't use any numbered frames. However, you can add a number to your reference frame in RoboDK (for example, rename your reference to "workpiece 1" to generate "CHGCOORD 1").
  2. Add a U after the pose if you are using a numbered reference frame.
Let me know if this works better by default or you would like to see other changes.

Albert


Attached Files
.py OTC.py(Size: 21.25 KB / Downloads: 462)
#3
Hi Albert,

I've tested out the new post processor. So far so good. : )

I promise I will learn Python next. I think I can get more out of RoboDK if I know it. (It is not hard. It is just time. : p)

Thanks!
#4
Hi all,

I have made some changes in the Postprocessor.
Now my question is if every Robot Model has the same type of functionnaming
I've got a MZ12-01 with a CFD-Controller

Changes I made
The Robot-programname normally was "MZ12-01-01-A.005"
Change to generate a program in Nachi-Software "MZ12-01.005"

Line 115
self.BASE_PROGNAME = robotnamelist[1] + '' #
#Before ... + '-01-A'

When calling Subprogram(s) the squaret brackets interfere with the Nachi-Software
Should be
CALLP XX国际新闻社tead of CALLP [XX]
Line 173
mainprog += 'CALLP %03i\n' % (self.PROG_ID+i+1)
#Before ...+='CALLP [%03i]\n'

I would like to know if these are general issues at the Nachi PP or just for my robot-model
Programming isn't my strenght... maybe there are some better solutions

Another thing I would like to change is the numeration of the called subprograms
The Programs start with .005 (always main)
Think it refers to Line 58
PROG_ID=5

My idea would be like this example:
'generate robot program as...'
MZ12-01.XX #For XX type a number (Main Prog)
# Calling X+n subprograms
MZ12-01.XX+1
MZ12-01.XX+2
MZ12-01.XX+...

hope myidea is good , what Ifall down on is implementing it...


Markus




Users browsing this thread:
2 Guest(s)