Based on TCP/IP protocol, cs model could communicate with external devices via port 30001, and the refresh frequencey for data transation is 10Hz, which means cs model sends robot status to external devices every 100ms, like real time postion, IO status.
Also only if cs model is in remote mode, external controller could send script to robot system to control the movement.
So first users should switch the robot to remote mode:
Confirm the IP address of FB1 (for virtual environment, just check the ip address of virtual machine)
Open the socket test software, and send the function as below (start with def, and finish with end, adding enter to switch next line):
def a():
movej([-3.14,-1.57,-1.57,-1.57,1.57,0],a=1.4,v=0.5,t=0,r=0)
movej([-1.57,-1.57,-1.57,-1.57,1.57,0],a=1.4,v=0.5,t=0,r=0)
end
If there is subprogram inside, you can also send commands as below:
def test(): # Must start with "def", and end with "end\n"
# The normal python format inside
def mov():
movej([0.57636,-1.01469,-2.04816,-1.29723,1.5708,-0],a=1.4,v=1.05,t=0,r=0)
a = "hello cs"
if a == "hello cs":
mov()