I succeeded in running the Ethernet KRL example, to transmit the current position of the tool to a computer. The src file:
Code
DECL EKI_STATUS RET
RET=EKI_Init("XmlTransmit")
RET=EKI_Open("XmlTransmit")
EKI_CHECK(RET,#QUIT)
RET=EKI_SetFrame("XmlTransmit","Robot/Data/LastPos", $POS_ACT)
WAIT SEC 1
RET=EKI_Close("XmlTransmit")
RET=EKI_Clear("XmlTransmit")
What I don’t understand is that the program always stops at the line “WAIT SEC 1” after transmitting the data, no matter whether on T1 or AUT mode. In order to transmit the data continuously, I add a WHILE loop:
However, the program still stops at the line “WAIT SEC 1” after transmitting the data once. I read that “If an EKI instructionis to be executed in the main run,instructions must be used which trigger an advance run stop, e.g. WAIT SEC.” . But I have no idea how to make the robot transmit data continuesly. Any suggestion? Thanks!