Function Description

The READ_U_PCMCIA function transfers data from the user memory card archiving zone to the PLC RAM memory. The function READ_U_PCMCIA allowss addressing the PLC zone’s beginning to be copied to the PCMCIA card up to 65 535 (instead of 32 767 for READ_PCMCIA function) and is therefore recommended to be used instead of READ_PCMCIA function.

The additional parameters EN and ENO can be configured.

An example using the function READ_U_PCMCIA is available, WRITE_U_PCMCIA and READ_U_PCMCIA Example.

Representation in FBD

Representation:

Representation in LD

Representation:

Representation in IL

Representation:

LD Slot_Number
READ_U_PCMCIA Source_Address, Words_Number, Dest_Address, Read_State

Representation in ST

Representation:

READ_U_PCMCIA(Slot_Number, Source_Address, Words_Number, Dest_Address, Read_State);

Description of the Parameters

This table describes the input parameters:

Parameter

Type

Comment

Slot_Number

INT

PCMCIA card slot:

  • 0 = upper slot,

  • 1 = lower slot

Source_Address

DINT

First address where the data is read from the memory card (0...).

Words_Number

INT

Number of words to be read.

Dest_Address

UINT

First address where the data is written in the PLC (%MW). The upper limit of the address is: 65 535.

This table describes the output parameters:

Parameter

Type

Comment

Read_State

INT

Code providing the result of the read command execution:

  • 16#0000: read performed correctly

  • 16#0102: Dest_Address + Words_Number -1 is greater than the maximum number of declared words in the PLC.

  • 16#0104: no valid application or no word in the PLC

  • 16#0201: no file zone in the memory card

  • 16#0202: memory card error

  • 16#0204: memory card write-protected

  • 16#0241: Source_Address < 0,

  • 16#0242: Dest_Address + Words_Number-1 is greater than the highest address of the memory car,.

  • 16#0401: Words_Number ≤ 0

  • 16#0402: Slot_Number is different from 0 and 1

  • 16#0501: Words_Number = unsupported service