Search found 8987 matches

by coppelia
03 Dec 2021, 15:38
Forum: General questions
Topic: How to optimize the control of manipulator
Replies: 3
Views: 444

Re: How to optimize the control of manipulator

In V4.2.0+, you would for instance select the calculation method with simIK.setIkGroupCalculation
Have a look at the kinematics plugin page for an example, and the many examples in scenes/kinematics/ folder.

Cheers
by coppelia
02 Dec 2021, 10:47
Forum: General questions
Topic: Quadcopter Propellers
Replies: 1
Views: 94

Re: Quadcopter Propellers

Hello, make sure you use CoppeliaSim V4.2.0 or later. The object handle is needed mainly to be able to apply a force and torque to the related propeller origin. The rotation of the propeller is just visuals). The model works by applying vertical force to each of the 4 propeller locations. And by als...
by coppelia
02 Dec 2021, 10:34
Forum: General questions
Topic: Smooth Path Following
Replies: 1
Views: 93

Re: Smooth Path Following

Hello Mattia, have a look at the demo scene scenes/trajectoryAndMotion/pathToTrajectory.ttt . The idea is to see your path as a one-dimensional task, which is to follow it from its start, until you arrived at its length L. Then you can use sim.moveToConfig Make sure you also have a look at the other...
by coppelia
02 Dec 2021, 10:30
Forum: General questions
Topic: use 'sim.moveToPose' to control two object move with different position
Replies: 3
Views: 1198

Re: use 'sim.moveToPose' to control two object move with different position

You can't call another coroutine/thread from a coroutine/thread. You'll have to work by organizing your coroutines as workers, that can be triggered/activated with specific variables for instance: function coroutineMain() while true do if commandPending then -- handle pending command commandPending=...
by coppelia
30 Nov 2021, 05:49
Forum: General questions
Topic: Error: [string -unknown location]:?: Call failed.
Replies: 1
Views: 430

Re: Error: [string -unknown location]:?: Call failed.

Hello, make sure that the script you are calling is initialized (e.g. if simulation is not running, child scripts are not initialized), and that the function exists. Additionally, as for your other post, I highly recommend you to use the ZeroMQ-based remote API : it will make everything much easier....
by coppelia
30 Nov 2021, 05:44
Forum: General questions
Topic: About simxGetModelProperty and simxSetModelProperty
Replies: 1
Views: 374

Re: About simxGetModelProperty and simxSetModelProperty

Hello, normally, sim.getModelProperty will return 0 when no property is overridden. The returned value is bit-coded. In your case, you won't get anything usable, since you are not using the appropriate operation mode (use simx_opmode_blocking to fetch values remotely). Finally, if you are running Py...
by coppelia
30 Nov 2021, 05:39
Forum: General questions
Topic: How to optimize the control of manipulator
Replies: 3
Views: 444

Re: How to optimize the control of manipulator

Hello, I am not sure I understand the question. Of course, in CoppeliaSim you can control/access models/objects/joints from several scripts at the same time, which will result in undefined behaviour. It is your responsibility to orchestrate everything. Additionally, it seems you are using an old Cop...
by coppelia
30 Nov 2021, 05:33
Forum: General questions
Topic: Inserting a path using x y coordinates
Replies: 3
Views: 614

Re: Inserting a path using x y coordinates

Hello,

here a simple example, creating a path with 4 control points located at (0,0,0),(1,0,0),(1,1,0),(0,1,0):

Code: Select all

    local ctrlPts={0,0,0,0,0,0,1,
                    1,0,0,0,0,0,1,
                    1,1,0,0,0,0,1,
                    0,1,0,0,0,0,1}
    sim.createPath(ctrlPts,0,100,0)
Cheers
by coppelia
30 Nov 2021, 05:26
Forum: General questions
Topic: use 'sim.moveToPose' to control two object move with different position
Replies: 3
Views: 1198

Re: use 'sim.moveToPose' to control two object move with different position

Hello, you have at least 3 possibilities: use a threaded child script for each object to move write an alternative function similar to sim.moveToPose: that function merely uses sim.rmlPos, sim.rmlStep and sim.rmlRemove, and you can then write movement functions for n DoFs, or for n objects However t...