Need to make a simus movement!

iRobotMac Klepp Stasjon
Hi guys, 

I have a challange to make the robot go like sinus movement. The equation is: x=(1-cos(2*pi*2))^2.  How do i put this in RAPID and make the robot understand it ?

Please help me :) !!



  • edwinderry
    edwinderry United Kingdom ✭✭

    Do you mean a sine wave, like the attached? If so I have some RAPID code that you could use.


  • blind3rr
    blind3rr Czech Republic
    @edwinderry: Could you please share the code? For me is also interesting. Thanks in advance!

    Benteler Maschinenbau CZ
  • bob865
    bob865 Greer, SC

    @edwinderry I would like to see this as well.  Just more information to learn from.


  • B_Baan
    B_Baan Nieuwegein, the Netherlands
    edited January 2015
    I believe that is not a very hard thing to do.

    Theoretically, you are moving along a straight line, just moving up and down (left and right, whatever you wish) along that line.

    You should define how many points you can put in between of the source- and destinationpositions.

    When you know the amount of positions you gotta move to in between of the source and destination, you know the amount of sine waves (that is X points / 2, since one wave = 2 points. One low point and a high point).

    After this, you need to know the distance of the original line you move between, then you can calculate at what distances you want the points to be. Also, the height of one wave (from the original line to the top) must be known, then you can create a position.

    You can also add support for rotation around the Z axis, which will let you move your robot in a sine wave which isn't up and down, but maybe left and right along a line.

    Unfortunately I don't have any code to send you, but if this doesn't help you i might be able to write some in my free time.