07-17-2024, 08:24 PM
Hello,
I want to make sure that I understand how the "start thread" option works when adding a Program Call Instruction.
I expect it to start a Python program running in a separate thread and that the thread will keep running forever - or until I have a nice way to stop it. Do the threads get garbage collected when the program ends or do they keep going?
Brief summary, I want a thread that connects to a Ethernet device and maintains a socket connection to it. Then the subsequent program calls can talk with that thread (probably using shared memory). The last program call will tell the thread to disconnect and shut down.
I should add that the program will be run from RoboDK and not exported and sent to a robot controller. Here is an example of how I think it might work...
Thanks for the insight,
Henry
I want to make sure that I understand how the "start thread" option works when adding a Program Call Instruction.
I expect it to start a Python program running in a separate thread and that the thread will keep running forever - or until I have a nice way to stop it. Do the threads get garbage collected when the program ends or do they keep going?
Brief summary, I want a thread that connects to a Ethernet device and maintains a socket connection to it. Then the subsequent program calls can talk with that thread (probably using shared memory). The last program call will tell the thread to disconnect and shut down.
I should add that the program will be run from RoboDK and not exported and sent to a robot controller. Here is an example of how I think it might work...
Thanks for the insight,
Henry