IMDTouchKnowledge BaseShop main store

How-to

Connecting a Magelis XBTN panel to a Zelio relay

HMI and touchscreens Published 6 min read By IMDTouch engineering team

Short answer

A Magelis XBTN panel exchanges data with a Zelio relay over one of two documented routes: a Zelio Modbus expansion with the panel as master, giving 4 words each way, or the Zelio programming port with SLIN and SLOUT, giving 24 words each way and needing VJDlite 1.3. Pick the programming port when you need more than 4 words.

On this page
  1. Which connection route should you choose?
  2. What do you set in the Zelio project for the Modbus expansion?
  3. Which Zelio words carry the data on the expansion route?
  4. How do you configure the programming-port route?
  5. Does the XBTN401 behave like the XBTN402?
  6. What happens to the exchanged data on a power loss?
  7. Questions asked

Two documented routes connect a Magelis XBTN panel to a Zelio smart relay. Route one is a Zelio Modbus expansion, with the panel as Modbus master and the relay as slave, exchanging 4 words in each direction through the CNA and CAN conversion functions. Route two is the Zelio programming port carrying the Zelio protocol, using the SLIN and SLOUT functions for 24 words in and 24 words out; it needs VJDlite 1.3 and a dedicated cable, packaged as starter kit VJDSTKXBTNSR2. Choose route two whenever the application outgrows the small expansion block. This article sets up both.

Which connection route should you choose? #

Choose the Modbus expansion when 4 words each direction cover all your commands and status, and the programming-port route when you need up to 24 words each way; anything beyond a few bits plus one numeric value goes to the programming port. On the expansion route the panel is master and the relay is slave, the same roles as in connecting an XBTGT panel to an M241 PLC over Modbus TCP, except the link runs to an expansion module instead of the controller's own port.

Modbus expansion route Programming-port route
Zelio connection Modbus expansion module Zelio programming port
Panel driver Modbus master Zelio-protocol driver
Exchange capacity 4 words in, 4 words out 24 words in, 24 words out
Zelio program objects Outputs O1 to O4 and inputs J1 to J4, with CNA and CAN SLIN and SLOUT functions
Extra requirements The expansion module VJDlite and the Zelio cable (kit VJDSTKXBTNSR2)

Both routes carry the same kind of content: command bits from the panel, status bits to the panel, and numeric values such as a setpoint or a timer preset. The difference is capacity and wiring, not what the panel can display.

What do you set in the Zelio project for the Modbus expansion? #

Select the Modbus expansion together with the relay in the Zelio Soft 2 hardware selection, or the communication inputs and outputs never appear on the programming page and there is nothing to wire to. A module bolted onto the relay does not add program objects to a project that was configured without it.

  1. In the module selection, tick the Modbus expansion alongside the SR2 relay reference before opening the programming workspace.
  2. Program in FBD; it lets you connect the expansion words to logic and to the conversion blocks more clearly than ladder.
  3. For status going to the panel, convert the discrete states into a word with CNA or CAN (each block's help states its direction) and connect the result to one of the outputs O1 to O4.
  4. For commands arriving from the panel, convert the word at inputs J1 to J4 back into bits with the other conversion function and use those bits in the logic.
  5. Pass numeric values such as a setpoint as raw words with no bit conversion, matching the panel object's format and scaling to what the relay program expects.

Which Zelio words carry the data on the expansion route? #

The expansion fixes the addresses for you: outputs O1 to O4 present status to the panel at words Mw20 to Mw23, and inputs J1 to J4 receive commands from the panel at Mw16 to Mw19.

Zelio object Word Direction Who writes, who reads
O1 Mw20 Zelio to panel Zelio writes status, panel reads
O2 Mw21 Zelio to panel Zelio writes status, panel reads
O3 Mw22 Zelio to panel Zelio writes status, panel reads
O4 Mw23 Zelio to panel Zelio writes status, panel reads
J1 Mw16 Panel to Zelio Panel writes commands, Zelio reads
J2 Mw17 Panel to Zelio Panel writes commands, Zelio reads
J3 Mw18 Panel to Zelio Panel writes commands, Zelio reads
J4 Mw19 Panel to Zelio Panel writes commands, Zelio reads

Worked example with an illustrative bit assignment: pack four status bits into O1, with pump running on bit 0, tank-high on bit 1, alarm on bit 2 and auto mode on bit 3. With pump running, no high level, alarm active and auto mode on, the word is 1×1 + 0×2 + 1×4 + 1×8 = 13. The conversion block drives 13 onto O1, and the panel object mapped to Mw20 displays 13. In the other direction, a panel key writes 5 into Mw16, which arrives at J1: 5 = 1 + 4, so bits 0 and 2 are on and the word-to-bit function closes exactly those two Zelio contacts.

Before duplicating objects across the map, prove one position with a live value: force a known pattern onto O1 and confirm the panel shows that word and not a neighbouring one, because a driver's address notation can differ from the raw word number.

How do you configure the programming-port route? #

Connect the panel to the Zelio programming port with the dedicated Zelio-protocol cable, build the panel project in VJDlite version 1.3, and place SLIN and SLOUT in the relay program to define the exchange positions. There is no Modbus register table on this route; the positions you configure in those two functions are the address map.

  1. Declare the Zelio as the link target in the panel project; the software then selects the protocol automatically.
  2. Get VJDlite from Schneider Electric's support site, or take it from starter kit VJDSTKXBTNSR2, which also bundles the panel programming cable (USB-RS485), the Zelio USB cable and accessories.
  3. In the relay program, place SLIN for the words the panel drives into the relay's inputs and SLOUT for the parameter words the panel reads; set their exchange positions to match the panel objects.
  4. Test each position with a changing value at both ends before building the full screen set.

Does the XBTN401 behave like the XBTN402? #

The Modbus-expansion setup is field-confirmed on an XBTN402; before running it on an XBTN401, confirm that panel's supported-connection list in the software, because an XBTN402 project does not transfer unchanged to the smaller panel. The kit reference VJDSTKXBTNSR2 by itself does not establish compatibility with every XBTN model either, so match the kit and the panel in the vendor's documentation for the exact reference you have.

For an existing XBTN402 with the expansion installed, keep route one. For an existing XBTN401, open its controller list first: if the Zelio protocol driver is listed, wire the programming-port route; if only a Modbus master driver is listed, the expansion route is the one available to you. For a new build, take the programming-port route with the kit, because the larger exchange block costs nothing in panel capacity and avoids the expansion module altogether.

What happens to the exchanged data on a power loss? #

Every exchange word drops to 0 when power fails, so any setting held only in the exchange area is lost; the relay program must keep presets elsewhere and the panel must rewrite its commands after restart. This applies on both routes: the exchange words are a mailbox, not memory.

  1. Keep timer presets, thresholds and mode settings in the relay's own program variables, not in words routed through SLIN, SLOUT or the expansion.
  2. Have the panel rewrite its command words on startup, since a restored supply brings every exchange word back as zero.
  3. Design keys as a set-and-reset pair so a command cannot stay latched after the operator releases the screen.
  4. Let the relay program, not the screen object, drive the outputs to a defined state when the link stops updating; that is the safe-state decision for the machine and it belongs in the Zelio logic.

Questions asked

Do I need to understand Modbus frames to use the expansion route?

No. The panel's driver builds the requests and replies; in the panel software you declare the Zelio as the link target and the protocol is selected automatically. Your only job is mapping screen objects to the fixed expansion words, so frame timing and function codes never appear in the project.

Can several panel keys write into the same command word?

Yes, but only if each key sets its own bit. A key whose object writes the whole word can clear bits that another key set a moment earlier. Check in the driver documentation whether the object performs a bit operation or a full-word write before packing independent commands into one word.

Should the Zelio program be in FBD or ladder?

Use FBD. It exposes the expansion words as connectable pins, so you can wire the CNA and CAN conversion blocks straight to the module inputs and outputs and see the data flow. Ladder works, but the word wiring is harder to follow when you troubleshoot it months later.

Where does the panel software come from?

VJDlite is downloadable from Schneider Electric's support site. The VJDSTKXBTNSR2 starter kit bundles the software with the panel programming cable, the Zelio USB cable and accessories, so a first build normally starts from the kit rather than sourcing the parts separately.

Keep reading

  • 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

  • How-to

    How to Swap Words on a C-More 32-Bit Modbus Tag

    Yes. In the C-more programming software, open Panel Manager, select the Modbus protocol, and enable Word Swap in its Setup dialog — add Byte Swap if each register's bytes are also reversed. The setting applies to every tag on that protocol instance, reaches the panel only with a full project transfer, and should be verified against a known reference value such as 0x12345678 (305419896 decimal).

    HMI and touchscreens

  • How-to

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

    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.

    HMI and touchscreens

Run and Stop a SIMOTION CPU from a Comfort Panel HMI