Inscription on the object
Inscription on the object
Hello. I would like to create a simple program in which a robotic arm will
write some inscription on an object. It can even be straight line and circle. Could you please tell me how to do it
in the simplest way? I have free version program Coppelia. This free version is called "player"
Thanks
write some inscription on an object. It can even be straight line and circle. Could you please tell me how to do it
in the simplest way? I have free version program Coppelia. This free version is called "player"
Thanks
Re: Inscription on the object
Hello,
you will need the EDU version at least. Then you can use the pen model for instance: Models/components/modifiers/felt pen.ttm
If the tip of the pen touches a surface during simulation, it will draw a point/line a that location.
Cheers
you will need the EDU version at least. Then you can use the pen model for instance: Models/components/modifiers/felt pen.ttm
If the tip of the pen touches a surface during simulation, it will draw a point/line a that location.
Cheers
Re: Inscription on the object
Hello
I attach feltPen on the robot. Can you explain to me what should I do to make my robot move? Do you have scripting instructions? I add photo what I have this right now.
Photo:
https://iv.pl/image/GZGGtTS
I'd like write something on this cuboid. Could you help me?
I attach feltPen on the robot. Can you explain to me what should I do to make my robot move? Do you have scripting instructions? I add photo what I have this right now.
Photo:
https://iv.pl/image/GZGGtTS
I'd like write something on this cuboid. Could you help me?
Re: Inscription on the object
Hi,
the pen should be child of the 'connection' object.
To make the robot move you would move the IK target (the 'target' object, or the green sphere that contains it) e.g. via sim.setObjectPosition
the pen should be child of the 'connection' object.
To make the robot move you would move the IK target (the 'target' object, or the green sphere that contains it) e.g. via sim.setObjectPosition
Re: Inscription on the object
I did it. Is it correct now? Can you tell me where I should write code? Where I marked green or blue?
https://iv.pl/image/GZGOSad
https://iv.pl/image/GZGOSad
Re: Inscription on the object
You can achieve a linear motion of the target from
you can put the code in an embedded script of any object, adjusting for how the target object is retrieved (
poseA
to poseB
with:Code: Select all
function sysCall_init()
...
target=sim.getObject('/IRB140/target')
maxVel=0.1
maxAccel=0.05
maxJerk=0.01
-- call sim.moveToPose() in a coroutine to be resumed periodically:
corout=coroutine.create(function()
local function moveTarget(currentPose,currentVel,currentAccel)
sim.setObjectPose(target,-1,currentPose)
end
sim.moveToPose(-1,poseA,{maxVel},{maxAccel},{maxJerk},poseB,moveTarget,nil,{1,1,1,1})
end
end
function sysCall_actuation()
if coroutine.status(corout)~='dead' then
local ok,errorMsg=coroutine.resume(corout)
if errorMsg then
error(debug.traceback(corout,errorMsg),2)
end
end
...
end
target=sim.getObject(...)
); the absolute path I used works from anywhere, but for instance if the script is attached to the 'target' object itself, the you could just say target=sim.getObject('.')
Re: Inscription on the object
If I did something like this, what do I need to do to make the pen move with the robot? How to connect the pen with the robot?
https://ibb.co/q5NvF6x
https://ibb.co/q5NvF6x
Re: Inscription on the object
You can attach/detach the pen to/from another object via sim.setObjectParent
Cheers
Cheers
Re: Inscription on the object
Hi
I don't have the "Segment Path" function in my program. In the "Path" tab, I only have "Open" and "Closed". My program version is 4.4.0. When I open a ready-made program and want to modify "Path", I have something like the attached image. How can I fix it?
https://ibb.co/Qj8MW0r
I don't have the "Segment Path" function in my program. In the "Path" tab, I only have "Open" and "Closed". My program version is 4.4.0. When I open a ready-made program and want to modify "Path", I have something like the attached image. How can I fix it?
https://ibb.co/Qj8MW0r
Re: Inscription on the object
That is a deprecated path object. From that, you can create an equivalent path object, that is not deprecated (click Create similar object).
If you are opening an old scene, that uses a deprecated path object, then youcan still modify it: select the object, then with ctrl-click, select a path control point, and move it in the same way you would move another object.
Cheers
If you are opening an old scene, that uses a deprecated path object, then youcan still modify it: select the object, then with ctrl-click, select a path control point, and move it in the same way you would move another object.
Cheers