CodeMEncrypt (FUN)

FUNCTION CodeMEncrypt : RTS_IEC_RESULT

Encrypt data

InOut:

Scope

Name

Type

Comment

Return

CodeMEncrypt

RTS_IEC_RESULT

Error code (see CmpErrors2 Interfaces Library) or ERR_OK if succeeded

Input

hCodeMeter

RTS_IEC_HANDLE

Handle to the CodeMeter license container retrieved by CodeMOpen().

udiEncryptionCode

UDINT

Encryption code

pbyData

POINTER TO BYTE

Pointer to plain text data to encrypt

nDataLen

__XWORD

Length of data to encrypt

Inout

ulCRC

UDINT

Returns CRC of the encrypted data