PLC_R: Controller Read-Only System Variables

Library and Namespace

Library name: SE_PLCSystem

Namespace: SEC

Variable Structure

This table describes the parameters of the PLC_R system variable (PLC_R_STRUCT type):

Modbus Address (1)

Variable Name

Type

Comment

60000

i_wVendorID

WORD

Controller Vendor ID.

101A hex = Schneider Electric

60001

i_wProductID

WORD

Controller Reference ID.

NOTE: Vendor ID and Reference ID are the components of the Target ID of the controller displayed in the communication settings view (Target ID = 101A XXXX hex).

Value per controller:

  • TM262L01MESE8T: 101A 0816 HEX

  • TM262L10MESE8T: 101A 0813 HEX

  • TM262L20MESE8T: 101A 0810 HEX

  • TM262M05MESS8T: 101A 0815 HEX

  • TM262M15MESS8T: 101A 0814 HEX

  • TM262M25MESS8T: 101A 0811 HEX

  • TM262M35MESS8T: 101A 0812 HEX

60002

i_dwSerialNumber

DWORD

Controller Serial Number

60004

i_byFirmVersion

ARRAY[0..3] OF BYTE

Controller Firmware Version [aa.bb.cc.dd]:

  • i_byFirmVersion[0] = aa

  • ...

  • i_byFirmVersion[3] = dd

60006

i_byBootVersion

ARRAY[0..3] OF BYTE

Controller Boot Version [aa.bb.cc.dd]:

  • i_byBootVersion[0] = aa

  • ...

  • i_byBootVersion[3] = dd

60008

i_dwHardVersion

DWORD

Controller Hardware Version.

NOTE: Reserved parameter for internal use only. For the Product Version (PV), consult the product label.

60010

i_dwChipVersion

DWORD

Controller Coprocessor Version.

60012

i_wStatus

PLC_R_STATUS

State of the controller.

60013

i_wBootProjectStatus

PLC_R_BOOT_PROJECT_STATUS

Returns information about the boot application stored in non-volatile memory.

60014

i_wLastStopCause

PLC_R_STOP_CAUSE

Cause of the last transition from RUN to another state.

60015

i_wLastApplicationError

PLC_R_APPLICATION_ERROR

Cause of the last controller exception.

60016

i_lwSystemFault_1

LWORD

Bit field FFFF FFFF FFFF FFFF hex indicates no error detected.

A bit at low level (0) means that an error has been detected:

  • bit 0 = Expert I/O error detected

  • bit 1 = I/O bus error detected

  • bit 2 = Ethernet IF1 error detected

  • bit 3 = Ethernet IF2 error detected

  • bit 4 = Serial 1 in overcurrent error detected

  • bit 5 = Serial 2 in overcurrent error detected

  • bit 6 = CAN 1 error detected

  • bit 7 = Reserved

  • bit 8 = Reserved

  • bit 9 = Communication bus error detected

  • bit 10 = SD Card error detected

  • bit 11 = Firewall error detected

  • bit 12 = DHCPS/FDR server error detected

  • bit 13 = OPC UA server error detected

  • bit 14 = Communication bus error detected

  • bit 15 = Communication bus health error detected

  • bit 16 = Ethernet IF2 Ring root error detected

  • bit 17 = Encoder power supply error detected

  • bit 18 = Encoder communication error detected

  • bit 19 = TMSES4 IF1 configuration error detected

  • bit 20 = TMSES4 IF2 configuration error detected

  • bit 21 = TMSES4 IF3 configuration error detected

  • bit 22 = Server address error detected

  • bit 23 = NTP error detected

  • bit 24 = Syslog error detected

60020

i_lwSystemFault_2

LWORD

Bit field FFFF hex indicates no error detected.

If i_wIOStatus1 = PLC_R_IO_SHORTCUT_FAULT, the meaning of i_lwSystemFault_2 is:

  • bit 0 = 0: short-circuit detected in output group 0 (Q0...Q1)

  • bit 1 = 0: short-circuit detected in output group 1 (Q2...Q3)

  • bit 2 = 0: short-circuit detected in output group 2 (Q4...Q7)

  • bit 3 = 0: short-circuit detected in output group 3 (Q8...Q11)

  • bit 4 = 0: short-circuit detected in output group 4 (Q12...Q15)

60024

i_wIOStatus1

PLC_R_IO_STATUS

Embedded Expert I/O status.

60025

i_wIOStatus2

PLC_R_IO_STATUS

TM3 I/O status.

60026

i_wClockBatterystatus

WORD

Status of the battery of the RTC: 100 = Battery fully charged

Not applicable for M262 Logic/Motion Controller.

60028

i_dwAppliSignature1

DWORD

First DWORD of 4 DWORD signature (16 bytes total).

The application signature is generated by the software during build.

60030

i_dwAppliSignature2

DWORD

Second DWORD of 4 DWORD signature (16 bytes total).

The application signature is generated by the software during build.

60032

i_dwAppliSignature3

DWORD

Third DWORD of 4 DWORD signature (16 bytes total).

The application signature is generated by the software during build.

60034

i_dwAppliSignature4

DWORD

Fourth DWORD of 4 DWORD signature (16 bytes total).

The application signature is generated by the software during build.

n/a

i_sVendorName

STRING(31)

Name of the vendor: “Schneider Electric”.

n/a

i_sProductRef

STRING(31)

Reference of the controller.

n/a

i_sNodeName

STRING(99)

Node name on EcoStruxure Machine Expert Network.

n/a

i_dwLastStopTime

DWORD

The time of the last detected STOP in seconds beginning with January 1, 1970 at 00:00 UTC.

n/a

i_dwLastPowerOffDate

DWORD

The date and time of the last detected power off in seconds beginning with January 1, 1970 at 00:00 UTC.

NOTE: Convert this value into date and time by using the function SysTimeRtcConvertUtcToDate. For more information about Time and Date conversion, refer to the Systime Library Guide.

n/a

i_uiEventsCounter

UINT

Number of external events detected on inputs configured for external event detection since the last cold start.

Reset by a Cold Start or by the PLC_W.q_wResetCounterEvent command.

n/a

i_wTerminalPortStatus

PLC_R_TERMINAL_PORT_STATUS

Status of the USB Programming Port (USB Mini-B).

n/a

i_wSdCardStatus

PLC_R_SDCARD_STATUS

Status of the SD card.

n/a

i_wUsrFreeFileHdl

WORD

Number of available File Handles.

A File Handle is the resource allocated by the system when you open a file.

n/a

i_udiUsrFsTotalBytes

UDINT

User FileSystem total memory size (in bytes).

It is the size of the non-volatile memory for the directory "/usr/".

n/a

i_udiUsrFsFreeBytes

UDINT

User FileSystem free memory size (in bytes).

n/a

i_uiTM3BusState

PLC_R_TM3_BUS_STATE

TM3 bus state.

i_uiTM3BusState can have the following values:

  • 1: TM3_CONF_ERROR

    Configuration mismatch between physical configuration and EcoStruxure Machine Expert configuration.

  • 3: TM3_OK

    Physical configuration matches EcoStruxure Machine Expert configuration.

  • 4: TM3_POWER_SUPPLY_ERROR

    TM3 bus is not powered (for example when the controller is powered by USB).

n/a

i_ExpertIO_RunStop_Input

BYTE

Run/Stop input location is:

  • 16...FF hex if the expert I/O is not configured

  • 0 for %IX0.0

  • 1 for %IX0.1

  • 2 for %IX0.2

  • ...and so on.

n/a

i_x10msClk

BOOL

TimeBase bit of 10 ms.

This variable is toggling On/Off with period = 10 ms. The value toggles when the controller is in STOPPED and in RUN state.

n/a

i_x100msClk

BOOL

TimeBase bit of 100 ms.

This variable is toggling On/Off with period = 100 ms. The value toggles when the controller is in STOPPED and in RUN state.

n/a

i_x1sClk

BOOL

TimeBase bit of 1 s.

This variable is toggling On/Off with period = 1 s. The value toggles when the controller is in STOPPED and in RUN state.

(1) Not accessible through the application as %MW.

n/a means there is no pre-defined Modbus address mapping for this system variable.