Im in the learning process of coordinate system transformation and im trying to make the post processor for 5 axis indexing positioning for drilling.
Frist idea is to use @tmatix and Siemens Cycle800 to rotate the table ( its table-table type machine).

The problem is i don't have any studying material except the GPPTOOL.chm , and few free downloadable pdf-s online . TO make matters worse - i dont even have any working 5 axis simens post so i could get the reverse engineering done on it.
Only thing i found is in one old student final paper the example that i cant make to work.

here is the example code that gives me the error in the Line 788 "Unrecognized statment"

If anyone can help it would be greatly appreciated - i don't want the complete 5axis post for free i just want the nudge in the right direction where to get more information to learn more! And to get the missing knowledge to make the 5axis Siemens post by myself.Any good books on the subject or maybe tutorials?

Code:
@tmatrix
local numeric hx hy hz dev_angle
local numeric cosx sinx cosy siny cosz sinz A B C 
local numeric dx dy dz dx1 dy1 dz1 x y z a b c 
 dx1 = 0
 dy1 = 0
 dz1 = 0
 dx = shift_x; + dx1
 dy = shift_y; + dy1
 dz = shift_z; + dz1
 sinx = sin(rotate_angle_x)
 cosx = cos(rotate_angle_x)
 siny = sin(rotate_angle_y)
 cosy = cos(rotate_angle_y)
 sinz = sin(rotate_angle_z)
 cosz = cos(rotate_angle_z)
hx = cosy*cosz*dx - sinz*cosy*dy + siny*dz
hy = (-sinx*siny*cosy + cosx*sinz)*dx + (sinx*siny*sinz + cosx*cosz)*dy - sinx*cosy*dz
hz = (cosx*cosz*siny + sinx*sinz)*dx + (-sinz*cosx*siny + sinx*cosz)*dy - cosx*cosy*dz
 if rot_axis_type eq axis4_none
THIS IS LINE 788 ---> rotate_angle_x:0.000T rotate_angle_y:0.000T rotate_angle_z:0.000T
rotate_angle_x_dir:cw rotate_angle_y_dir:cw rotate_angle_z_dir:cw
 A = rotate_angle_x
 B = rotate_angle_y
 C = rotate_angle_z
 rotate_angle_x_dir = cw / ccw
 rotate_angle_y_dir = cw / ccw
 rotate_angle_z_dir = cw / ccw
y_angle_const_x:0.000T z_angle_const_x:0.000T dev_angle_x:0.000T
y_angle_const_x_dir:cw z_angle_const_x_dir:cw dev_angle_x_dir:cw
 B = y_angle_const_x
 C = z_angle_const_x
  part_home_number:1 tool_z_level:250.000
 tmatrix_I_1:1.000T tmatrix_I_2:0.000T tmatrix_I_3:0.000T tmatrix_I_4:0.000T
 tmatrix_I_5:0.000T tmatrix_I_6:1.000T tmatrix_I_7:0.000T tmatrix_I_8:0.000T
 tmatrix_I_9:0.000T tmatrix_I_10:0.000T tmatrix_I_11:1.000T tmatrix_I_12:0.000T
 tmatrix_I_13:0.000T tmatrix_I_14:0.000T tmatrix_I_15:0.000T tmatrix_I_16:1.000T
 x = cos(y)*cos(z)*x - sin(z)*cos(y)*y + sin(y)*z
 y = (-sin(x)*sin(y)*cos(z) + cos(x)*sin(z))*x + (sin(x)*sin(y)*sin(z) + cos(x)*cos(z))*y - sin(x)*cos(y)*z
 z = (cos(x)*cos(z)*sin(y) + sin(x)*sin(z))*x + (-sin(z)*cos(x)*sin(y) + sin(x)*cos(z))*y - cos(x)*cos(y)*z
 ;around Z
 x = x*cos(dev_angle) - y*sin(dev_angle)
 y = x*sin(dev_angle) + y*cos(dev_angle)
 ;around Y
 z = z*cos(dev_angle) - x*sin(dev_angle)
 x = z*sin(dev_angle) + x*cos(dev_angle)
 ;around X
 y = y*cos(dev_angle) - z*sin(dev_angle)
 z = y*sin(dev_angle) + z*cos(dev_angle)
 endif
if rot_axis_type eq axis4_none
 {nb,'MCALL CYCLE',800}
CYCLE800(1, "", 0, _MODE, 200, 200, 200,, rotate_angle_y, rotate_angle_z, _X1, _Y1, _Z1, _DIR)
endp


Similar Threads: