585,974 active members*
4,338 visitors online*
Register for free
Login
IndustryArena Forum > MetalWorking Machines > Okuma > Help with an unexpected program tool move
Results 1 to 11 of 11
  1. #1
    Join Date
    May 2009
    Posts
    41

    Help with an unexpected program tool move

    Hi Guys,

    I would really appreciate someone with experienced eyes to look at my program. I'm pulling my hair out with an unexpected tool movement.

    I tested a program with machine lock on and it ran as expected.

    I then test ran my next program for an almost identical part and I get a tool path that I cant explain.

    It happens in the code highlighted green.

    Instead of the tool moving 7mm in the -ve Z direction, it moves in the positive direction.

    Can anyone explain this to me?


    (On a side note, Ive started using the paint commands for animation etc and it seems that the zero points you specify for this are the z offsets set regardless of any 'in-program' VZSHZ commands. i.e. using VZSHZ before the paint command in the program does move the paint '0 point' to the new program '0' point.) (my code area in orange)


    Thanks for any assistance all you experienced guys.

    Iain.


    (51mm tip #2)
    (Material 60/40 4140 hollowbar)
    (Bar 37.23mm out from jaws)
    (Z0 15mm from jaw face)
    (JAW PRESSURE 150)
    (PROVEN AND BACKSAVED x)
    G50 S2000
    G90
    G95
    G40
    M42
    VZSHZ=15
    DEF WORK
    PS LC,[0,0],[23,60],4
    PS LC,[0,0],[23,40],0
    END
    DRAW
    NSTAR
    G00 X400 Z800
    T010101
    (FACE)
    G00 X65 Z21.2 M08
    G96 G01 X35 M03 S100 F0.25
    G00 X400 Z800 M09
    T020202
    G00 X65 Z20.73 M08
    G96 G01 X35 M03 S150 F0.1
    G00 Z50 M09
    G00 X400 Z800
    (ROUGH Internal CYC)
    N0001 G00 X400 Z800
    T060606
    N0002 G96 M03 S100
    N0003 G00 X38 Z22 M08
    N0004 G85 NAT01 D3 F0.25 U0.3 W0.3
    (FINISH Internal CYC)
    N0101 G00 X400 Z800
    T090909
    N0102 G96 M03 S150
    G00 X48 Z22
    N0103 G87 NAT01 F0.15
    (Int. CONTOUR)
    NAT01 G81 G42
    N0201 G01 X50.9 Z20.73
    N0202 G01 X50.9 Z14.73
    N0203 G01 X47.5 Z14.73
    N0204 G01 X44.7 Z4.0
    N0205 G01 X44.7 Z-4.0
    G40
    G80
    G00 X35
    G00 Z100
    G00 X400 Z800
    (EXT CYCLE 1)
    G00 X400 Z800
    T040404
    G96 M03 S120
    G00 X62 Z22 M08
    G85 NAT02 D2 F0.2
    M09
    (EXT CONTOUR 1)
    NAT02 G81 G42
    N0401 X53.6 Z20.73
    N0402 G01 X54.5 Z14.73
    G40
    G80
    (EXT CYCLE 2)
    N0502 G96 M03 S120
    N0503 G00 X61 Z15 M08
    N0504 G85 NAT03 D2 F0.2
    M09
    (EXT CONTOUR 2)
    NAT03 G81 G42
    N0601 X54.5 Z14.73
    N0602 G01 X50.36 Z3
    N0603 G01 X50.36 Z-4
    G40
    G80
    (EXT FINISH 1&2)
    G42
    G00 X60 Z22
    G00 X52
    G01 X52.5 Z20.73 F0.15
    G01 X53.28 Z14.85
    G03 X53.26 Z14.6 I-1 K-0.07
    G01 X49.16 Z3
    G01 X49.16 Z-4
    G00 X50 Z5
    G40
    (POINT CYCLE)
    N0702 G96 M03 S150
    N0703 G00 X50 Z5 M08
    N0704 G85 NAT04 D1 F0.15
    M09
    (POINT CONTOUR)
    NAT04 G81 G42
    N0701 G01 X49.16 Z4
    N0702 G01 X45.7 Z0
    N0703 G01 X45.7 Z-3.5
    G40
    G80
    G00 X60 Z14
    M01 (CHECK OK FOR PARTING)

    (PARTING)
    G00 X400 Z800
    T1212
    M01 (PUT BAR IN FOR PARTS CATCHER T/S)
    G00 X60 Z0 M08
    G00 X50 Z0
    M03 G96 S100
    G01 X40 Z0 F0.1
    M05
    G00 X400 Z800 M09

    (BAR RESET)
    T101010
    G00 X-10 Z20.75
    M00 (PULL BAR)
    G00 X400 Z8003
    GOTO NSTAR
    M02
    %

  2. #2
    Join Date
    Jun 2015
    Posts
    4154

    Re: Help with an unexpected program tool move

    may be a compensation issue

    run your code without G42 G40, or leave it just like that and declare radius=0 : if in both cases the machine will move Z-7, than it is a compensation thing

    after that, share tool nose radius, and i may fix the toolpath for you ...

    igf ?


    ps : (Bar 37.23mm out from jaws) + (Z0 15mm from jaw face) : on osp300 those 2 lines will be VSZOZ = 123.456
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  3. #3
    Join Date
    Jun 2015
    Posts
    4154

    Re: Help with an unexpected program tool move

    "real time animation", "CAS animation" and "IGF animation" are all based on the 3d model library

    if the tool inside the 3d model has a radius <> VNSR*, than the simulated toolpath will be <> real toolpath


    about the fact that Z0 does not shift inside the animation, just put it into a large bag with a label " differences between real setup and simulations " : there are some other system variables that do not perform well inside a simulation, but they work flawless in reality


    animation & cafe wifi is for princesses; barbarians and vikings don't care
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  4. #4
    Join Date
    May 2009
    Posts
    41

    Re: Help with an unexpected program tool move

    Hi Deadly Kitten,

    Thanks so very much for your time in replying.

    I am not sure it is a compensation issue. Would that show up in the middle of a list of tool paths without a tool change and head the tool in the opposite direction?

    I've pasted in a nearly identical part program below which has no problems with it. Maybe this will give some further clues as a comparison?

    Many thanks,


    (51mm tip #4)
    (Material 60/40 4140 hollowbar)
    (Bar 53.5mm out from jaws)
    (Z0 15mm from jaw face)
    (JAW PRESSURE 150)
    (PROVEN AND BACKSAVED x)
    G50 S2000
    G90
    G95
    G40
    M42
    VZSHZ=15
    DEF WORK
    PS LC,[0,0],[39,60],4
    PS LC,[0,0],[39,40],0
    END
    DRAW
    NSTAR
    G00 X400 Z800
    T010101
    (FACE)
    G00 X65 Z37.4 M08
    G96 G01 X35 M03 S100 F0.25
    G00 X400 Z800 M09
    T020202
    G00 X65 Z36.92 M08
    G96 G01 X35 M03 S150 F0.1
    G00 Z50 M09
    G00 X400 Z800
    (ROUGH Internal CYC)
    N0001 G00 X400 Z800
    T060606
    N0002 G96 M03 S100
    N0003 G00 X38 Z38 M08
    N0004 G85 NAT01 D3 F0.25 U0.3 W0.3
    (FINISH Internal CYC)
    N0101 G00 X400 Z800
    T090909
    N0102 G96 M03 S150
    G00 X48 Z38
    N0103 G87 NAT01 F0.15
    (Int. CONTOUR)
    NAT01 G81 G42
    N0201 G01 X50.9 Z36.92
    N0202 G01 X50.9 Z26.92
    N0203 G01 X47.5 Z26.92
    N0204 G01 X42.5 Z3
    N0205 G01 X42.5 Z-4.0
    G40
    G80
    G00 X35
    G00 Z100
    G00 X400 Z800
    (EXT CYCLE 1)
    G00 X400 Z800
    T040404
    G96 M03 S120
    G00 X62 Z38 M08
    G85 NAT02 D2 F0.2
    M09
    (EXT CONTOUR 1)
    NAT02 G81 G42
    N0401 X53.7 Z36.92
    N0402 G01 X57.1 Z26.92
    G40
    G80
    (EXT CYCLE 2)
    N0502 G96 M03 S120
    N0503 G00 X61 Z28 M08
    N0504 G85 NAT03 D2 F0.2
    M09
    (EXT CONTOUR 2)
    NAT03 G81 G42
    N0601 X57.1 Z26.92
    N0602 G01 X48.66 Z3.0
    N0603 G01 X48.66 Z-4
    G40
    G80
    (EXT FINISH 1&2)
    G42
    G00 X60 Z25
    G00 Z38
    G00 X52
    G01 X52.5 Z36.92 F0.15
    G01 X55.84 Z27.09
    G03 X55.84 Z26.75 I-0.99 K-0.17
    G01 X47.46 Z3.0
    G01 X47.46 Z-4
    G00 X55 Z3
    G40
    (POINT CYCLE)
    N0702 G96 M03 S150
    N0703 G00 X48.5 Z5 M08
    N0704 G85 NAT04 D1 F0.15
    M09
    (POINT CONTOUR)
    NAT04 G81 G42
    N0701 X47.46 Z3
    N0702 G01 X44.0 Z0
    N0703 G01 X44.0 Z-3.5
    G40
    G80
    G00 X60 Z28
    M01 (CHECK OK FOR PARTING)

    (PARTING)
    G00 X400 Z800
    T1212
    M01 (PUT BAR IN FOR PARTS CATCHER T/S)
    G00 X62 Z0 M08
    M03 G96 S100
    G01 X40 Z0 F0.1
    M05
    G00 X400 Z800 M09

    (BAR RESET)
    T101010
    G00 X-10 Z38.5
    M00 (PULL BAR)
    G00 X400 Z8003
    GOTO NSTAR
    M02
    %
    

  5. #5
    Join Date
    Jun 2015
    Posts
    4154

    Re: Help with an unexpected program tool move

    check attached image : there is a sharp angle right at the end of the toolpath

    also G40 is after G00; not technical : cutting should be compensated, not also positioning

    when positioning is included inside a comp code, stuff may happen

    if you wish, run your code with radius = 0 : it will work well, it won't deliver the part, but it will work ...



    ok, now time for an easy-fix :

    Code:
    (EXT FINISH 1&2)
    G42
    G00 X60 Z22
    G00 X52
    G01 X52.5 Z20.73 F0.15
    G01 X53.28 Z14.85
    G03 X53.26 Z14.6 I-1 K-0.07
    G01 X49.16 Z3
    G01 X49.16 Z-4
    G40
    G00 X50 Z5
    (POINT CYCLE)
    
    voila
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  6. #6
    Join Date
    May 2009
    Posts
    41
    Hi


    Thankyou so much for your help.

    Your solution worked by cancelling TNR COMP before the rapid move.

    I have no idea why this is so. The original program has G40 after the block that has the problem so the machine shouldnt habe even seen this G40 or the upcoming rapid move.

    Can you explain why the G40 move, 2 lines ahead of the problem tool path caused it to move positive Z rather than negative?

    Thanks for your drawing too. What is this showing? Just the difference between TNR on and off?

    Thanks for all your time and effort.

    Regards, Iain

  7. #7
    Join Date
    May 2009
    Posts
    41
    To clarify:

    Instead of moving to the programmed Z-4, the tool appeared to head towards Z+8

  8. #8
    Join Date
    Jun 2015
    Posts
    4154

    Re: Help with an unexpected program tool move

    hi / drawing shows program coordinates

    pls share tool nose radius : i need it to draw the comp toolpath; in the end, you will see that the radius can't fit into the sharp angle at the end of your toolpath

    Your solution worked by cancelling TNR COMP before the rapid move. I have no idea why this is so
    neither do i

    the original program has G40 after the block that has the problem so the machine shouldnt habe even seen this G40 or the upcoming rapid move
    no, not quite so ... there is the read ahead buffer, which normally goes in front of the execution line ( it may go 1 line ahead , 2 lines, 100 lines, etc )

    in comp mode, the controller executes current line acordingly to the next 3-4 lines at least

    i don't know how many lines reads the read-ahead in comp mode, but i can tell for sure that at least 3-4 are used to calculate the coordinates for the current line; the read ahead may be in front with much more lines, but only 3-4 are required by the contoller, so to decide where to move the tool

    ... and so, this is why why is this
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  9. #9
    Join Date
    Jun 2015
    Posts
    4154

    Re: Help with an unexpected program tool move

    more precise, in comp mode, the controller needs only the next movement, so to calculate the end position of the current line ( accordingly to the next movement )

    this would mean that the read-ahead should be only 1 line ahead

    okuma controller ( and other brands also ) permit auxiliary codes to be inserted within a comp paragraph

    consider points A B C on a toolpath :

    Code:
        N1 G41
        N2 G01 A ( when N2 is executed, the controller needs to know also the location of point B, so to compute correctly the comp toolpath )
        N3 G01 B
        N4 G01 C
        N5 G40
    this code has auxiliary lines intercalated inside the comp paragraph :
    Code:
        N1 G41
        N2 G01 A
        line 1 random stuff 1
        line 2 random stuff 2
        line 3 random stuff 3
        N3 G01 B
        N4 G01 C
        N5 G40
    in this case, execution of line N2 still requires the coordinate from line N3, but in between are some extra-codes; okuma allows 3-4 extra lines

    this is why, in comp mode, the read ahead must be at least 3-4 lines ahead so to permit the comp-toolpath to flow across auxiliary lines
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  10. #10
    Join Date
    May 2009
    Posts
    41

    Re: Help with an unexpected program tool move

    Deadly Kitten,

    Thanks so much for you all your replies and great help.

    I was playing with this part today and got somewhere thanks to your help.

    I have another questions if you're able to help me, or anyone else.

    Firstly I thought I understood TNR comp. But its not as clear as I thought. Is there a simple analogy to picture it?

    Secondly on this, do Okuma machines require that you have a tool form selected to make correct use of this? I didn't imagine it would need this but some things I have been reading suggest it may.



    But onto my main point..

    I want to part off my part in the normal fashion with the parting tool close to the chuck and the part in the +Z direction relative to tool.

    I wanted to groove slightly with my parting tool, back out and break the corner of the part with a small radius and continue on parting off. I have done this many times without TNR comp.

    As this parting insert has a 0.2mm TNR I should compensate for it.

    NO combinations I could come up with have a usable tool path.

    I tried the groove without TNR comp left and right and then moving to the +Z and +X direction relative to the start of the arc point so all movements after TNR comp were in the same direction but still no luck.


    G00 X60 Z1 (Rapid in to area)
    G01 X45 Z0 F2 (Feed more slowely to start point {I did have all this with TNR comp at one point hence G01's})
    G01 X43.4 F0.1 ( Groove a clearance for the radius)
    G01 X45 F1 (retract from groove)
    G01 Z0.5 (shift over so tool is in +z direction relative to radius starting point where I want to use TNR comp)
    G42 (or 41)
    G01 X44.29 Z0.25 F1 ( feed to start of Radius)
    G03 X43.42 Z0 I-0.43 K0.25 F0.5 (Radius that leads into the parting off plane)
    G01 X38 F.1 (finish parting off)
    M05

    Nothing I tried could make this work - though it has to be possible. Okuma OSP7000 control

    Thanks for your help guys.

  11. #11
    Join Date
    Jun 2015
    Posts
    4154

    Re: Help with an unexpected program tool move

    Is there a simple analogy to picture it? : draw something made of lines and arches ( program toolpath ) inside autocad, and after that try the offset instrument on it ( comp toolpath ) : now modify the offset shape, so to make it continuous ( it may be tangent or not ) : this should give you a clue about how the controller calculates the comp-toolpath; in 10 minutes you will be a master in reality, controller tries to make it continuous and tangent ( whenever possible )

    next, you should mess your head with:
    ... P values, or compensation quadrants
    ... offset sides : G41 & G42
    ... lead-in lead-out movements & imaginary vectors

    *but, well, easy steps


    do Okuma machines require that you have a tool form selected to make correct use of this? : there are several ways to program the cnc:
    ... if you use CAS and 3d models, than it is 'a must' to have a tool
    declared with a correct shape
    ... it is possible also to program the cnc without CAS and 3d models : for example i code a lot in G-code, and i draw custom toolpaths that i convert to G-code; i avoid default machine cycles, because they don't perform how i wish; i also switch the CAS off, but i verify each tool offset to be within some safe limits : of course, it takes a bit of time, but is faster than configuring CAS; i don't use all my tricks, unless there is a setup that should last for a long time these days i am preparing 2 long-term setups ... now i learn to take back my driving license




    ok, now about parting with chamfer :

    1) i recomand a normal 'c' chamfer, not 'r' radius : 'c' is simpler than 'r', and executes faster because it is shorter; also, when you use 'r' you will comand the cnc to go among an arch, and this will involve the motors to change continuosly the sync ratios, as the arch is executed; on a 'c' the sync ratio will always be the same

    in other words, 'r' puts more stress on the servos than a 'c' ; of course, depends how sensitive you are when talking about machining; maybe you don't look or you did not had time to look into such details

    also, when you use 'r', you should deliver the part with the 'r' tangent to the OD

    so : 'c' is shorter, constant servos sync ratio, no 'tangential demands'; i recomand use default 'c', and 'r' only when it is required

    2) i used to use a parametric code, inside which i specify : OD, clearance, nose-radius, etc and it worked

    but lately i have more codes inside the parting off operation :
    ... ctr parts-catcher + high-low rpm so to be sure that the parts fall inside the parts-catcher
    ... different feeds, starting high and going slower, so to deliver a smooth cut; an agresive cut may throw the part random, break the window, etc
    ... coding the chamfer also for the bar puller, so to smooth out the movement of the bar-puller when it goes to grab the material; if i don't do this, i may end up having an increased load on Z axis
    ... more than 1 corection ( 2nd offset, or a variable, or a parameter ) inside the code
    ... cutting away or near the spindle ( for example when i pull the material once, but i do more than 1 part )

    all these are pretty particular to each setup, so i don't use a parametric code anymore, because is easier to write the code ' on the spot ' than create a more complex cutting soubroutine to handle all these particular cases again, all these i do only for long term setups



    but, for you, i would recomand a soubroutine : if you wish, share a drawing, or some dimensions, be a bit specific about details that you wanna control, and i will write you a soubroutine ( or i will share what i think you may need ) and you may use it as long as you wish ... kindly
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

Similar Threads

  1. Replies: 9
    Last Post: 11-15-2017, 01:43 AM
  2. Mach3 unexpected plunge after tool change
    By CabinDigital in forum Mach Mill
    Replies: 5
    Last Post: 02-19-2016, 11:11 PM
  3. Replies: 2
    Last Post: 12-31-2014, 01:46 PM
  4. G Code Generating Unexpected Tool Path
    By jknee2 in forum Mach Software (ArtSoft software)
    Replies: 3
    Last Post: 09-03-2013, 02:21 AM
  5. V25 - Unexpected clipping in tool path
    By Analias in forum BobCad-Cam
    Replies: 5
    Last Post: 02-15-2013, 06:51 PM

Tags for this Thread

Posting Permissions

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