Code: Select all
function sysCall_actuation()
-- put your actuation code here
local position = sim.getObjectPosition(SphereHandle,-1)
-- dt = 0.05 (Simulation dt) and vx = 0.2 [m/s]
x = position[1] + dt*vx
sim.setObjectPosition(SphereHandle,{x,0,0.125},sim.handle_world)
end
- The reaction force varies significantly between different physics engines.
- The reaction force changes significantly with varying step sizes.
CoppeliaSim Edu, Version 4.6.0 (rev. 6) (Qt Version 5.15.0, MSVC2019). Windows 10 OS.