FP_ETHERNETIP_STOP

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.

Parameters

Input

d_dutStateTable (FP_ETHERNETIP_STATE_TABLE_DUT)
  • Node number table for stop requests

  • Memory area address storing the maximum node number (1-256) or a constant.

Output

d_Result (WORD)

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

Error flags

sys_bIsOperationErrorHold (turns to TRUE and remains TRUE)
  • if the read area is outside the permissible range

  • if the instruction is executed in an interrupt program

sys_bIsOperationErrorNonHold (turns to TRUE for one scan)
  • if the read area is outside the permissible range

  • if the instruction is executed in an interrupt program

Example

POU header

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

POU body

When the variables sys_bIsEtherNetIPStartStopControllable and bEnable are set to TRUE, the function is carried out.

LD body

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

ST body

IF (sys_bIsEtherNetIPStartStopControllable) AND (bEnable) then
    FP_ETHERNETIP_STOP(d_dutStateTable := dutNodes_NodeTableStart,
                        d_Result => wResult)
END_IF;

Modified on: 2022-03-02Feedback on this pagePanasonic hotline