To register the current robot position to the Vision Sensor, use "FHSMPLREGP". Send the measurement command to the Vision Sensor and receives a response to that command. 32 6.4. Register the Current Robot Position in the Vision Sensor Before executing measurements, execute the current position registration command execution sample function (FHSMPLREGP) to the Vision Sensor. 106: !;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; 107: ! (3) Register the current ; 108: ! position of the robot to ; 109: ! the FH before measurement ; 110: !;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; Current position registration 111: ; command execution sample 112: CALL FHSMPLREGP(R[198],R[199]) ; function 113:
IF R[200] 0,JMP LBL[998] ; 1 6.5. Executing Measurements on Vision Sensor To send the measurement command to the Vision Sensor, set the command name to "MEASURE" and execute "FHRUNSNDCMD". 116: !;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; 117: ! (4) Execute measurement and get ; 118: ! the measurement results of ; 119: ! the FH ; 120: !;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ; nonprocedural command transmission function 121: ; 122: CALL FHRUNSNDCMD(0,'MEASURE','...','...','...','...','...') ; 123: IF R[200] 0,JMP LBL[998] ; 1 To receive the response to the measurement command from the Vision Sensor, execute "FHRUNRCVRES". 125: CALL FHRUNRCVRES(R[198],R[199],194) ; 126:
IF R[200] 0,JMP LBL[998] ; command response receiving function 127: ; 128: IF R[194] 1,JMP LBL[998] ; If the response is not OK, exit the program. 2