Function description

The WRITE_V_PCMCIA function transfers variables from the PLC RAM memory to a given location in the user memory card.

Representation in FBD

The representation in FBD of the WRITE_V_PCMCIA function is as follows:

1

Slot number

2

Memory card address

3

Number of BYTEs to be write

4

Source variable address

5

Write status

Representation in LD

The additional parameters EN and ENO can be configured.

The representation in LD of the WRITE_V_PCMCIA function is as follows:

1

Slot number

2

Memory card address

3

Number of BYTEs to be write

4

Source variable address

5

Write status

Representation in IL

The representation in IL of the WRITE_V_PCMCIA function is as follows:

LD SLOT
WRITE_V_PCMCIA SLOT, DEST, NUM, EMIS, CR

Representation in ST

The representation in ST of the WRITE_V_PCMCIA function is as follows:

WRITE_V_PCMCIA(SLOT, DEST, NUM, EMIS, CR);

Description of the parameters

The following table describes the Input parameters:

Parameter

Type

Comment

SLOT

INT

PCMCIA card slot:

  • 0 = upper slot,

  • 1 = lower slot

DEST

DINT

First address where the variable is written in the memory card.

NUM

UDINT

Number of BYTEs to write.

EMIS

ANY

First address of the variable in the PLC.

The following table describes the Output parameters:

Parameter

Type

Comment

CR

INT

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

  • 0000 hex: write performed correctly

  • 0201 hex: no file zone in the memory card

  • 0202 hex: memory card error

  • 0204 hex: memory card write-protected

  • 0241 hex: DEST < 0

  • 0401 hex: NUM = 0

  • 0402 hex: SLOT is different from 0 and 1

  • 0501 hex: unsupported service