Torque control and replication

Typically: "How do I... ", "How can I... " questions
Post Reply
bayouma1

Torque control and replication

Post by bayouma1 »

Hello,
I am currently trying to design a simple model to learn robot dynamics from
data. For this, I am sending specific joint poses and trying to query for
the torque which VREP applied so I can use this data later for my model.
However, I have the following issues:
1. When sending multiple poses (even with triggering), only the last pose
sent gets executed.
2. When trying to apply the torques observed again to the model (with very
high velocity and setting my desired torques as max torques), nothing
happens and the robot doesn't move.
I am currently using MATLAB for API communication. Any help would be
appreciated.

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

Re: Torque control and replication

Post by coppelia »

Hello,

you will of course have to wait until one of the desired pose is reached, before sending the second on. How the movement is executed entirely depends on how you implemented things. Have a look at the demo scene Scenes/messaging/movementViaRemoteApi.ttt and its corresponding client code:
  • programming/b0remoteApiBindings/python/sendMovementSequence-mov.py
  • programming/b0remoteApiBindings/python/sendMovementSequence-pts.py
  • programming/b0remoteApiBindings/python/sendSimultanMovementSequences-mov.py
  • programming/remoteApiBindings/python/python/sendMovementSequence-mov.py
  • programming/remoteApiBindings/python/python/sendMovementSequence-pts.py
  • programming/remoteApiBindings/python/python/sendSimultanMovementSequences-mov.py
In general, try to first have your test able to run within CoppeliaSim, before attempting to reproduce the same from an external application: from an external application, there are many other factors that needs to be paid close attention, namely to have your external application run synchronously with CoppeliaSim, depending on the type of application. So if you are a beginner and try to cumulate all tasks at once, then you'll never know where your problems originate from: from the communication? From the algorithm, from CoppeliaSim, etc.

Cheers

Post Reply