Cyclic communication stop request
This FP instruction stops the node on which the stop request is made and writes the result into the output variable d_Result. The node number table is specified by FP_ETHERNETIP_STATE_TABLE_DUT.
Input
Node number table for stop requests
Memory area address storing the maximum node number (1-256) or a constant.
Output
Destination to which the data is written
0: Specified node stop is completed
1: Specified node stop processing is in progress.
2: Specified node stop failed
3: Multiple starts of FP_ETHERNETIP_STOP
if the read area is outside the permissible range
if the instruction is executed in an interrupt program
if the read area is outside the permissible range
if the instruction is executed in an interrupt program
All input and output variables used for programming this function have been declared in the POU header. The same POU header is used for all programming languages.
VAR
bEnable: BOOL:=FALSE;
wResult: WORD:=0;
dutNodes_NodeTableStop: FP_ETHERNETIP_STATE_TABLE_DUT;
END_VAR
When the variables sys_bIsEtherNetIPStartStopControllable and bEnable are set to TRUE, the function is carried out.
BODY
WORKSPACE
NETWORK_LIST_TYPE := NWTYPELD ;
ACTIVE_NETWORK := 0 ;
END_WORKSPACE
NET_WORK
NETWORK_TYPE := NWTYPELD ;
NETWORK_LABEL := ;
NETWORK_TITLE := ;
NETWORK_HEIGHT := 8 ;
NETWORK_BODY
B(B_VARIN,,dutNodes_NodeTableStop,14,5,16,7,);
B(B_VAROUT,,wResult,28,5,30,7,);
B(B_CONTACT,,bEnable,12,4,14,6,);
B(B_CONTACT,,sys_bIsEtherNetIPStartStopControllable,8,1,10,3,);
B(B_F,FP_ETHERNETIP_STOP!,,16,3,28,7,,?DEN?Dd_dutStateTable?AENO?Cd_Result);
L(1,2,8,2);
L(10,2,10,5);
L(10,5,12,5);
L(14,5,16,5);
L(1,0,1,8);
END_NETWORK_BODY
END_NET_WORK
END_BODY
IF (sys_bIsEtherNetIPStartStopControllable) AND (bEnable) then
FP_ETHERNETIP_STOP(d_dutStateTable := dutNodes_NodeTableStart,
d_Result => wResult)
END_IF;