1. Home
    1. Dashboard
    2. Search
  2. Forum
    1. Unresolved Threads
    2. Members
      1. Recent Activities
      2. Users Online
      3. Team Members
      4. Search Members
      5. Trophys
  3. Articles
  4. Blog
  5. Videos
  6. Jobs
  7. Shop
    1. Orders
  • Login or register
  • Search
This Thread
  • Everywhere
  • This Thread
  • This Forum
  • Articles
  • Pages
  • Forum
  • Blog Articles
  • Products
  • More Options
  1. Robotforum - Support and discussion community for industrial robots and cobots
  2. Forum
  3. Industrial Robot Support and Discussion Center
  4. KUKA Robot Forum
Your browser does not support videos RoboDK Software for simulation and programming
Visit our Mainsponsor
IRBCAM
Robotics Channel
Robotics Training
Advertise in robotics
Sponsored Ads

Incremental & decremental circular program

  • Ankit1995
  • February 21, 2024 at 11:20 AM
  • Thread is Unresolved
  • Ankit1995
    Trophies
    1
    Posts
    16
    • February 21, 2024 at 11:20 AM
    • #1

    I want to make a program in kuka robot - Like let say i have a circle of 100mm diameter, i want shift the 'Z' height at the edges of the circle as the diameter increases (roughly i want to travel & shift the Z height by 10 mm as the dia increases.

    After reaching at the center of the circle, the length of movement should be in decremental order for the lower half portion of the circle.
    Can anyone help me to make the program.

  • 95devils February 21, 2024 at 11:40 AM

    Approved the thread.
  • panic mode
    Reactions Received
    1,296
    Trophies
    11
    Posts
    13,136
    • February 21, 2024 at 1:40 PM
    • #2

    Far from clear....

    1) read pinned topic: READ FIRST...

    2) if you have an issue with robot, post question in the correct forum section... do NOT contact me directly

    3) read 1 and 2

  • Lemster68 February 21, 2024 at 2:18 PM

    Moved the thread from forum Robot Geometry, Linear Algebra, Forward and Inverse Kinematics to forum KUKA Robot Forum.
  • Hes
    Reactions Received
    42
    Trophies
    2
    Posts
    243
    • February 21, 2024 at 7:08 PM
    • #3

    What is it that you are seeking? A conical spiral, a regular spiral, somekind of ellipsis, a skewed circle?

  • hermann
    Reactions Received
    411
    Trophies
    9
    Posts
    2,623
    • February 22, 2024 at 7:44 AM
    • #4
    Quote from Ankit1995

    .. i want shift the 'Z' height at the edges of the circle..

    Already this part is kind of strange. Haven't ever seen a circle with an edge :hmmm:

  • Ankit1995
    Trophies
    1
    Posts
    16
    • February 27, 2024 at 5:25 AM
    • #5

    For easy understanding, I want to move kuka robot horizontally towards top to bottom, while each 'z' height shift to be 5 mm but the shift can done slightly (25mm outside) from the outside of the circle.

  • Fubini
    Reactions Received
    283
    Trophies
    9
    Posts
    1,904
    • February 27, 2024 at 5:55 AM
    • #6

    Still not clear. Could you provide a picture?

  • SkyeFire
    Reactions Received
    1,060
    Trophies
    12
    Posts
    9,456
    • February 27, 2024 at 2:15 PM
    • #7

    This sounds like it might be a spiral boring action, similar to the red toolpath seen here:

    External Content youtu.be
    Content embedded from external sources will not be displayed without your consent.
    Through the activation of external content, you agree that personal data may be transferred to third party platforms. We have provided more information on this in our privacy policy.

    I've attached a library I built years ago to generate circular motions as a series of mathematically generated LIN points. It wouldn't be hard to add a Z step.

    Files

    GeneralEllipsoid.zip 107.66 kB – 14 Downloads
  • Ankit1995
    Trophies
    1
    Posts
    16
    • February 28, 2024 at 11:24 AM
    • #8

    Thanks for help but Sorry to say but i dont know how to attach a JPEG/ZIP file as i'm very new to this forum. :confused_face: :confused_face:

    Please check the image & help me now.
    https://we.tl/t-gk0qHN6WYn

  • SkyeFire
    Reactions Received
    1,060
    Trophies
    12
    Posts
    9,456
    • February 28, 2024 at 2:51 PM
    • #9
    Quote from Ankit1995

    Please check the image & help me now.
    https://we.tl/t-gk0qHN6WYn

    No, sorry. That site demands I give up my privacy just to view the file. Try a different host. You could also try answering my previous question.

  • panic mode
    Reactions Received
    1,296
    Trophies
    11
    Posts
    13,136
    • February 28, 2024 at 2:53 PM
    • #10

    1) read pinned topic: READ FIRST...

    2) if you have an issue with robot, post question in the correct forum section... do NOT contact me directly

    3) read 1 and 2

  • SkyeFire
    Reactions Received
    1,060
    Trophies
    12
    Posts
    9,456
    • February 28, 2024 at 3:13 PM
    • #11
    Quote from panic mode

    A raster scan of a circle? Hm.... Well, my GeneralEllipsoid module would produce an array of points around the circumference. It would just need an extra step to re-sort the array into a raster rather than a circular motion. Something like:

    Code
      ; Sort for Raster Scan
      REPEAT
        FOR _i = 1 TO 300
          IF NextPos[_i].X > NextPos[_i+1].Z THEN
            _pTemp = NextPos[_i]
            NextPos[_i] = NextPos[_i+1]
            NextPos[_i+1] = _pTemp
            _bSort = TRUE
          ELSE
            _bSort = FALSE
          ENDIF
        ENDFOR
      UNTIL NOT _bSort
    Display More

    That's just off the cuff, and I don't have a way to test it right now. And it would require a second stage to arrange for the small "vertical" move at each end... hm. I'm sure there's a way to do it, but I'm short on time right now.

  • panic mode
    Reactions Received
    1,296
    Trophies
    11
    Posts
    13,136
    • February 28, 2024 at 4:19 PM
    • #12

    maybe something like this. just an idea - some debugging may be needed...

    Code
    DEF circ_fill(start_pos:in,aux_pos:in,target_pos:in,spacing:in)
      DECL FRAME approach, edge1,edge2,start_pos,aux_pos,target_pos, base_pts[3]
      DECL FRAME temp_base, prev_base
      DECL REAL spacing,r,x,y,dx,dy,dz
      decl bool neg
      DECL ORI_TYPE prev_ori
      DECL INT i
    
      base_pts[1] = start_pos
      base_pts[2] = target_pos
      base_pts[3] = aux_pos
      temp_base   = CalcBase(base_pts[])
      
      dx = target_pos.x - start_pos.x
      dy = target_pos.y - start_pos.y
      dz = target_pos.z - start_pos.z 
      r  = 0.5*sqrt(dx*dx+dy*dy+dz*dz)
    
      approach = $POS_ACT
      prev_ori =$ORI_TYPE
      LIN start_pos
      $ORI_TYPE=#CONSTANT  
      prev_base = $BASE
      $BASE     = temp_base  
      edge1     = $nullframe
      edge2     = $nullframe  
      neg       = false
      i=0
      WHILE (edge1.x+spacing)<=2*r
        i=i+1 
        edge1.X = edge1.X+spacing
        edge1.Y = sqrt(r*r-(r-edge1.x)*(r-edge1.x))
        edge2.X = edge1.X
        edge2.Y = -edge1.Y
        if neg then
          LIN edge1 
          LIN edge2
        else
          LIN edge2
          LIN edge1
        endif
        neg = not neg
      ENDWHILE
      
      $BASE = prev_base
      LIN target_pos
      LIN approach
      $ORI_TYPE=prev_ori
    end
    Display More

    1) read pinned topic: READ FIRST...

    2) if you have an issue with robot, post question in the correct forum section... do NOT contact me directly

    3) read 1 and 2

  • panic mode
    Reactions Received
    1,296
    Trophies
    11
    Posts
    13,136
    • February 29, 2024 at 3:54 AM
    • #13

    CalcBase is found on forum, for example

    Post

    Re: Create Base manually from 3 Touch'up points

    Hello Naathaaanb,

    use attached function to calculate a new base.

    put the 3 positions in an Array of frame fNewB[3]

    (Code, 6 lines)

    A,B and C will be right if the fNewB[3] are correct

    Greets Loipe
    Loipe
    March 5, 2019 at 2:04 PM

    the end result is something like this:

    Files

    2024-02-28 21-46-36.zip 8.78 MB – 10 Downloads

    1) read pinned topic: READ FIRST...

    2) if you have an issue with robot, post question in the correct forum section... do NOT contact me directly

    3) read 1 and 2

  • Ankit1995
    Trophies
    1
    Posts
    16
    • February 29, 2024 at 5:48 AM
    • #14
    Quote from panic mode

    CalcBase is found on forum, for example

    Post

    Re: Create Base manually from 3 Touch'up points

    Hello Naathaaanb,

    use attached function to calculate a new base.

    put the 3 positions in an Array of frame fNewB[3]

    (Code, 6 lines)

    A,B and C will be right if the fNewB[3] are correct

    Greets Loipe
    Loipe
    March 5, 2019 at 2:04 PM

    the end result is something like this:

    1. Can you show where to teach points on small circle only, as i need to program only 1 circle at a time.
    2. In line no. 17 & 20, into the bracket what is written after - (Xp1, Xp2, Xp3,. ....) because it is not clearly visible in video.

    thanks in advance.

  • panic mode
    Reactions Received
    1,296
    Trophies
    11
    Posts
    13,136
    • February 29, 2024 at 6:01 AM
    • #15

    in current version raster runs from start point to target point. distance between those two points is diameter of the circle. the aux point is used to set the plane. it just need to be on the circle/disc, as long as it is away from center axis (green line). it does not need to be on the edge.

    1) read pinned topic: READ FIRST...

    2) if you have an issue with robot, post question in the correct forum section... do NOT contact me directly

    3) read 1 and 2

  • panic mode
    Reactions Received
    1,296
    Trophies
    11
    Posts
    13,136
    • February 29, 2024 at 6:06 AM
    • #16

    circ_fill() has 4 parameters:

    start point

    aux point

    target point

    distance between raster lines (in millimeters)

    the larger the distance value, the fewer raster lines will be calculated.

    if you watch the video, first it does small circle using 80mm raster,

    then it repeats the same circle using 20mm raster....

    i used large values just to make shorter video (smaller file size)

    you must be watching the video on the phone. if you watch it on computer, you should be able to see more detail. screenshot below is taken from the video and it looks pretty readable to me:

    1) read pinned topic: READ FIRST...

    2) if you have an issue with robot, post question in the correct forum section... do NOT contact me directly

    3) read 1 and 2

  • Ankit1995
    Trophies
    1
    Posts
    16
    • February 29, 2024 at 6:19 AM
    • #17
    Quote from panic mode

    circ_fill() has 4 parameters:

    start point

    aux point

    target point

    distance between raster lines (in millimeters)

    the larger the distance value, the fewer raster lines will be calculated.

    if you watch the video, first it does small circle using 80mm raster,

    then it repeats the same circle using 20mm raster....

    i used large values just to make shorter video (smaller file size)

    Display More

    Yes i have understood. I just tried this program just for single circle & for 20 mm distance. But Circ_fill(xP1,xP2,xP3,20), treating this line as a subprogram & it gives error. So again i need your help that did you make any subprogram for line no. 20 ?

  • Ankit1995
    Trophies
    1
    Posts
    16
    • February 29, 2024 at 6:26 AM
    • #18
    Quote from SkyeFire

    A raster scan of a circle? Hm.... Well, my GeneralEllipsoid module would produce an array of points around the circumference. It would just need an extra step to re-sort the array into a raster rather than a circular motion. Something like:

    Code
      ; Sort for Raster Scan
      REPEAT
        FOR _i = 1 TO 300
          IF NextPos[_i].X > NextPos[_i+1].Z THEN
            _pTemp = NextPos[_i]
            NextPos[_i] = NextPos[_i+1]
            NextPos[_i+1] = _pTemp
            _bSort = TRUE
          ELSE
            _bSort = FALSE
          ENDIF
        ENDFOR
      UNTIL NOT _bSort
    Display More

    That's just off the cuff, and I don't have a way to test it right now. And it would require a second stage to arrange for the small "vertical" move at each end... hm. I'm sure there's a way to do it, but I'm short on time right now.

    Thanks & take your time, i'm looking forward for your help.

  • panic mode
    Reactions Received
    1,296
    Trophies
    11
    Posts
    13,136
    • February 29, 2024 at 7:05 AM
    • #19
    Quote from Ankit1995

    Yes i have understood. I just tried this program just for single circle & for 20 mm distance. But Circ_fill(xP1,xP2,xP3,20), treating this line as a subprogram & it gives error. So again i need your help that did you make any subprogram for line no. 20 ?

    did you take the code from post #12 and save it as CIRC_FILL.SRC?

    did you put it on the robot?

    did you do the same with CalcBase.src?

    if you need help you need to be a lot more proactive with providing data. "it gives an error" tells me nothing.

    1) read pinned topic: READ FIRST...

    2) if you have an issue with robot, post question in the correct forum section... do NOT contact me directly

    3) read 1 and 2

  • Ankit1995
    Trophies
    1
    Posts
    16
    • February 29, 2024 at 7:27 AM
    • #20
    Quote from panic mode

    did you take the code from post #12 and save it as CIRC_FILL.SRC?

    did you put it on the robot?

    did you do the same with CalcBase.src?

    if you need help you need to be a lot more proactive with providing data. "it gives an error" tells me nothing.

    did you take the code from post #12 and save it as CIRC_FILL.SRC? - YES

    did you put it on the robot? - YES

    did you do the same with CalcBase.src? - I DID SIMPLY BASE CALCULATION FROM TOOL/BASE MANAGEMENT SYSTEM. IS IT NECESSARY TOO?

Advertising from our partners

IRBCAM
Robotics Channel
Robotics Training
Advertise in robotics
Advertise in Robotics
Advertise in Robotics

Job Postings

  • Anyware Robotics is hiring!

    yzhou377 February 23, 2025 at 4:54 AM
  • How to see your Job Posting (search or recruit) here in Robot-Forum.com

    Werner Hampel November 18, 2021 at 3:44 PM
Your browser does not support videos RoboDK Software for simulation and programming

Tag Cloud

  • abb
  • Backup
  • calibration
  • Communication
  • CRX
  • DCS
  • dx100
  • dx200
  • error
  • Ethernet
  • Ethernet IP
  • external axis
  • Fanuc
  • help
  • hmi
  • I/O
  • irc5
  • IRVIsion
  • karel
  • kawasaki
  • KRC2
  • KRC4
  • KRC 4
  • krc5
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • roboguide
  • robot
  • robotstudio
  • RSI
  • safety
  • Siemens
  • simulation
  • SPEED
  • staubli
  • tcp
  • TCP/IP
  • teach pendant
  • vision
  • Welding
  • workvisual
  • yaskawa
  • YRC1000

Thread Tag Cloud

  • abb
  • Backup
  • calibration
  • Communication
  • CRX
  • DCS
  • dx100
  • dx200
  • error
  • Ethernet
  • Ethernet IP
  • external axis
  • Fanuc
  • help
  • hmi
  • I/O
  • irc5
  • IRVIsion
  • karel
  • kawasaki
  • KRC2
  • KRC4
  • KRC 4
  • krc5
  • KRL
  • KUKA
  • motoman
  • Offset
  • PLC
  • PROFINET
  • Program
  • Programming
  • RAPID
  • roboguide
  • robot
  • robotstudio
  • RSI
  • safety
  • Siemens
  • simulation
  • SPEED
  • staubli
  • tcp
  • TCP/IP
  • teach pendant
  • vision
  • Welding
  • workvisual
  • yaskawa
  • YRC1000

Users Viewing This Thread

  • 1 Guest
  1. Privacy Policy
  2. Legal Notice
Powered by WoltLab Suite™
As a registered Member:
* You will see no Google advertising
* You can translate posts into your local language
* You can ask questions or help the community with your knowledge
* You can thank the authors for their help
* You can receive notifications of replies or new topics on request
* We do not sell your data - we promise

JOIN OUR GREAT ROBOTICS COMMUNITY.
Don’t have an account yet? Register yourself now and be a part of our community!
Register Yourself Lost Password
Robotforum - Support and discussion community for industrial robots and cobots in the WSC-Connect App on Google Play
Robotforum - Support and discussion community for industrial robots and cobots in the WSC-Connect App on the App Store
Download