GetDateAndTime (FB) ¶ FUNCTION_BLOCK GetDateAndTime This function block reads the realtime clock. It returns the time of the local time zone (i.e. a possible switch to summer/standard time will be regarded). The current time zone switch can be defined by SetTimeZoneInformation . If a switch to summer/standard time has become necessary since the last polling of the time, this is done automatically. At the start of the module the outputs dtDateAndTime and ePeriode are reset. ( DT#1970-01-01-00:00 and RTCLK_UNKNOWN ). After successful operation they will contain the current local time. InOut: Scope Name Type Comment Input xExecute BOOL Rising edge: Action start Falling edge: Resets outputs. If a falling edge occurs before the function block has completed its action, the outputs operate in the usual manner and are only reset if either the action is completed or in the event of an error. In this case, the corresponding output values (xDone, xError, iError) are present at the outputs for exactly one cycle. Output xDone BOOL Action successfully completed xBusy BOOL Function block active xError BOOL TRUE : error occurred, function block aborts action FALSE : no error eError ERROR Error description for diagnosis dtDateAndTime DT ePeriode RTCLK.PERIODE Current local time
SetDateAndTime (FB) ¶ FUNCTION_BLOCK SetDateAndTime This function block sets the realtime clock. The current local time is passed in the parameter dtDateAndTime . Note If the time is within the not-unique interval shortly after the switch to standard (winter) time, standard time will be assumed. This case occurs for example in the Central European countries, if on the last Sunday of October the time is set at 2:30 a.m.. Here it is not clear, whether 2:30 a.m. is still summer time or already standard (winter) time. In this case the module assumes standard (winter) time. InOut: Scope Name Type Comment Input xExecute BOOL Rising edge: Action start Falling edge: Resets outputs. If a falling edge occurs before the function block has completed its action, the outputs operate in the usual manner and are only reset if either the action is completed or in the event of an error. In this case, the corresponding output values (xDone, xError, iError) are present at the outputs for exactly one cycle. dtDateAndTime DT Output xDone BOOL Action successfully completed xBusy BOOL Function block active xError BOOL TRUE : error occurred, function block aborts action FALSE : no error eError ERROR Error description for diagnosis
Functions ¶ Utility Functions DTConcat (Function) DTSplit (Function) DateConcat (Function) DateSplit (Function) GetDayOfWeek (Function) TODConcat (Function) TODSplit (Function)
Utility Functions ¶ DTConcat (Function) DTSplit (Function) DateConcat (Function) DateSplit (Function) GetDayOfWeek (Function) TODConcat (Function) TODSplit (Function)
DTConcat (FUN) ¶ FUNCTION DTConcat : DATE_AND_TIME The function converts year, month, hour, minute and second to the IEC 6-1131-3 format DATE_AND_TIME . In case of invalid inputs DT#1970-01-01-00:00 will be returned. InOut: Scope Name Type Comment Return DTConcat DT Input uiYear UINT 1970 .. 2099 uiMonth UINT 1 .. 12 uiDay UINT 1 .. 31 uiHour UINT 0 .. 23 uiMinute UINT 0 .. 59 uiSecond UINT 0 .. 59 peError POINTER TO ERROR
CAADiagTreeBase (FB) ¶ FUNCTION_BLOCK CAADiagTreeBase IMPLEMENTS INode Default implementation of INode interface for CAADiagDeviceDefault function block Properties: ChildNodeCount Enable FirstChildNode IsRootNode NextSiblingNode ParentNode SiblingNodeCount Structure: INode ChildNodeCount (Property) Enable (Property) FirstChildNode (Property) IsRootNode (Property) NextSiblingNode (Property) ParentNode (Property) SiblingNodeCount (Property)
CAAReconfigureBase (FB) ¶ FUNCTION_BLOCK CAAReconfigureBase IMPLEMENTS IReconfigureProvider This function block provides a base implementation for IReconfigureProvider . It is important to call CAAReconfigureBase.Initialize_Diag once before using this function block. I/O driver nodes just delegate all IReconfigureProvider methods and properties to this function block. There is no additional code necessary. For other nodes a specific implementation is necessary. For this CAAReconfigureBase.BeginReconfigure , CAAReconfigureBase.ReconfigureChildrenAsync and CAAReconfigureBase.EndReconfigure can be used. Properties: ReconfigureActive SiblingIRP Methods: BeginReconfigure EndReconfigure Initialize_Diag ReconfigureAsync ReconfigureChildrenAsync ReconfigureIoDriverAsync RegisterIRPChild Structure: BeginReconfigure (Method) EndReconfigure (Method) IReconfigureProvider ReconfigureActive (Property) ReconfigureAsync (Method) RegisterIRPChild (Method) SiblingIRP (Property) Initialize_Diag (Method) Reconfigure-Implementations ReconfigureChildrenAsync (Method) ReconfigureIoDriverAsync (Method)
Structs ¶ BUS_INFO (Struct) DEVICE_INFO (Struct) ERROR_INFO (Struct) LOG_ENTRY (Struct) QOS_INFO (Struct)
BUS_INFO (STRUCT) ¶ TYPE BUS_INFO : STRUCT This structure provides basic information on a fieldbus: eType : Type of fieldbus. See BUS_TYPE . idSystem : Unique system ID for the identification of the fieldbus. Bus Type Interpretation CANbus Network ID Profibus DP MasterID (see also Master-FB Property) DeviceNet Network ID EtherCAT low DWORD of the MAC address of the master Sercos III CAA.gc_idMAX_IDENT Profinet IO MasterID (see also Controller-FB Property) Modbus TCP CAA.gc_idMAX_IDENT Modbus RTU CAA.gc_idMAX_IDENT EtherNet/IP IP address AS Interface CAA.gc_idMAX_IDENT Ethernet IP address Serial Line number of COM port idInstance : Instance number in I/O configuration (starting by 0). Example First CANbus has instance number 0, second CANbus instance number 1, … Attributes: qualified_only InOut: Name Type Comment eType BUS_TYPE Unique ID of the fieldbus type (e.g. CANopen, ProfiBus) idSystem CAA.IDENT Unique system ID for the identification of the fieldbus. The interpretation of this value is fieldbus dependent (e.g. NetID for CANBus). If the value gc_idMAX_IDENT is returned the system ID could not be determined. idInstance CAA.IDENT Instance number in I/O configuration.
DEVICE_INFO (STRUCT) ¶ TYPE DEVICE_INFO : STRUCT This structure provides the basic information on a device. eType : Type of device. See DEVICE_TYPE . idSystem : Unique address within the bus system. Device Type Interpretation CANopen Node ID J1939 Manager CAA.gc_idMAX_IDENT J1939 ECU Preferred Address Profibus MasterID (see also Master-FB Property) DeviceNet MAC ID EtherCAT Master Last 4 Bytes of the Mac address EtherCAT Slave Physical address of slave Sercos III Master CAA.gc_idMAX_IDENT Sercos III Slave active Sercos address Profinet MasterID (see also Controller-FB Property) Modbus TCP CAA.gc_idMAX_IDENT Modbus RTU Master CAA.gc_idMAX_IDENT Modbus RTU Slave slave address EtherNet/IP IP address ASI Master CAA.gc_idMAX_IDENT ASI Slave ASI address I/O Modules CAA.gc_idMAX_IDENT Safety Device CAA.gc_idMAX_IDENT SoftMotion Device CAA.gc_idMAX_IDENT SoftVision Device CAA.gc_idMAX_IDENT PLC CAA.gc_idMAX_IDENT Safety PLC CAA.gc_idMAX_IDENT Drive CAA.gc_idMAX_IDENT Parameterizable device CAA.gc_idMAX_IDENT HMI CAA.gc_idMAX_IDENT SoftMotion PLC CAA.gc_idMAX_IDENT idInstance : Instance number in I/O configuration (starting by 0). Example First EtherNet/IP Scanner has instance number 0, second EtherNet/IP Scanner instance number 1, … Attributes: qualified_only InOut: Name Type Comment eType DEVICE_TYPE Unique ID of the device type (e.g. CANopen, ProfiBus) idSystem CAA.IDENT Unique address within the bus system. The interpretation of this value is fieldbus dependent (e.g. NodeID for CANopen). idInstance CAA.IDENT Instance number in I/O configuration.