FP_FTP_GET_STATUS_ALL

Get status of all Ethernet units using FTP transmission

This FP instruction gets the information from all Ethernet units nTransferID0nTransferID15 and writes the values into the DUT FP_CLIENT_STATUS_ALL_DUT.

Parameters

Output

dutFPClientStatusAll (FP_CLIENT_STATUS_ALL_DUT)

Stores the values of the Ethernet status of all Ethernet units

Remarks

  • This instruction is not available in interrupt programs.

  • Before you execute the instruction, you need to specify the transfer settings using FP_FTP_SET_MODE or the setting dialog of the FTP client.

  • Before you execute the instruction, you need to specify the transfer settings for data recording files using FP_FTP_SET_MODE_TRANSFER_LOG or the setting dialog of the FTP client.

  • When an error occurs, check the system variable sys_iEthernetConnectionErrorCode for the error code number.

Error flags

sys_bIsOperationErrorHold (turns to TRUE and remains TRUE)
  • if a transfer setting that has not been configured with FP_FTP_SET_MODE or in the setting dialog of the FTP client is specified.

  • if a transfer setting for data recording files that has not been configured with the instruction FP_FTP_SET_MODE_TRANSFER_LOG or the setting dialog of the FTP client is specified.

  • if the instruction is executed in an interrupt program

sys_bIsOperationErrorNonHold (turns to TRUE for one scan)
  • if a transfer setting that has not been configured with FP_FTP_SET_MODE or in the setting dialog of the FTP client is specified.

  • if a transfer setting for data recording files that has not been configured with the instruction FP_FTP_SET_MODE_TRANSFER_LOG or the setting dialog of the FTP client is specified.

  • 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
		dutFPClientStatusAll: FP_CLIENT_STATUS_ALL_DUT;
		bGetStatusAll: BOOL:=FALSE;
	END_VAR

POU body

If bGetStatusAll is set to TRUE, the instruction is carried out. The status values of all Ethernet units are written into the DUT dutFPClientStatusAll.

LD body

BODY
    WORKSPACE
        NETWORK_LIST_TYPE := NWTYPELD ;
        ACTIVE_NETWORK := 0 ;
    END_WORKSPACE
    NET_WORK
        NETWORK_TYPE := NWTYPELD ;
        NETWORK_LABEL :=  ;
        NETWORK_TITLE :=  ;
        NETWORK_HEIGHT := 5 ;
        NETWORK_BODY
B(B_COMMENT,, ^Get status of all FTP Transfer numbers: e.g. ID0..ID15,3,1,26,4,);
L(1,0,1,5);
        END_NETWORK_BODY
    END_NET_WORK
    NET_WORK
        NETWORK_TYPE := NWTYPELD ;
        NETWORK_LABEL :=  ;
        NETWORK_TITLE :=  ;
        NETWORK_HEIGHT := 5 ;
        NETWORK_BODY
B(B_VAROUT,,dutFPClientStatusAll,24,3,26,5,);
B(B_CONTACT,,bGetStatusAll,5,2,7,4,);
B(B_F,FP_FTP_GET_STATUS_ALL!,,11,1,24,5,,?DEN?AENO?CdutFPClientStatusAll);
L(1,3,5,3);
L(7,3,11,3);
L(1,0,1,5);
        END_NETWORK_BODY
    END_NET_WORK
END_BODY

ST body

(* First get status of all FTP Transfer numbers: e.g. ID0..ID15 *)
If (bGetStatusAll) then
    FP_FTP_GET_STATUS_ALL(dutClientStatusAll => dutFPClientStatusAll);
End_if;

Modified on: 2024-03-06Feedback on this pagePanasonic hotline