Socket communication crashing
Hello!
I have a program for 3d bin picking, and i am connected via TCP/IP to an external computer. In the program below i create a socket and connect to it. My question is when i start the program in manual mode from main procedure i can normally connect and it works fine, but if i stop in another procedure and have to move the program pointer to another procedure the communication crashes and i get disconnected from the port. What can i do or is there an explanation to why it happens?
Program:
PROC TcpIpInicializacija()
VAR socketdev ABB_PC_socket;
VAR string IPaddress:="192.168.1.124";
VAR num PortNumber:=20001;
SocketClose ABB_PC_socket;
WaitTime 0.05;
SocketCreate ABB_PC_socket;
SocketConnect ABB_PC_socket,IPaddress,PortNumber,\Time:=WAIT_MAX;
ENDPROC
Comments
-
Hello,You may use an other task to manage this.☑️2024 - RobotStudio® User Group0
Categories
- All Categories
- 5.5K RobotStudio
- 396 UpFeed
- 18 Tutorials
- 13 RobotApps
- 297 PowerPacs
- 405 RobotStudio S4
- 1.8K Developer Tools
- 250 ScreenMaker
- 2.8K Robot Controller
- 316 IRC5
- 61 OmniCore
- 7 RCS (Realistic Controller Simulation)
- 798 RAPID Programming
- AppStudio
- 3 RobotStudio AR Viewer
- 18 Wizard Easy Programming
- 105 Collaborative Robots
- 5 Job listings