IMDTouchKnowledge BaseShop main store

How-to

Connecting a C-More HMI to a Schneider M340 over Modbus TCP

HMI and touchscreens Published 6 min read

Short answer

Yes. Select the Modicon Modbus TCP/IP driver in the C-More project, give the M340 a static IP address because its Ethernet modules default to dynamic addressing, and map each %MW word N to the one-based register reference N+1 — the field-documented case reads %MW62200 at 462201. Verify with one known word before building screens.

On this page
  1. Can a C-More HMI connect to a Schneider M340 over Modbus TCP?
  2. Why does the M340 need a static IP before you configure the panel?
  3. How do you set up the Modicon Modbus TCP/IP driver in C-More?
  4. How do you convert M340 %MW addresses to C-More register numbers?
  5. Which M340 data can the panel actually read?
  6. How do you verify the link before building screens?
  7. What about remote access and alarm messaging?
  8. Questions asked

Yes. A C-More panel connects to a Schneider Modicon M340 over Modbus TCP using the Modicon Modbus TCP/IP driver, and the pairing works once two preparations are handled. The M340's Ethernet interface defaults to dynamic addressing — with no address configured it derives one from its MAC — so it needs a static IP before the panel can target it reliably. And the driver counts registers from one while the M340 counts %MW words from zero, so every tag reference is the word index plus one: the field-documented case reads %MW62200 at reference 462201. This article walks the setup in the order you meet it: address the PLC, pick the driver, convert the addresses, verify one word, then plan the remote access and messaging that usually come next.

Can a C-More HMI connect to a Schneider M340 over Modbus TCP? #

Yes. A C-More panel with an Ethernet port talks to the M340's embedded Modbus TCP server with the Modicon Modbus TCP/IP driver selected in the C-More project — no gateway needed, and the driver choice is the single decision that makes the pairing work.

Modbus TCP splits the work cleanly: the C-More is the client that polls, and the M340's Ethernet port is the server that answers on the standard Modbus TCP port 502. The M340's datasheet lists Modbus TCP among its capabilities, so nothing sits between panel and PLC but a cable and a switch. The roles can also reverse on other machines — setting up a PLC Ethernet module as the Modbus TCP client with scattered registers follows the same client/server split from the other end of the wire.

What the link gives you is data: the tags you map in the sections below. It does not by itself give remote access or alarm messaging; that comes last.

Why does the M340 need a static IP before you configure the panel? #

Because the M340's Ethernet modules default to dynamic addressing: with no address configured, the port derives one from its MAC address in the 84.x.x.x form — one documented unit sat at 84.18.26.196 — which is not an address you chose for your control network.

Assign the static address in the M340's Ethernet configuration in the Unity Pro programming software, on the subnet the panel will live on, and record it. The alternative — BOOTP or DHCP assignment — carries a documented trap: M340 Ethernet modules will not receive an address from a BOOTP/DHCP server on application download if the IP configuration has not changed, so a re-download can silently keep the old address.

Decision: for a machine with one panel and one PLC, configure a static IP. A panel driver needs a fixed endpoint, and the MAC-derived default belongs to commissioning, not production.

How do you set up the Modicon Modbus TCP/IP driver in C-More? #

Open the Protocol Manager from the Home tab, choose Modicon Modbus TCP/IP, and aim it at the M340's static address on the standard Modbus TCP port 502 — three settings and the transport side is done.

  1. Open the C-More programming software and click the Protocol Manager button on the Home tab.
  2. Select Modicon Modbus TCP/IP as the protocol for the panel's Ethernet port.
  3. Enter the M340's static IP address where the driver asks for the controller.
  4. Put the panel and the M340 on the same subnet for the first test — same switch, same address range.
  5. Note the driver's reference format before building tags: it takes one-based, 4-prefixed register references, which is the subject of the next section.

How do you convert M340 %MW addresses to C-More register numbers? #

Add one to the %MW index and put a 4 in front of it: %MW62200 reads at reference 462201 because the C-More Modicon driver counts registers from one while the M340 counts %MW words from zero.

The offset exists because the C-More's Modicon driver speaks the old Modicon reference convention, which numbers holding registers from 1, while the M340's %MW addressing numbers words from 0. One register of difference, on every tag.

Formula: for M340 word %MW N, the C-More reference is a 4 followed by N + 1, zero-padded to the reference width. Worked example, from the field-documented case: %MW62200 becomes 62200 + 1 = 62201, and with the 4 prefix the reference is 462201. The same arithmetic on smaller words:

M340 word One-based register C-More reference
%MW0 1 40001
%MW150 151 40151
%MW62200 62201 462201

The 4-prefix form is the classic Modicon convention; decoding a long Modbus holding register reference from PLC to HMI shows where each digit comes from when the numbers run past five digits.

Which M340 data can the panel actually read? #

Only located variables on the M340's Modbus address list — the %MW words and other addressed data declared in the Unity Pro project — are served to the panel; a running program's internal variables are not.

Pull the address list from the project before writing tags: protocol compatibility does not expose the program's internals, only the located data. Two planning points while you build the list:

  • Group tags into contiguous %MW blocks where the application allows it — one block is one efficient poll, while scattered words cost the client extra requests.
  • A 32-bit value, such as a floating-point or double-word result, occupies two consecutive words, and the pair's word order must match what the display expects. Swapping words on a C-More 32-bit Modbus tag shows the fix when a value looks scrambled, and displaying a PLC real value over Modbus on an HMI covers the format side.

Write a known value into one %MW word the program does not use, and read it back at the calculated reference: if %MW62200 holds 12345, the panel must display 12345 at 462201 — one word proves the whole mapping.

  1. Choose a spare %MW word the program does not use and write 12345 into it from the programming software.
  2. Create one numeric display on the panel at the calculated reference — for %MW62200 that is 462201.
  3. Transfer the project to the panel and confirm it shows 12345.
  4. If the value belongs to a neighboring word, the reference is off by one — reapply N + 1.
  5. If nothing appears at all, fix the transport first: ping the M340, check the subnet, confirm the port.

Run the write test only on a word nothing in the program drives — never on a word that feeds outputs.

If panel and PLC disagree, an independent Modbus diagnostic client on a PC can confirm whether the M340 actually serves the value at that reference, which separates an HMI problem from a server problem. For the wider fault families, fixing Modbus TCP addressing errors between an HMI and a PLC covers the offset class of fault, and why a C-More panel reads nothing from a Micro800 PLC covers the connects-but-shows-nothing class.

What about remote access and alarm messaging? #

This link moves data only: remote access to the panel and alarm messaging are separate C-More features with their own network design, and you configure them after the local data path is proven.

Do them in order. For reaching the machine from outside the plant network, connecting an HMI to remote PLCs over a WAN covers the path and its timing effects. When the site has no fixed public address, remote HMI access with dynamic DNS and a VPN is the standard arrangement. Messaging — email on alarm — is a panel feature configured against the site's mail server, and it rides on the same proven data path. Get one tag reading correctly first; everything after that is configuration, not debugging.

Questions asked

Do writes from the panel follow the same %MW offset as reads?

Yes. The same one-based reference serves reads and writes: to set %MW200 from the panel, target register 201 with the 4 prefix, which is 40201. Test writes on a spare word the PLC program does not use, watch the value change in the programming software, and only then wire the button to data that matters.

Can I reach a factory-fresh M340 that has no IP set yet?

Yes, temporarily. With no address configured, the M340 derives one from its MAC in the 84.x.x.x form — the documented example sat at 84.18.26.196 — so give your PC a compatible 84.x.x.x address with a matching mask, connect, and configure the static control-network address you actually want before the panel enters the picture.

Why does the panel connect but show the wrong word?

Almost always the base. The Modicon driver counts registers from one and the M340 counts %MW words from zero, so a tag entered at the raw %MW number reads the previous word: %MW62200 entered as 462200 returns %MW62199. Move the reference up by one and the data lands. If a two-word value still looks scrambled after that, check word order next.

Can more than one C-More poll the same M340?

Yes. The M340's Ethernet interface is the server and accepts multiple TCP client sessions, so a second panel simply points at the same static address. The practical ceiling is the simultaneous-connection count of your exact processor or Ethernet module, so confirm that figure against the module documentation before adding a third or fourth station, and stagger poll rates so panels do not burst together.

Keep reading

  • Troubleshooting

    Connecting a Delta DVP 15MC PLC to a Weintek HMI

    The DVP 15MC exposes its data to an HMI as a Modbus TCP server on the standard port 502. In EasyBuilder Pro, use a 15MC-specific driver if your editor's driver list has one, otherwise the generic Modbus TCP driver with the controller's register-to-Modbus mapping table. A 64-bit QWORD spans four holding registers, so prove one read-only tag before building screens.

    HMI and touchscreens

  • Troubleshooting

    Fixing C-more CM5 timeout 1026 to a CLICK PLC

    Timeout 1026 on a C-more CM5 to CLICK link is almost always the CLICK Ethernet port on its out-of-box settings: the panel sent a Modbus TCP request and nothing answered. Select Use the following IP address with 192.168.0.10 and mask 255.255.255.0, enable the Modbus TCP server on port 502, put the panel at 192.168.0.20, then settle the one-register tag offset with a 1-2-3 write-and-read test.

    HMI and touchscreens

  • How-to

    Connecting an XBTGT HMI to an M241 PLC over Modbus TCP

    Delete the Generic Modbus TCP slave from the M241 device tree and activate the Modbus server on the controller's Ethernet interface instead — that slave makes the M241 a client, so both devices poll and neither answers. Then map Vijeo Designer driver address 40001 to PLC word %MW0, keep TCP port 502 open between panel and controller, and shift the address map by one word if a test read lands one register off.

    HMI and touchscreens