Palletizing or Offset Locations

  • I'm trying to pick and place a grid of 78 parts in and out of a laser engraver. My rows and columns are aligned to the world coordinate system. 13 rows parallel to the x axis. Each row spaced at 2.5 inches. 6 columns parallel to y, each spaced at 4 inches. I would like to teach one position above the part to pick and one on the part. What is the best approach to program the other 77 locations? Can you share a program example? Steps will be pick one part, engrave it and place it back. Then go do the same to the next part. Thanks!!!

  • Here's an example of picking objects and placing them in a grid.


    https://mh142.com/wiki/Pepperoni_Bot


    This program's "destination" half is almost identical to what you want to do. Once a location is used, move to the next. Once all items in a row are used, move to the next row and begin again from the first column. Continue on until finished.


    In your case, the program for picking up a piece would be the same positions and offsets as the placing, simplifying matters a bit. You only have to use one offset position register, and all of your motion instructions would be the same.



    I've written an example below. I don't know what inches look like on the FANUC controllers so I've written it in millimeters, but you probably know how to do it in the units you use.

    You're absolutely correct about only wanting two positions. Motion would look like this:



    LBL[1]


    Pick up from tray:


    J P[1:Above_Part] 100% FINE OFFSET PR[18:GRID]

    L P[2:At_Part] 100mm/s FINE OFFSET PR[18:GRID]

    RO[1:Vacuum] = ON

    L P[1:Above_Part] 100mm/s FINE OFFSET PR[18:GRID]


    (your motion to the engraver would go here)


    Placement back in tray:


    WAIT DI[101:ENGRAVERFINISHEDSIGNAL] = ON

    J P[1:Above_Part] 100% FINE OFFSET PR[18:GRID]

    L P[2:At_Part] 100mm/s FINE OFFSET PR[18:GRID]

    RO[1:Vacuum] = OFF

    L P[1:Above_Part] 100mm/s FINE OFFSET PR[18:GRID]



    After each cycle of pick and place, add 2.5 inches to the X element of the position register.


    PR[18, 1:GRID] = PR[18, 1:GRID] + 63.5


    Check to see if the X element is still within your grid. If so, the row isn't finished, so jump back up to before the motion.


    IF PR[18,1:GRID] < 762 JMP LBL[1]


    If not - set the X offset to zero, and add 4 inches to the Y element of your offset to start the next column.


    PR[18, 1:GRID] = 0


    PR[18, 2:GRID] = PR[18, 2:GRID] + 101.6


    Check to see if the Y offset is still within your grid. If so, the columns aren't finished, so jump back to before the motion.


    IF PR[18,2:GRID] < 508 JMP LBL[1]


    If not - go to a safe HOME position and alert the technician to load a new batch of product.


    The if statements may not build with PR elements using the < selection on older robots (dunno why) but you can do it with the mixed logic selection (...).



    The very beginning of your program should include PR[18] = PR[18] - PR[18] to clear all of its elements as zero, so that every time it starts a tray it will start from the beginning. You can also add instructions for manually setting the start row/column, but since PR's are global variables and non-volatile, a power outage and reboot will start right from where it left off without issue.

    Edited 2 times, last by Mike13815: added part about cleanup of the position register. ().

  • Very interesting! I'll give this a go in the morning. After your explanation it seems pretty straight forward to implement. Thanks.

Advertising from our partners