PortDock

Testing MC protocol communication without a PLC — simulator, 127.0.0.1, common mistakes

Test an HMI or data-collection program's MC protocol (SLMP) link on one PC before the PLC arrives, and avoid 3E/4E, binary/ASCII, port and station mix-ups.

Tools for this guidePLC Simulator Windows program · freeTCP Windows program · freeMC Protocol (SLMP) Frame Decoder web · no installIP Subnet Calculator web · no install

When an HMI, a data-collection program or host software reads and writes PLC values over the MC protocol (SLMP), you can test the communication part before the PLC arrives. PortDock PLC Simulator is a free Windows program that makes the PC answer MC protocol requests like a PLC's Ethernet port. This guide connects your program and the simulator on one PC through 127.0.0.1, and lists where people usually get stuck at first.

1. Set up the simulator

SettingChoose
TransportTCP server (several clients, up to 64) or UDP — whichever your program uses
Frame3E (subheader 5000) or 4E (5400 + serial number) — same as your program
Data codeBinary or ASCII — same as your program
Bind address127.0.0.1 (default) — only programs on this PC can connect
Port5000 by default. That is just this program's default; the manuals do not fix a port (it is set on the PLC side)

Pick device D at the top, enter values in D100–D102 and press «Start» (F4). Values can be entered before starting; changes while it runs apply from the next request.

2. Set up your program

3. First request — read 3 words from D100

50 00 00 FF FF 03 00 0C 00 10 00 01 04 00 00 64 00 00 A8 03 00

This is a 3E binary batch read (0401). «Reading an MC protocol 3E binary frame» explains each field. If the simulator holds 0x1995, 0x1202 and 0x1130 in D100–D102, the reply is:

D0 00 00 FF FF 03 00 08 00 00 00 95 19 02 12 30 11

After end code 00 00 (completed) come the values, low byte first. The same request in ASCII is «500000FF03FF000018001004010000D*0001000003». The simulator's traffic log decodes it as «0401 Read (words) D100 ×3» and «End 0000 OK · 6 bytes».

Common mistakes

SymptomCheck
Cannot connectIs the simulator started, and is the port the same? 127.0.0.1 accepts connections from this PC only. For an HMI on another PC, turn on «Allow other PCs to connect (0.0.0.0)» and allow the program in Windows Firewall
«Port already in use»Another program (or another PortDock window) is using that port
Requests arrive (RX) but no replyAn EV «IGNORED» line means 3E/4E or binary/ASCII differ. Also make sure fault injection «Do not respond» is off
TCP and UDP mixed upIf your program sends UDP, the simulator's transport must be UDP too
End code C057The header's request data length is wrong. It counts the bytes (characters in ASCII) from the monitoring timer to the end
End code C059A command or subcommand the simulator does not implement (it has 0401, 1401, 0403, 1402, 0619, and from 0.6.0 also 0406/1406 blocks, 0801/0802 monitor, 1001–1006 remote operation and 0101 Read Type Name)
End code C056A number beyond the device size (points). Increase «Size (points)» in the simulator
End code C05F«Own station requests only» is on and the station fields are not 00, FF, 03FF, 00
32-bit or float values look wrongThe lower-numbered word holds the low part (D200 low, D201 high). The default order in the simulator's «Cell settings» is CDAB
X/Y values land in the wrong placeX, Y, B, W and ZR are numbered in hex (X10 is the 17th from X0) — see the device numbering guide

Test the error handling too

What a simulator cannot tell you

PortDock PLC Simulator follows only the message formats in the public manuals and has not been compared with real hardware. No ladder program runs, and error codes, timing, connection limits and per-model device ranges may differ. Use it to get the communication side ready, and do the final test on the real PLC. Never run it on a plant network with the same IP and port as a real PLC — it would answer in its place.

This guide is based on Mitsubishi Electric's public manuals (SLMP and MC protocol); it is not affiliated with Mitsubishi Electric.

Sources

Published 2026-10-29