About controlling the robot in V-REP and in reality

Typically: "How do I... ", "How can I... " questions
Post Reply
youngsea
Posts: 18
Joined: 11 Apr 2016, 12:40

About controlling the robot in V-REP and in reality

Post by youngsea » 02 Aug 2016, 16:20

Hi~I have a qusetion about controlling the robot in V-REP and the robot in reality.The computer programs compiled by V-REP can control the KUKA Robot in V-REP,however,can it control the KUKA Robot in reality?In other words,can the code which can run in V-REP run in the robot system in real robot?and does it have the same effect in controlling the KUKA robot in V-REP and the KUKA robot in reality?
If not, are there any solution to transform the VREP-Code to the code which can run in real robot ?
Thanks!

coppelia
Site Admin
Posts: 7199
Joined: 14 Dec 2012, 00:25

Re: About controlling the robot in V-REP and in reality

Post by coppelia » 03 Aug 2016, 09:22

Hello,

it always depend on which robot and what control system we are talking about:
  • If you control your simulated robot via the RosInterface, then you could send the same messages to the real robot (if it is linked to ROS)
  • If you control your simulated robot via the remote API, then you could instead of sending the messages to the simulated robot, generate real world actions (control the motors, etc.)
  • if you connect V-REP with the robot's RCS module, then you can often also directly generate real robot programs based on RRS1-interface commands. The RRS-1 interface (i.e. Realistic Robot Simulation interface) is available as a plugin (v_repExtRRS1)
  • you can also write a plugin that translates commands to a specific robot language, and so have your real robot move.
Cheers

youngsea
Posts: 18
Joined: 11 Apr 2016, 12:40

Re: About controlling the robot in V-REP and in reality

Post by youngsea » 04 Aug 2016, 16:33

Thanks~coppelia!
Now I want to write some code to control KUKA Robot in V-REP.If I want to use these code to control the real KUKA Robot by writting a plugin.And the KUKA Robot system use the KRL,a computer lanuage like C.Do you think a plugin can translate the V-REP commands to KRL?And what should I do about writting this specific plugin?And maybe the commands in V-REP is also specific to control the robot,is it right?

fferri
Posts: 343
Joined: 09 Sep 2013, 19:28

Re: About controlling the robot in V-REP and in reality

Post by fferri » 05 Aug 2016, 09:41

In our lab, we had a custom built mobile robot, with ROS drivers and ROS C++ nodes for controlling it.

We created a robot model in V-REP, and then we used the V-REP RosInterface plugin, implementing the same messages used to command the robot, so we could test our nodes with a simulated version of our robot.

youngsea
Posts: 18
Joined: 11 Apr 2016, 12:40

Re: About controlling the robot in V-REP and in reality

Post by youngsea » 05 Aug 2016, 11:48

Thanks~fferri.You use the RosInterface to control the KUKA Robot(the first method above).About the KRL in KUKA Robot,do you think the forth method above can do that?

coppelia
Site Admin
Posts: 7199
Joined: 14 Dec 2012, 00:25

Re: About controlling the robot in V-REP and in reality

Post by coppelia » 05 Aug 2016, 12:54

If you have a specific robot language you need to support (or generate), then you most probably have to write a plugin. You have two situations:
  • you want to control a simulated robot with the KRL language. You will have to write a KRL language interpreter that will for instance translate into a trajectory.
  • you want to generate KRL commands based on a robot trajectory.
We recommend however you familiarize yourself with the RRS-1 interface specifications. Many robot RCS modules will first translate RRS1 code into their specific robot language (e.g. KRL)

Cheers

Post Reply