Results 1 to 7 of 7

Thread: Okuma's User Task 2

  1. #1
    Registered
    Join Date
    Oct 2007
    Location
    US
    Posts
    48
    Downloads
    0
    Uploads
    0

    Okuma's User Task 2

    I'm still learning the different ways I can exploit Okuma's User Task language and wondered if I could do one thing in particular. Is there anyway I can read from the main program the furthest point a particular tool goes in X or Z? I wrote a bar pulling subroutine and I'm trying to make it smarter. I'm hoping there is some way the sub can query the main program and use the cutoff tools last point to know where it should pull from.


  2. #2
    Registered
    Join Date
    Oct 2007
    Location
    US
    Posts
    48
    Downloads
    0
    Uploads
    0
    I'm thinking I can use VSIOZ(Z Axis command target point) or VAPAZ(Z axis active point) but I've never used them before. I will tinker with them today but if anybody else has any ideas I would love to hear them.


  3. #3
    Registered
    Join Date
    Oct 2007
    Location
    US
    Posts
    48
    Downloads
    0
    Uploads
    0
    VSIOZ Worked like a charm. Now I can just insert CALL OBAR right after my part off on any job and the sub knows everything automatically. Maybe I should be posting this in the Okuma section (which I didn't see at first) Is this why I'm not getting any responses?


  4. #4
    Registered broby's Avatar
    Join Date
    Apr 2006
    Location
    Australia
    Posts
    643
    Downloads
    0
    Uploads
    0

    Question

    Why do you need to know this information?
    If you have just parted off the component at a known Z value, Then surely the bar puller should be programmed to come into this point to grab the part and pull the required distance of material out of the chuck. (Keep in mind I have no idea what your Bar puller looks like nor how it operates).
    Are you familiar with how to pass variables into your subroutines?
    I would pass in the position of where you expect to find the end face and also the distance you need to pull out.
    Cheers
    Brian.


  • #5
    Registered
    Join Date
    Oct 2007
    Location
    US
    Posts
    48
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by broby View Post
    Why do you need to know this information?
    If you have just parted off the component at a known Z value, Then surely the bar puller should be programmed to come into this point to grab the part and pull the required distance of material out of the chuck. (Keep in mind I have no idea what your Bar puller looks like nor how it operates).
    Are you familiar with how to pass variables into your subroutines?
    I would pass in the position of where you expect to find the end face and also the distance you need to pull out.
    Cheers
    Brian.
    Well the variable 'VSIOZ' is the Z axis command point. By calling my bar pull from the part off point I can have the bar pull subroutine automatically know where it needs to go for its pull and by multiplying that number by -1 and adding .02 (face allowance) it knows how far to pull it out. No need to pass any variables. The only variables I pass are the bar diameter and the tool number for the puller. Heres my program it has changed a lot but this version is fully tested and kicks ass. It works extremely well. Maybe by examining the code you can see what I was after and why. The next step is to add a loop in the new bar section that sets up a loop while the chuck is open. This will prevent a stupid mistake that would throw an alarm and require a reset of the main program.

    Code:
    OBAR
    (**********************************************************************************)
    (OKUMA BAR PULL MACRO                                                              )
    (*2/20/2008*                                                          )
    (CALL THIS PROGRAM RIGHT AFTER PART OFF TOOL, DO NOT RAPID PART OFF TOOL AWAY FROM )
    (PART OFF POINT BEFORE CALLING THS CYCLE. THE PROGRAM USES THIS POINT TO FIGURE ITS)
    (PULL DISTANCE!                                                                   )
    (THIS PROGRAM MUST BE SAVED AS OBAR.SSB                                            )
    (PROGRAM EXAMPLE:                                                                  )
    (CALL OBAR DIA=2.0 TOOL=1                                                          )
    (WHERE 'DIA' IS THE STOCK DIAMETER AND 'TOOL' IS THE TOOL NUMBER OF THE PULLER     )
    (**********************************************************************************)
    BARL=36.0(BAR LENGTH)
    
    FFA=.02(FACE FINISH ALLOWANCE)
    
    DROP=3.0(DESIRED DROP LENGTH LEFT IN CHUCK)
    (****************************)
    (*DO NOT EDIT BLOW THIS LINE*)
    (****************************)
    BARN=0
    
    M5M9
    N1
    
    IF[BARN EQ 1]N2
    
    V199=VETLN
    
    PARL=VSIOZ*-1
    
    PTCT=ROUND[BARL-DROP/[PARL+FFA]]
    G00X20.
    
    Z5.0
    
    N2
    NEWB=0
    V200=V200+1
    
    IF[V200 GT PTCT]N3
    
    T[TOOL*101]
    
    X[DIA+1.5]Z-[PARL+.5]
    
    G01 G94 X0. F200.
    
    M84
    
    G91Z[PARL+FFA]
    
    G90
    
    M83
    
    G95
    
    G0X20.
    
    Z5.0
    
    N3 IF[V200 LE PTCT]N4
    
    M84
    
    M00
    (INSERT NEW BAR)
    (NEED TO INSERT CHUCK STATE CHECK HERE)
    
    G00 G96 M3 S1000 T[V199*101]
    
    X[DIA+.1]Z-[PARL]M8
    
    G1X-.01F.004
    
    G0X[DIA+.1]M9
    
    M5
    
    X20.
    
    Z5.0
    BARN=1
    V200=0
    
    GOTO N1
    
    N4
    
    RTS


  • #6
    Registered broby's Avatar
    Join Date
    Apr 2006
    Location
    Australia
    Posts
    643
    Downloads
    0
    Uploads
    0
    Is your program set for Z0 at the front face or the back face? I am presuming it is at the front face, thus your use of the parting posn info. Neat way of doing this I must admit!


  • #7
    Registered
    Join Date
    Oct 2007
    Location
    US
    Posts
    48
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by broby View Post
    Is your program set for Z0 at the front face or the back face? I am presuming it is at the front face, thus your use of the parting posn info. Neat way of doing this I must admit!
    I always program from the front. If my zero was in the back the bar pull would be simple. I could always go to Z-.5 for the pull but I would have to figure a way for the sub to extrapolate it's pull distance without me passing variables manually. I love smart programs, they make me smile lol.


  • Similar Threads

    1. Shop Task Gunmaster 17-32 XMTC Worth getting?
      By strykerakamack in forum Shopmaster/Shoptask
      Replies: 13
      Last Post: 01-14-2010, 02:37 AM
    2. Shop task complaints post here
      By digitalmdj in forum Vendor Discussion
      Replies: 18
      Last Post: 12-09-2007, 10:08 AM
    3. Right VMC for the task
      By hardrocker in forum General Metal Working Machines
      Replies: 0
      Last Post: 04-05-2007, 10:55 PM
    4. Daunting task
      By mikie in forum DIY CNC Router Table Machines
      Replies: 7
      Last Post: 08-06-2003, 07:28 PM

    Posting Permissions


     


    About CNCzone.com

      We are the largest and most active discussion forum from DIY CNC Machines to the Cad/Cam software to run them. The site is 100% free to join and use, so join today!

    Follow us on

    Facebook Dribbble RSS Feed


    Search Engine Friendly URLs by vBSEO ©2011, Crawlability, Inc.