Raycasting in Robodk可打印版本 +- RoboDK Forum (//m.sinclairbody.com/forum) +-- Forum: RoboDK (EN) (//m.sinclairbody.com/forum/Forum-RoboDK-EN) +--- Forum: RoboDK API (//m.sinclairbody.com/forum/Forum-RoboDK-API) +--- Thread: Raycasting in Robodk (/Thread-Raycasting-in-Robodk) |
Raycasting in Robodk-mjavala-02-17-2021 I am creating a simulation where I need to trigger a stop function on my running simulation if there is movement in a certain area. I was thinking of ray casting for this, but I haven't been able to find any info on this. I also tried using the laser to no avail. Is this not a feature in RoboDK? If so, is there any way I can possibly achieve this? Thanks 再保险:Raycasting Robodk-Albert-02-17-2021 You should be able to call Stop on a robot or a program to stop them: //m.sinclairbody.com/doc/en/PythonAPI/robolink.html#robolink.Item.Stop 再保险:Raycasting Robodk-Jeremy-02-17-2021 Hi Mjavala, I think what you are trying to do is simulate a light/laser curtain. What Albert gave you is a way to stop the program once the laser curtain is triggered. To create the laser curtain itself, I think I would use this API call://m.sinclairbody.com/doc/en/PythonAPI/robolink.html#robolink.Robolink.Collision_Line It will let you define a line (or many lines) and trigger a collision as soon a something cross that invisible line. Let me know if it helps. Jeremy |