locked
Kinematics using VPL RRS feed

  • Question

  • Hi,
    I am new to robotics studio and I'm trying to control the Kuka simulated robot in MSRS so that I could type in D-H parameters and have the robot give move to the Cartesian point within the virtual world but I don't know how to write the program in VPL to perform this. Can anyone please give me some advice?
    Thanks
    Monday, May 12, 2008 7:21 PM

Answers

  • You should still look at the sample code for our book. Chapter 8 has a simulated Lynx L6 arm and Chapter 15 covers the real L6 arm. The forward and inverse kinematics calculations are embedded in the services and everything is written in C#. That should provide you with a starting point. However, the code is for V1.5. You can migrate it to V2.0 without too much trouble, but we are not going to offer a download until the final release of V2.0.

     

    I don't understand why you would have problems with the mouse in MSRS V1.5. It has nothing to do with mice.

     

    Quaternions are not too scary. Look them up on Wikipedia. The MSRS Simuator uses them extensively.

     

    If you want to change the number of links, you will have to write some C# code anyway. This is not something that I would even attempt in VPL.

     

    Trevor

     

    Friday, May 16, 2008 5:39 AM

All replies

  • Once you have a LBR3 in the VPL diagram, you can use the GetEndEffectorPose and SetEndEffectorPose operations to control it. The pose consists of an Orientation (which is a Quaternion) and a Position (3D coordinate).

     

    Are you aware that the Simple Dashboard can be used to move the joints on the robot? What I suggest that you do is write a simple VPL program that does a GetEndEffectorPose and displays the results using a Simple Dialog. Drag the Simple Dashboard to your diagram as well. It does not need any connections. Then use the Dashboard to move the arm around and see what results you get. You will need to put in a timer, or a button or some way to control how often the GetEndEffectorPose is executed so that you don't fill the screen up with dialog boxes.

     

    Once you know what the pose information is for various positions of the arm, you can try using SetEndEffectorPose. Bear in mind that there are seven values that have to be specified for the position (x, y, z) and orientation (x, y, z, w).

     

    The main point is that you need to know how the coordinate system works. You should be able to ofigure this out with a little trial and error. (I don't know.) You will also need to understand quaternions if you want to change the angle of the end effector. However, just getting to a given (x,y,z) initially should be enough.

     

    Trevor

     

    P.S. My updated Dashboard which is part of the sample code for our upcoming book has a Get Pose button that does a GetEndEffectorPose and displays the results. You can download the code (for MRDS V1.5) from http://www.promrds.com/Downloads.htm and look in Chapter 4.

    Wednesday, May 14, 2008 8:03 AM
  • Hi Trevor,

    Thanks for getting back to me, I tried viewing the code for the GetEndEffectorPose but I couldn't since I am using the CTP version of MSRS and I had some problems running getting the mouse to work on MSRS 1.5. I am still not sure how to use the GetEndEffectorPose and SetEndEffectorPose operations and how do I even obtain them since I don't see them among the services? Is there a way I can do without using quaternions since we didn't cover them in class? We use euler xyz or zyz angles or fixed angles. I must say that I am really confused, all i desire to do for now is simulate a generic robotic arm, have the user type in D-H parameters as well as number of links and then have the simulated robot ( i.e. the links) move to what it estimates is the Cartesian representation (in the virtual world) of the values entered as inputs. I know I would need some transformations and I know how to do them on paper but doing all this in MSRS is very confusing to me. Would it be easier doing this in C# or another language? cause I see that there is some tutorial under C# and I was trying to learn C#  as fast as I can to understand the code. Please help me, I need to turn in my result in a few weeks and I am working so hard but not getting very far.

    Onyeka
    Thursday, May 15, 2008 9:16 AM
  • You should still look at the sample code for our book. Chapter 8 has a simulated Lynx L6 arm and Chapter 15 covers the real L6 arm. The forward and inverse kinematics calculations are embedded in the services and everything is written in C#. That should provide you with a starting point. However, the code is for V1.5. You can migrate it to V2.0 without too much trouble, but we are not going to offer a download until the final release of V2.0.

     

    I don't understand why you would have problems with the mouse in MSRS V1.5. It has nothing to do with mice.

     

    Quaternions are not too scary. Look them up on Wikipedia. The MSRS Simuator uses them extensively.

     

    If you want to change the number of links, you will have to write some C# code anyway. This is not something that I would even attempt in VPL.

     

    Trevor

     

    Friday, May 16, 2008 5:39 AM