HaModDiag (FB)

FUNCTION_BLOCK HaModDiag EXTENDS AbbLConCA

Function block HaModDiag is intended to be used for Diagnosis. HaModDiag function block provides the diagnosis information other than the configuration and runtime errors displayed in the HaModControl function block. Using this function block, user will be able to get the diagnosis information such as Primary status, active and configured CI Modules, CI communication status, sync instances and number of sync bytes configured.

Note

This function block must be connected to HaModControl function block instance called for the system using ADR operator to populate the diagnosis information.

InOut:

Scope

Name

Type

Initial

Comment

Inherited from

Input

Enable

BOOL

FALSE

A rising edge (Enable = TRUE) starts the operation, the output Busy goes to TRUE. All other inputs are read and considered continuously. A falling edge (Enable = FALSE) aborts the operation. During Aborting the Busy is still TRUE. Afterward all outputs are reset.

AbbLConCA

Output

Busy

BOOL

FALSE

Operation is running (while output Error is FALSE)

AbbLConCA

Error

BOOL

FALSE

Operation is stopped with error (while output Busy is FALSE). This output is TRUE for at least one cycle or until Enable is set to FALSE. The output ErrorID gives more details about the error.

AbbLConCA

Input

dwHaP

POINTER TO HaModControl

2 : Pointer to HaModControl Instance

Output

CpuAPrimary

BOOL

FALSE

3: CPU A Primary Status

CpuBPrimary

BOOL

FALSE

4: CPU B Primary Status

CpuARun

BOOL

FALSE

5: CPU A RUN Status

CpuBRun

BOOL

FALSE

6: CPU B RUN Status

CpuACi52xBusActive

BOOL

FALSE

7: ModbusTcp CI52x- Bus active on CPU A

CpuBCi52xBusActive

BOOL

FALSE

8: ModbusTcp CI52x- Bus active on CPU B

CpuACi52xCfg

BYTE

0

9: Number of CI52x configured on CPU A

CpuBCi52xCfg

BYTE

0

10: Number of CI52x configured on CPU B

CpuACi52xAct

BYTE

0

11: Number of CI52x Active on CPU A

CpuBCi52xAct

BYTE

0

12: Number of CI2x Active on CPU B

SyncInstances

UINT

0

13: Number of data sync and utility blocks initialised in project

SyncDataCheckSum

UINT

0

14: Check sum of all address pointer blocks in bytes

stHACpuStatus

HaModStatusPlc

15: HA Own Cpu status. It will show the status details of logged in Cpu

stHAotherCpuStatus

HaModStatusLifecom2

16: HA other Cpu status. It will show the status details of other Cpu