Skip to main content

LS ELECTRIC — XGI / XBC / XBM

Communicates with LS ELECTRIC (formerly LS Industrial Systems) XGI / XBC / XBM PLC series over the FEnet (Fast Ethernet) standard protocol.

This is the most commonly used communication method on the XGT series. The gateway first verifies ICMP (ping) reachability, then begins actual communication.


Registration form entries

FieldWhat to enterExample
IP addressIP of the PLC's FEnet module192.168.0.80
PortFEnet port2004 (XGT default)
Connect timeout (connect-timeout)Maximum time for a connection attempt (ms)3000
Read timeout (read-timeout)Maximum time for a read response (ms)3000
Use checksum (use-checksum)BCC checksum optionUsually false
Use hex bit index (use-hex-bit-index)Whether to interpret bit numbers as hexadecimalUsually false. Set to true only when using hex indices such as F in the P area

On the PLC side, register the FEnet module's IP / port in advance using XG5000.

ping check

Before attempting communication, the gateway checks whether the LS PLC is reachable via ping. If ICMP (ping) is blocked on the corporate network, even a healthy PLC will be reported as "Ping failed" — check your firewall policy.


PLC address notation for tags

For LS PLCs the short form (D00309) is recommended; the gateway automatically converts it to the standard form (%DW00309).

Memory areas

LetterArea
DData Register — most common
MMemory (memory bit)
KKeep Relay
FFlag
TTimer
CCounter
R(depends on series)
PI/O

Notation examples

Notation (short form)Meaning
D00309Data Register 309 (16-bit)
D00600Data Register 600 (to use it as 32-bit, specify DW in [format qualifier])
M02704Memory bit 2704
P0001FI/O bit (when using hex indices)

Because the same LS address can be interpreted as 16-bit / 32-bit / 64-bit / floating point, the [format qualifier] is essential.


Data type matching

PLC valueData typeFormat qualifierPLC address example
Bit (M, K, T, P)Boolean(empty)M02704
A specific bit within a wordBooleanBIN[3] (bit 3)D00309
16-bit integerInteger(empty)D00309
16-bit unsignedIntegerUID00300
32-bit integerIntegerDWD00600 (uses D00600–D00601)
32-bit unsignedIntegerUDWD00690
64-bit integerLong(empty)D00700
32-bit float (most common float type)FloatREALD00450
64-bit floatDoubleLREALD00500
String of N words (= 2N characters)StringSTR[N]D00500
What if the value is 32-bit and the format qualifier is left empty?

It is read as 16-bit, so the value comes out as a completely different number. Always specify DW for 32-bit integers and REAL for 32-bit floats.


Common problems and solutions

Symptom / messagePossible causeSolution
"Ping failed"ICMP is blockedAllow ICMP on the firewall. If that is not possible, contact your system administrator
"Connect failed"FEnet module not running, or wrong portCheck the FEnet module IP/port (2004) in XG5000
32-bit value looks wrongFormat qualifier left emptySpecify DW (integer) / REAL (float)
Bit is not readRegistered as D00100 (D is a word area)Use a bit area such as M02704, or extract the bit from the word with format=BIN[3]
Garbled string charactersLS sends data low-byte-firstThe gateway handles this automatically. Take care when decoding directly with external tools

Frequently used examples

Registering a general line PLC

Tag namePLC addressData typeFormat qualifier
Run bitM02704Boolean(empty)
Counter (16-bit)D00309Integer(empty)
Cumulative production (32-bit)D00600IntegerDW
Pressure (float)D00100FloatREAL
Pressure (kPa, converted)D00100FloatREAL (formula ${VALUE}*0.1)
Batch name (10 words)D00500StringSTR[10]

Extracting bits from a word

If several bit signals are packed into the same word, you can register them one per row using BIN[비트번호].

Tag namePLC addressData typeFormat qualifier
Bit 0D00309BooleanBIN[0]
Bit 3D00309BooleanBIN[3]
Bit 15D00309BooleanBIN[F] (hex F = 15)

Setting the PLC registration option with use-hex-bit-index=true enables the use of hex indices (F, etc.).


More detailed examples / automated registration

See the LS examples in Advanced — REST API.