Function description

The READ_V_PCMCIA function transfers variables from the user memory card to the PLC’s RAM.

The additional parameters EN and ENO can be configured.

Representation in FBD

Representation:

1

Slot number

2

Memory card address

3

Number of BYTEs to be read

4

Destination variable address

5

Read status

Representation in LD

Representation:

1

Slot number

2

Memory card address

3

Number of BYTEs to be read

4

Destination variable address

5

Read status

Representation in IL

Representation:

LD SLOT
READ_V_PCMCIA SRC, NUM

Representation in ST

Representation:

READ_V_PCMCIA(SLOT, SRC, NUM);

Description of the parameters

The following table describes the READ_V_PCMCIA Input parameters:

Parameter

Type

Comment

SLOT

INT

PCMCIA card slot:

  • 0 = upper slot,

  • 1 = lower slot

SRC

DINT

Source address where the variable is read from the memory card (0...).

NUM

UDINT

Number of BYTEs to be read. Use the SIZEOF function to find this number.

The following table describes the READ_V_PCMCIA Output parameters:

Parameter

Type

Comment

RCPT

ANY

Destination address of every located or unlocated variable (DDT).

CR

INT

Code providing the result of the read command's execution:

  • 0000 hex: read performed correctly

  • 0201 hex: no file zone in the memory card

  • 0202 hex: detected memory card error

  • 0204 hex: memory card write-protected

  • 0241 hex: SRC < 0

  • 0280 hex: NUM input value not consistent with the RCT output or not consistent with the PCMCIA memory structure

  • 0401 hex: NUM = 0

  • 0402 hex: SLOT is different from 0 and 1

  • 0501 hex: NUM = unsupported service