SncDeviceDriverBase.SyncdWriterSize (PROP) ¶ PROPERTY SyncdWriterSize : UDINT Property of type ‘UDINT’ to save the size of the writer which is set by the standard RTS. This size is used to synchronize with the F-SPS because there is no writer’s inteface yet to get the size
SncDeviceDriverBase.TransmitDeviceSpecificData (METH) ¶ METHOD TransmitDeviceSpecificData : ERROR Method to transmit the content of a SNC service request to a specific F-SPS and to transform its reply as a SNC service reply InOut: Scope Name Type Comment Input eFSpsBusId FSPSBUSDRV F-SPS field bus ID szSafetySvcDevAddr STRING device address to which the service should be directed pbySafetySvcData POINTER TO BYTE pointer to the specific safety service data udiSafetySvcDataSize UDINT size of this data hWriter RTS_IEC_HANDLE writer for the reply; udiStdSpsBufferSize UDINT size of the communication buffer of the standard SPS Return TransmitDeviceSpecificData ERROR
SncDeviceDriverBase.WasInitialized (PROP) ¶ PROPERTY WasInitialized : BOOL Property of type ‘BOOL’ to get / set if the service provider has been already Initialized
SncDeviceDriverBase.WriteScanReply (METH) ¶ METHOD PROTECTED WriteScanReply : ERROR Method to write the reply of the field bus specific scan result InOut: Scope Name Type Comment Input hWriter RTS_IEC_HANDLE writer for the reply bAlive BOOL flag if F-SPS is still alive eError ERROR SNC ERROR Return WriteScanReply ERROR
DEVDRV_ETC (GVL) ¶ Global constants for the EtherCAT device driver for reading config parameters from the device description Attributes: qualified_only InOut: Scope Name Type Initial Comment Constant VoE_COMMBUFFERSIZE_ID UDINT 16#88000000 size of the comm buffer of the EtherCAT mailbox VoE_TIMEOUT_ID UDINT 16#88000001 timeout of the EtherCAT mailbox BLOCK_TIMEOUT_MULTIPLIER_ID UDINT 16#88000002 multiplier to get a block timeout on base of the above timeout MSG_TIMEOUT_ID UDINT 16#88000003 message timeout for a complete reply
SncEtherCATDriver (FB) ¶ FUNCTION_BLOCK FINAL SncEtherCATDriver EXTENDS SncDeviceDriverBase IMPLEMENTS IBusSpecificDataHandler Function block for an EtherCAT device driver to handle the SNC services addressed to its connected F-SPS extends ‘SncDeviceDriverBase’ and implements the interface ‘IDeviceSpecificDataHandler’ represents one connected EtherCAT F-SPS and registers it to the SncServiceProvider scans for this specific F-SPS and synchronizes its communication buffer size with the one from the Std-SPS handles the service requests coming from the SNC service handler with the help of the EtherCAT bus handler Properties: BlockTimeoutMs BlockTimeoutMultiplier CommBufferSize CommTimeout FSpsBusID MsgTimeoutMs ScanTimeoutMs FSpsDeviceAddress , inherited from SncDeviceDriverBase SyncdWriterSize , inherited from SncDeviceDriverBase WasInitialized , inherited from SncDeviceDriverBase Methods: InitDeviceSpecificFSps ScanDeviceSpecificFSps InitOnDownload , inherited from SncDeviceDriverBase Initialize , inherited from SncDeviceDriverBase TransmitDeviceSpecificData , inherited from SncDeviceDriverBase WriteScanReply , inherited from SncDeviceDriverBase Structure: BlockTimeoutMs (Property) BlockTimeoutMultiplier (Property) CommBufferSize (Property) CommTimeout (Property) FSpsBusID (Property) InitDeviceSpecificFSps (Method) MsgTimeoutMs (Property) ScanDeviceSpecificFSps (Method) ScanTimeoutMs (Property)
SncEtherCATDriver.BlockTimeoutMs (PROP) ¶ PROPERTY BlockTimeoutMs : UDINT Property of type ‘UDINT’ to get the block timeout in ms of the underlying block driver The block timeout is used while sending a data block
SncEtherCATDriver.BlockTimeoutMultiplier (PROP) ¶ PROPERTY BlockTimeoutMultiplier : UDINT Property of type ‘UDINT’ to get the multiplier for the block timeout on base of the comm timeout
ERROR (ENUM) ¶ TYPE ERROR : Enumeration for the various error types in the subnode communication manager (SNCM): Attributes: qualified_only InOut: Name Initial Comment ERR_OK 0 The action was successful. ERR_FAILED 1 The action failed due to a non specific reason. ERR_ADDRESS_INVALID 2 The given F-SPS bus address or F-SPS device address is not valid. ERR_SERVICEPROVIDER_NOTINITIALIZED 3 The SNC service provider was not fully initialized yet. ERR_SERVICEPROVIDER_START 4 The SNC service handler could not be registered at the RTS service handler and therefore not started. ERR_DRIVER_INVALID 5 The given F-SPS bus driver could not be registered in the SNC service provider because of an invalid driver handle. ERR_DRIVER_ALREADYREGISTERED 6 The given F-SPS bus driver is already registered in the SNC service provider. ERR_DRIVER_MISMATCH 7 The given service is forwarded to the wrong F-SPS bus driver. ERR_BUSHANDLER_NOTINITIALIZED 8 The underlying bus handler was not fully initialized yet. ERR_READER_FAILED 9 Error while reading the service ERR_WRITER_FAILED 10 Error while writing the reply ERR_COMM_NOTOPEN 11 The communication channel to the F-SPS could not be opened. ERR_FSPS_SVC2BIG 12 The transferred safety service is larger than the F-SPS message buffer ERR_FSPS_SEND 13 Common error during sending the safety service data ERR_FSPS_SENDTIMEOUT 14 Timeout during sending the safety service data (block timeout) ERR_FSPS_SENDANDREOPEN 15 The sending of the safety service data is pending and the reopen of the channel failed ERR_FSPS_REPLY 16 Common error while receiving the safety service reply ERR_FSPS_REPLYTIMEOUT 17 Timeout during reply (block timeout and message timeout) ERR_FSPS_STATE 18 Undefined state in the communication loop of the bus handler ERR_FSPS_PENDING 19 The F-SPS is busy and couldn’t handle the service reply in time (access to flash, …) ERR_SCAN_FAILED 20 Common error in scan ERR_SCAN_TIMEOUT 21 Timeout during scan
FSPSBUSDRV (ENUM) ¶ TYPE FSPSBUSDRV : Enumeration for the various F-SPS bus driver types in the subnode communication manager: Attributes: qualified_only InOut: Name Initial Comment ETHERCAT 16#1 Bus driver is of type ‘ETHERCAT’ SINGLE_SHM 16#2 Bus driver is of type ‘Single FSps’ on base of a shared memory communication