586,055 active members*
4,176 visitors online*
Register for free
Login
IndustryArena Forum > MetalWorking Machines > Okuma > auto Z origin on lathe
Page 3 of 4 1234
Results 41 to 60 of 78
  1. #41
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    hy in attached archive is a movie that shows this program at work

    ... in reality is much faster, since here i had to operate with the door open and one hand holding the camera, and another on the feed potentiometer
    ... a sharp eye should see that there are no extra movements ( specific to cycles ) when frontal is cut kindly !
    Attached Files Attached Files
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  2. #42
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    [ delivering a stable machine condition before using G22, and a proper PZ ]

    hello all this thing generally occurs as default, so you dont have to worry about it; problems may appear when improper safe positions are used, or when using G22 for at least 2 times on same part, because screw ball area is changed

    1) running a simple code, without touching the material :

    Code:
        G29 PZ=69 (*1)
        G22 PZ=69 Z-15 G94 F100*5 D15 G91 (*1) (*2)
        G28
    i runned this code a few times, and between each run i have moved the turret :
    ... to left or to right
    ... by hand wheel or by the arrows
    ... with low or high feed
    ... in front of the chuck or far from the chuck

    as it can be seen in attached image 1, the effort is not identical

    2) adding movement before the G22, so to normalize the effort diagram :

    Code:
        G00 X+200 Z+200 G91
            X-200 Z-190
                  Z-10
        G29 PZ=69 (*1)
        G22 PZ=69 Z-15 G94 F100*5 D15 G91 (*1) (*2)
        G28
    trials are shown in image 2 : effort is normalized now ( last 2 runs are in a different screw ball area; at run 4 i have reduced the feed from the potentiometer, checking not to hit the tailstock )

    movement before G22 must exist and be repeatable, so to normalize the servos effort when G22 begins

    this code :
    ... safe position
    ... rapid movement to G22_start_position
    ... G22, may not be good : if during the rapid movement only X is traveling a lot ( from X+limit towards the part ), and Z is traveling short ( this may succumb the Z servo )

    so i suggest this approach :
    ... safe position
    ... rapid movement to G22_start_position.X G22_start_position.Z+10
    ... rapid movement to G22_start_position ( this line should normalize the servo )
    ... G22
    *or just control the safe position, being sure that Z servo during approaching has enough travel, to reach a normal feed

    with this approach, repetability is achieved : start-up effort is stable and also the normalization effort is stable; just replace PZ=69 with a value greater with 3..5 units than the normalized effort and hit the material PZ=25..30% should deliver in most cases ... kindly !





    (*1)
    PZ=69 is totally random; idea is to run a blank trial ( without touching the material ) and have an active torque limit big enough, so things will run smooth; this limit may be maximized in this stage, because servos will never reach it; after such trials, it can be lowered and material can be hit; if such trials are runned with a lower PZ, than the machine may stop without touching the material, but also very close to it, so making it hard to guess that the code is not working as it should

    (*2)
    turret should always execute the full travel and raise an error at the end; this is normal, and the error says that during the travel, the desired effort limit ( PZ=... ) was not reached; this is simply solved by hitting the material without reaching the end Z
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  3. #43
    Join Date
    Mar 2018
    Posts
    17

    Re: auto Z origin on lathe

    ... G22 PZ=69 Z-15 G94 F100*5 D15 G91 (*1) (*2) ...Whats the D15 for? Does it have to match Z? Is this the limit that gives Torque alarm if it passes 15?

  4. #44
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    hi / don't use PZ=69, but something lower, like PZ=15 - 20 - 25; 69 is too big ...

    there is a comment at the bottom of the post, where i said that 69 is random yeah, you know ...



    yup, match the D with the Z, more precise, when going left, Z will be negative and D = | Z |

    that code, because of the G91, will start moving the turret towards left, for a travel of 15mm long, regardless of initial turret position :
    ... if there is nothing in front of the turret, the cnc will raise an error after the 15mm had been traveled
    ... if there is something in front of the turret, the cnc will continue it's movement until the effort will be PZ; after that, next block is executed

    for more infos about G22 check attached file; also, pls consider initial posts; latest posts are a bit too wild : more precise there is a lot of code and things, that require time to be understood, but they perform pretty fast and versatile i don't know, just don't get lost ...
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  5. #45
    Join Date
    Apr 2009
    Posts
    1262

    Re: auto Z origin on lathe

    D does not have to match Z. It is only an approach Distance where the feed will be cut to 1/5 in order to more accurately detect the load value. Yes 69 is way too high. That may be a G29 torque limit max rather than the G22 torque skip value which should be about 20 as kitty says.

    D would be distance before target where feed decreases
    and L is distance after target before alarm occurs.
    Experience is what you get just after you needed it.

  6. #46
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    hy mr wizard you are right, D does not have to match the Z, but this is how i use G22 : it simplifies the syntax, because there is no more the "L" parameter

    this is the " senseless gauging " fragment of code that i use :
    Code:
        G00       Z+V7
        G29 PZ=25
        G22 PZ=25 Z-V7 F+100*5 G94 D+V7*2
        G28
    it only requires a value for the V7, that is calculated automatically; for example, if i start a setup, i put a bar in there, and i simply input these values :
    ... minimal VSZOZ
    ... how many cuts
    ... cut width
    ... Z to leave for the main program, so to adjust origin as necessary ( for example : deliver Z0, or Z<>0 when a face cut is inside the main program )

    the soubroutine does all the work for example, after G22 is executed, it checks that the material is detected inside a small window arround V7-5mm; i use 5 mm, so to allow the monitoring effort to stabilize, thus it checks that a "minimal travel occurs", and raises an error otherwise


    approach depends on real setup / kindly !
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  7. #47
    Join Date
    Mar 2018
    Posts
    17

    Re: auto Z origin on lathe

    Quote Originally Posted by OkumaWiz View Post
    .....Then you will need to read the machine position once it stops. V1=VAPAZ (sets variable 1 = Actual Z position)You may need to do some math to determine how much to shift since this reads the machine position.VZSHZ=Zero Shift on ZVZOFZ=Zero OFFSET on ZVSIOZ=Zero Secondary Incremental offset on ZSo amount to shift would be V2=VAPAZ-VZSHZ-VZOFZ-VSIOZThen in your program shift to new origin by VSIOZ=VSIOZ+V2.Zero should now be at the front of your part....
    Hi again. Im struggling with this "equation".My V1 (VAPAZ) is 55387.251, but I cant seem to get anything useful out of it.Could you explain again with more details? How would you explain the difference between VZSHZ, VZOFZ and VSIOZ to a newbie?

    Also I am not looking for changing my zero point, but rather add the difference between the current position and my zero point to the cyclus start. Then I wont be running air cuts while facing the parts.

  8. #48
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    paste your G22 code, and specify your control generation : if osp200 or 300 i will quick edit it for you, so to get the Z zero

    about explanations about those variables, let's postpone them : you may not need to use all those variables, so to make the G22 work so if i start explaining them, you won't move your cnc ...

    this is a paragraph : it has no safe position, no T codes; can you handle it ?
    M19
    G00 Z+10
    G29 PZ=25
    G22 PZ=25 Z-10 F+100*5 G94 D+10*2
    G28
    G00 Z+2.5 M18 G91
    G90
    NOEX VSZOZ = VSZOZ + VSIOZ - 2.5
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  9. #49
    Join Date
    Mar 2018
    Posts
    17

    Re: auto Z origin on lathe

    G00 X25 Z10
    G29 PZ=30
    G94 G22 PZ=25 Z-10 F200 D10
    G28
    G91
    G00 Z2.5
    G90

    This is ish how it looks. I'll get the specific one tomorrow.

    It is an OSP-P300S

    "
    G28
    G00 Z+2.5 G91
    G90
    NOEX VSZOZ = VSZOZ + VSIOZ - 2.5
    "
    Ill try this tomorrow

  10. #50
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    G00 X25 Z10
    G29 PZ=30
    G94 G22 PZ=25 Z-10 F200 D20 ( there is 20 from +10 to -10 )
    G28
    G00 Z2.5 G91
    G90
    NOEX VSZOZ = VSZOZ + VSIOZ - 2.5

    test it, and after that i will explain those variables; what means the "S" from osp300s ?
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  11. #51
    Join Date
    Mar 2018
    Posts
    17

    Re: auto Z origin on lathe

    ...
    G140 (-)
    G20 HP=1
    TD=108M323
    G50 S600
    G96 S250 M4
    G0 X400 Z5
    G29 PZ=30
    G95 G22 PZ=5 Z0 D5.0 L1.0 F0.1
    G28
    G91
    G0 Z5
    G90
    NOEX (VSZOZ)V1=VSZOZ+VSIOZ-5
    G20 HP=1
    M5
    M30
    ...
    I set it to 5% atm so I can "simulate" a hit with turning the feed up.On my V1 I get 726,617. This is the correct value if I were to change my zero point.If I only do V1=VSIOZ-5 I get the specific location on the start of my blank so I could put V1 as a cyclus start point!I think I got it man, thanks for the help!

  12. #52
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    hi

    i don't know if only 5% is enough; check the Z axis effort when cutting air, and use PZ=air+a_bit; if you have already done this, than is cool

    why do you use g50 s600 : is it a big machine ?

    so far i never used detection while cutting, but only when spindle was stationary, because the materials had a very tilted face after the bandsaw ; if you detect the face by cutting, than you should be sure that you always cut enough, so to get a straight face

    if you wish, pls check post 41 : it shows my code at work this is a way to begin cutting when there is no bar-feeder, and also the material is pulled to the turret instead of using a depth caliper : this is faster especially when the material is heavy and Z0 is pretty close to the chuck; if a depth caliber should be used, than the operator should sustain ( with one hand ) the entire mass of the bar which tends to fall, and with the 3rd hand it should keep the caliper into place ; using the turret makes it faster and requires less strength from the operator, especially for heavy materials; an operator which is less solicited should be more sharp about supervising the cnc; if he has worries that his muscles will atrophy, than he may bring a dumbbell to work

    once i have encoutered a pretty messy situation with a bar that should deliver 2 parts : the faces were so tilted, that i had to cut only a face at a time and check; otherwise it would be impossible to get 2 parts from the material : it happens when a low quality bandsaw is there

    about those system variables :
    ... VSZOZ : Z origin
    ... VSIOZ : comanded Z ( or target point if you wish ), not actual Z
    if you use
    N1 G00 Z0
    N2 G00 Z10
    N3 V1 = VSIOZ (V1 will show 10, while VSIOZ will be 10 since the moment of execution of line N2 )
    sometimes, things are not so straigth forward : during comp codes, VSIOZ may not be spot on : best practice is to test the code



    one more thing : "senseless gauging" is a reserved word, created by mr Wizard, so use it carefully, like G140 ( senseless gauging © mr Wizard ); from him i know this technique

    ok man
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  13. #53
    Join Date
    Mar 2018
    Posts
    17

    Re: auto Z origin on lathe

    Thanks for the info. Yes, its a big machine and the face is very often tilted.
    I will use this while the part is rotating to get the highest point.
    I'll call it something other than S. Gauging from now on!

  14. #54
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    hi / just a few more things :

    - you used s250*f0.1=25mm/min feed during G22; real feed will be at 1/5 ratio, thus only 5mm/min; G22 reduces the feed in this way, by default; i like to program the feed at 100*5 G94, so the real feed to be 100mm/min during contact; there is a maximal feed that is allowed during G22 ( 500mm/min or 2500mm/min; i dont remember exactly, but generally you won't reach that value ); so my advice, if you wish for 0.1mm/rot, simply use G95 G22 PZ=5 Z0 D5.0 L1.0 F0.1*5; i use higher feed because spindle is stationary in my case ( i have in idea how to boost you code, but i will share it later )

    - about the D : you begin at Z5 and target Z0 : this requires D5; how you also used L1.0, this may require D6 ? i don't know, so :
    ... pls check how the D is altered by L<>0, or
    ... use
    G95 G22 PZ=5 Z0 D5.0 (L1.0) F0.1*5

    - about the decimal points : the okuma controller may treat 5.0 the same as 5, so using
    G95 G22 PZ=5 Z0 D5 F0.1*5 should be just fine

    - about the feed position : i like to keep it at the end; the okuma controller should not treat differently "
    G95 G22 PZ=5 Z0 D5 F0.1*5 " and " G22 PZ=5 Z0 D5 F0.1*5 G95 ", so if you puted G95 right at the begining , considering that it must precced the G22, than you shoud not worry; better test this, to be sure ( some controlers<>okuma care about feed position )

    - about travel from Z5 to Z0 L1, thus from Z5 to Z-1 : this window may be to small : during it, the Z axis has to accelerate and avoid initial effort peek, and also decelerate near the end; this may create problems with higher feeds, because real zone where the effort will be stabilized will be -1<zone<5; the "zone" reduces as the feed increases, so i recomend you "
    G22 PZ=5 Z-10 D15 F0.1*5 G95 " in this way, you should be sure that during contact, you are away from the acceleration/deceleration zone; pls be aware that there are warnings about a " minimal 2.5mm clearance " to be used when load monitoring is involved, and more precise, " 5mm clearance is recomended"; so the contact should occure after at least 5mm from the position where G22 begins, and also, G22 should have at least 2.5mm after the contact point; so if you consider that the material will be anywhere between Z-2 and Z+3, use "G00 Z+3+5"+"G22 Z-2-2.5... "is it ok ? did i explained it well ?


    i hope you find these usefull kindly !
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  15. #55
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    Quote Originally Posted by deadlykitten View Post
    i have in idea how to boost you code, but i will share it later
    to use G22 with higher feed, like 100mm/min, and keep the spindle stationary, than pls consider touching not with the "cutting edge", but with the "turret frontal"

    i guess your turret frontal is big enough to handle the X400 coordinate

    particular case example : if your material is X500 and turret can only reach X350, than simply shift your detected Z with a bit more; between X350detected and X500material, should be a little difference=d caused by the tilted bandsaw, so modify the Zorigin delivered by G22 with d

    idea behind all these is to have a G22 travel as minimal as possbile, executed as fast as possible

    if you just started using G22, than also try to implement this; trials will lead to a bit of downtime, but for the future, the code will remain unchanged

    if your material is very tilted, than 1st few face cuts should not stop at X0, but at X200, so not to cut air

    i have seen over the internet an example with a big lathe with live tools, that was getting the face done by circular milling : i guess this is faster than turning, and less air cut is there

    i hope you find it usefull and i hope i explain things well / kindly !
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  16. #56
    Join Date
    Mar 2018
    Posts
    17

    Re: auto Z origin on lathe

    Im using the cutting edge because I will put something like this under a G-code with inc. values so I can locate the part and set my cycle start points. I want to use the relevant tool and use as little time as possible. So if I want to turn a D400 part I will go to X395 Z10 and then have G206 to locate my part and set V1 as starting Z for face. (Spindle will not be stationary, but it will have the same "cutting data" as the operation it sets the start points for)
    Most of these are a few millimeters slant, but the big ones I have milled

    "G95 G22 PZ=5 Z0 D5.0 (L1.0) F0.1*5" - As long as there is more or equal distance from your starting point to the set Z value (Z0 in this case) it will not cause an alarm. The L can be as big as you want.At least that's what I got from it while trying. D=Distance from starting point to end point. (Not included L-length)

    Alarm:
    G0 X400 Z4.99
    G95 G22 PZ=5 Z0 D5.0 L1.0 F0.1*5

    No alarm:
    G0 X400 Z5
    G95 G22 PZ=5 Z0 D5.0 L10.0 F0.1*5

  17. #57
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    hello guys & girls an update will be soon shared in this thread, about facing & zeroing ( without G22 )

    fast & smooth, few keystrokes, versatile : easy adaptable to different diameters and bar lengths

    something like " not know what hit you " , or " what happened " / so smooth you don't know is there

    all-inclusive / kindly


    ps : i have to prepare the video ...
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  18. #58
    Join Date
    May 2018
    Posts
    74

    Re: auto Z origin on lathe

    Hello Deadlykitten,
    I went through this topic and very interested in the auto Z origin. So my thought is that if we can do the auto Z then we are able to do the auto X.
    So let me tell you what the process that I think of:
    1. Load the part into the chuck
    2. Hit the cycle start
    3. The turret will index the tool (master tool) and start to set a program zero (z axis) for all tools.
    4. Do the same on X axis
    5. And start to produce the part.
    6. Most our machines are osp 200 some 5020L

    Could you help me to understand the G22 and I would like to write a macro to do the auto Z and X zero. It would be very great...

    Quote Originally Posted by deadlykitten View Post
    paste your G22 code, and specify your control generation : if osp200 or 300 i will quick edit it for you, so to get the Z zero

    about explanations about those variables, let's postpone them : you may not need to use all those variables, so to make the G22 work so if i start explaining them, you won't move your cnc ...

    this is a paragraph : it has no safe position, no T codes; can you handle it ?
    M19
    G00 Z+10
    G29 PZ=25
    G22 PZ=25 Z-10 F+100*5 G94 D+10*2
    G28
    G00 Z+2.5 M18 G91
    G90
    NOEX VSZOZ = VSZOZ + VSIOZ - 2.5

  19. #59
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    hi nodo, it is possible to use G22 among X axis, but i really don't understand why isn't it enough for you only on Z axis ?

    why do you need both of them ?


    also, there may be a problem with load detection among X axis; sometimes there is a remanent load, that simply goes away after a few seconds

    this means that X load value, sometimes, may be greater without an aparent reason

    check attached image : machine cuts air from X100 to X65, but effort is not constant; it simply starts high, and gets lower ( normalized ) arround X80

    i have no clue what causes it, or if it appears also during G22

    to handle this, you should use an effort limit >30%, and it seems a bit much for me, especially for a repetitive task

    the lower the limit, the better, but there are some problems with limits that are too low; so far i have used 20-25%, mostly on Z axis / kindly
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

  20. #60
    Join Date
    Jun 2015
    Posts
    4154

    Re: auto Z origin on lathe

    hello again, i don't know, maybe you need G22 for both x&z because you use a master tool ?

    so far i never used master tools, but only heared a bit about them ... so i am not sure if i can help you

    however, let's begin with auto Z

    try this code and see what happens

    it should work if your controler suports G22 and those system variables

    M19 and M18 are not really required, but i like to have the chuck locked while this "senseless gauging" technique occurs; keeping the chuck steady should minimize marks that remain from the contact

    if all is ok, we move to X YZABCDJLJFDLGD / kindly
    Code:
        G00 safe position
        T ( consider touching with a od tool shank, a rod, toolholder, etc )
        M19
        G00 X50 Z10
        G29 PZ=25
        G22 PZ=22 Z-10 F+100*5 G94 D+10*2
        G28
        G00 Z+2.5 M18 G91
        G90
      ( NOEX ) VSZOZ = VSZOZ + VSIOZ - 2.5
        G00 safe position
    Ladyhawke - My Delirium, https://www.youtube.com/watch?v=X_bFO1SNRZg

Page 3 of 4 1234

Similar Threads

  1. auto-set C axis origin :)
    By deadlykitten in forum Okuma
    Replies: 2
    Last Post: 02-26-2016, 01:35 PM
  2. Auto Lathe toolturret info?.
    By Al_The_Man in forum Mechanical Calculations/Engineering Design
    Replies: 3
    Last Post: 04-06-2011, 01:56 AM
  3. Origin and tool offsets Lathe
    By Bony Fingers in forum Daewoo/Doosan
    Replies: 1
    Last Post: 04-15-2009, 06:36 AM
  4. Princess Auto Lathe Sale
    By Al_The_Man in forum Mini Lathe
    Replies: 9
    Last Post: 09-12-2007, 07:18 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
  •