PID and Python

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

PID and Python

Post by mech »

Hello, how can I customize the control loop directly in the python environment (setting up gains and all) instead of setting it up in Coppelia (I know it is harder that way but it is for a certain reason)?

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

Re: PID and Python

Post by coppelia »

Hello,

if you want to control a joint from an external application, then you should make sure to run CoppeliaSim in synchronous or stepped mode, and if the joint is dynamically enabled, then make sure you use the same simulation time step size (by default 50ms) as the dynamics time step size (by default 5ms).

Have a look at the demo scene messaging/pControllerViaRemoteApi.ttt. I highly recommend that for that, you use the ZeroMQ-based remote API, since this makes everything much simpler.

Cheers

Post Reply