CD522SsiCnt_PLUS (FB)

FUNCTION_BLOCK CD522SsiCnt_PLUS EXTENDS AbbLConCA

Function block to access all IO-Values for the SSI of CD522. With additional ResetSSI signal input.
If the SSI Encoder has differential signals adjust parameter “Input level FCx” to “differential”.
Also adjust the SSI frequency, SSI resolution in Bit and SSI polling time. This FB is valid to be used with mode 14
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

ChnNum

WORD

0

0 or 1, counter 0 or counter 1 is used

EnCnt

BOOL

FALSE

Enable (TRUE) or disable (FALSE) the counter function of the module

EnTouch

BOOL

FALSE

Enable (TRUE) or disable (FALSE) the touch function of the module

EdgeTouch

BOOL

FALSE

Select (TRUE) positive or (FALSE) negative edge for touch

ResetSsi

BOOL

FALSE

Reset signal for SSI encoder. Sets an output signal on CD522 for SSI encoder reset input. (ChnNum 0: on CD522 output C7 is set / ChnNum 1: on CD522 output C15 is set)

EnGray

BOOL

FALSE

If (TRUE), Actual value will be calculated from gray code to binary code

EnBcd

BOOL

FALSE

If (TRUE), Actual value will be calculated from bcd code to binary code

AdrIn

POINTER TO WORD

0

Address of process image input. See ../Structs/CD522In for more information about structure

AdrOut

POINTER TO WORD

0

Address of process image output. See ../Structs/CD522Out for more information about structure

Output

ErrorID

ERROR_ID

ERROR_ID.NO_ERROR

Error code description

Act

DWORD

0

32 bit actual counter value

CntTouch

DWORD

0

32 bit touch counter value

RdyTouch

BOOL

FALSE

Set (TRUE) when new touch value is available