Professional Documents
Culture Documents
SGW1-IA3-MMP - Modbus Multiplexer Exemys
SGW1-IA3-MMP - Modbus Multiplexer Exemys
Exemys products are constantly evolving to meet the needs of our customers. For this reason,
the specifications and capabilities are subject to change without notice.
Page Index
1 Introduction ________________________________________________________
________________________________________________________ 4
1.1 User’s Manual Purpose ________________________________________________
________________________________________________ 4
1.2 Product Overview____________________________________________________
____________________________________________________ 4
1.3 Ordering Codes _____________________________________________________
_____________________________________________________ 5
1.4 Technical Specifications _______________________________________________
_______________________________________________ 5
2 Installation ________________________________________________________
________________________________________________________ 6
2.1 Power ____________________________________________________________
____________________________________________________________ 6
2.2 Connections________________________________________________________
________________________________________________________ 6
2.3 LED indicators ______________________________________________________
______________________________________________________ 7
3 Configuration ______________________________________________________
______________________________________________________ 8
3.1 Master / Slave configuration parameters ___________________________________
___________________________________ 9
3.2 Serial Port Configuration _____________________________________________
_____________________________________________ 10
3.3 RTS Control Configuration ____________________________________________
____________________________________________ 11
3.4 Slave ranges, Configuration ___________________________________________
___________________________________________ 11
3.5 Other configuration settings. __________________________________________
__________________________________________ 14
4 Typical Usage Modes ________________________________________________
________________________________________________ 15
4.1 Multiplexer Mode __________________________________________________
__________________________________________________ 15
4.2 De-
De-Multiplexer Mode ________________________________________________
________________________________________________ 16
4.3 Converter Mode ____________________________________________________
____________________________________________________ 17
4.4 Interchange memory Mode ____________________________________________
____________________________________________ 17
5 Monitoring _______________________________________________________
_______________________________________________________ 18
A. FIRMWARE UPGRADE 19
B. FACTORY SETTINGS 22
1 Introduction
The purpose of this manual is to provide the instructions for installing and operating the
SGW1-IA3-MMP quickly and simply. The manual begins with a general description of the
product, following the instructions for the correct installation of the hardware. The
configuration and operation of the device is detailed later.
Acronym Description
PC Personal Computer
USB Universal Serial Bus
LED Led Indicator
GND Ground (Reference)
The SGW1-IA3-MMP orders the interrogations coming from the different masters assigning a
priority according to the order of arrival of the different masters, and then sends them to the
slaves.
As an additional function, the device allows the exchange of information between Modbus
masters through the 1000-byte exchange memory that can be read and written by any of the
connected masters.
www.exemys.com SGW1-IA3-MMP User’s Manual Rev. 1 4
SGW1-IA3-MMP – Modbus Multiplexer Exemys
SGW1-4B0
4B0-00
4B0 00-IA3-MMP
00 4 RS-232 / RS-485 ports
SGW1-13B0
13B0-00
13B0 00-IA3-MMP-CF
00 CF 1 RS232with flow control + 3 RS-232 / RS-485 ports
Configuration
Configuration Serial USB console.
Firmware
Firmware upgrade Via serial RS232 console
LED’s Indicators
Indicators Power, Modbus data
10 a 30 [Vdc].
Power
12 Vdc – 70 [mA]
24 Vdc – 40 [mA].
1 year
Warranty
Technical support included.
2 Installation
2.1 Power
The SGW1-IA3-MMP accepts a power supply in the range of +10 to 30 Vdc and must connect
the positive of the power supply to terminal No. 17 and the negative of the power supply to
terminal No. 18, as shown in the following figure:
2.2 Connections
SGW1-4B0
4B0-
4B0-00-IA3-MMP
00 SGW1-13B0
13B0-
13B0-00-IA3-MMP-CF
00 CF
RS232 ports are DTE type. That is, it is transmitted through the TX terminal and is received by
the RX terminal. If you want to connect another DTE device you must cross the terminals Tx and
Rx.
3 Configuration
The SGW1-IA3-MMP provides a command console for configuration via USB port.
To access it, the SGW1-IA3-MMP must be connected to a USB port on a PC and it must have
the Exemys terminal program called Exemys Console.
The driver for the USB can be downloaded from here: http://www.exemys.com/rmsrmdriver
Once the driver and the terminal type program have been installed, the terminal must be run,
connect the SGW1-IA3-MMP to a USB port on the PC and go to the Connection -> USB
menu, a window will open with the description of all the Exemys products with USB found.
Select with double click the product to be configured and pressing ENTER will show a ">"
sign indicating that you can enter the configuration commands listed below.
In the commands below, the suffix X must be replaced by A, B, C or D depending on the serial port
that you want to configure.
Command Description
Configures if a Master or a Slave will be connected to the COM
NOTE: The priority of level 0 is the maximum. For each priority level added, extra
10 milliseconds are delayed before responding to that master's order.
PRIORITY:
(0..100)
This command applies to all ports connected to masters.
[ms]
• Value = 0 ... 100 [ms].
NOTE: The priority of level 0 is the maximum. For each priority level added, extra
PRIORITYx:
10 milliseconds are delayed before responding to that master's order.
(0..100)
[ms] • Value = 0 ... 100 [ms].
Command Description
Configures the baud rate of the X port.
BAUDx:
• Values = 1200, 2400, 4800, 9600, 14400, 19200, 28800, 38400, 57600 or
(1200|…|
115200..
115200)
Example of use: BAUDA:115200
Configures the data bits of the X port.
BITSx:
• Values = 7 or 8.
(7|8)
Example of use: BITSB:7
Configure the parity of port X.
PKTTOUT - Modbus RTU packet expiry time: Modbus RTU packets are separated
from each other by a time interval. This parameter allows you to change the
maximum time to count after the last byte of the packet is received, during which
the SGW1-IA3-MMP will assume that the packet has not yet been terminated.
After this maximum time, the SGW1-IA3-MMP will assume that the packet has
finished arriving. The time is entered in one-byte time units, with a minimum of 3
units.
www.exemys.com SGW1-IA3-MMP User’s Manual Rev. 1 10
SGW1-IA3-MMP – Modbus Multiplexer Exemys
The SGW1-13B0-00-IA3-MMP-CF can handle the RTS pin on port A for the activation of the
transmission in devices, such as a radio modem.
The RTS pin handles a timer, which will activate a time before sending data through the
serial port and will turn off a time after the end of the shipment. This option applies only to
port A on the device.
Command Description
Sets the RTS polarity.
RTSLOGIC:
• 0 = Inverted. / 1 = Normal.
(0|1)
Example of use: RTSLOGIC:1
Configures the delay prior to sending data.
RTSDON:
• Value = 0 ... 1000 [ms].
(0..1000)
[ms]
Example of use: RTSDON:50
It is also possible to apply an Offset to the ID of the Modbus queries that arrive from the
masters before sending them to the corresponding slave port. This allows you to change the
ID with which the slaves are read from the point of view of the masters.
Command Description
Adds a range of slaves to which the indicated master will access.
Queries arriving at port A with Modbus ID between 20 and 50 are sent to port
C without applying offset to the received ID.
SRANGEADD:A,20,50,C,1,E
Queries arriving at port A with Modbus ID between 20 and 50 are sent to port C
C applying a -1 offset to the ID received and converting the query to ENRON
format.
Example of use:
SRANGEDEL:A,20,50,C,0 Clear Range A, 20.50, C, 0
SRANGEDEL:ALL Deletes all ranges.
SRANGEADD:A,1,20,B,0
SRANGEADD:A,35,39,C,0
• Example 2 (Offset use): Read four Modbus slaves from two masters. Two of the slaves have
the ID # 1 and the other two the ID # 2.
• Port A: Master 1.
• Port B: Master 2.
• Port C: First pair of slaves with ID # 1 and # 2.
• Port D: Second pair of slaves with ID # 1 and # 2.
SRANGEADD:A,1,2,C,0
SRANGEADD:A,3,4,D,2
SRANGEADD:B,1,2,C,0
SRANGEADD:B,3,4,D,2
In this way, both masters will be able to access the first pair of slaves using ID # 1 and # 2,
and the second pair of slaves using ID # 3 and # 4.
Command Description
Configure the ID of the internal slave to access the data transfer memory.
INTSLVID:
• Values = 1 ... 254.
(1..254)
Example of use: INTSLVID:110
Enables the traces by the USB console, for port X. Or for all ports by setting ALL.
TRACESON:
• Values = A, B, C, D, or ALL.
(A|B|C|D|ALL)
Example of use: TRACESON:D
Disables the traces by the USB console, for port X. Or for all ports by setting ALL.
TRACESOFF:
• Values = A, B, C, D, or ALL.
(A|B|C|D|ALL)
Example of use: TRACESOFF:ALL
Turn on or off the aggregate of information to the TRACES.
This aggregated information is the content of Modbus frames expressed in
hexadecimal.
TRACESFULL: NOTE:
NOTE Keep in mind that for this command to work, TRACES must be enabled on
(E|D) at least one port
• E = Enabled. / D = Disabled.
The first command that we should use is MSCOM and set Port A in slave mode and the other
ports master mode.
With the BAUD, BITS, PARITY, STOP and PROTOCOL commands you can configure the
particular characteristics of each port. The team will perform conversions between one COM
and another if necessary.
It is important to take into account the response time of the slaves. This time can be set on
each port connected to slaves with the SLVTOUT command. Then you must set the response
time (timeout) on each of the master devices connected to the device. As a rule the master
timeout must be at least N times the timeout set in SGW1, N being the number of masters (1,
2 or 3)
Example of configuration: 1 Master and 3 Slaves (with different characteristics in their series
ports).
The first command to use is MSCOM and set Port A in "Master" mode and the other Ports in
"Slaves" mode”.
In order for the device to know which port to send the Modbus query sent by the master, the
Modbus ID range of the slave devices of each port must be configured. Use the
SRANGEADD, SRANGEDEL, and SRANGELIST commands
This feature allows Modbus masters connected to the device to exchange information
between them by reading and writing a memory area of the SGW1-IA3-MMP intended for
this purpose. This mode can be used in conjunction with the multiplexer mode.
The Modbus ID number of the internal slave is 240. It can be modified through the
INTSLVID command.
For this we must configure master A to read registers 40001 to 40050 of slave # 240 and to
write registers 40051 to 40150 with the information that master B needs. In the same way,
set up master B to read registers 40051 to 40150 of slave # 240 and to write registers 40001
to 40050 with the information that master A needs
5 Monitoring
The SGW1-IA3-MMP allows you to monitor communications on all four ports from the USB
console. With the TRACESON command the monitoring messages are enabled. With the
complementary command TRACESFULL you can have more detailed information.
Activating the TRACESON command, we will see the incoming and outgoing traffic
corresponding to the port activated and the ID of the target device. Then when adding the
TRACESFULL command, the content of the traffic expressed in hexadecimal is added to
the above information.
In the following example, the TRACESON and TRACESFULL commands of ports A and C
are activated:
Activation of the TRACESON and TRACESFULL commands cause process delays in the device,
due to the density of information to be presented; So activating these commands slows
communication between the devices.
A. Firmware Upgrade
The firmware of the device can be upgraded in case of new versions with improvements, by
accessing the serial console intended for this purpose.
Connect an RS232 cable such as the one between the device and a device and follow these
steps
1) Open an Exemys Console terminal type program in the COM of the corresponding
device and verify in the terminal that the Baudrate is in 9600.
2) Turn the SGW1-IA3-MMP on and within the first 7 seconds enter CFG and press
ENTER or press the CFG button that is available. Once this is done the SGW1-IA3-
MMP will display the welcome message to the configuration command console:
4) Locate and select the binary file (.bin) to transfer and press the Open button to
start updating the firmware of your device.
5) During the transfer of the file the progress of the process will be displayed.
6) At the end of the device will be restarted to install the update, preserving the
configuration that was available.
Do not turn off the device once the message Verifying firmware ... is displayed, this can cause
irreparable damage.
B. Factory settings
Parameter Value
Ports A, C y D
Mode. MASTER
Priority 0[ms]
Baud Rate. 9600
Data bits 8
Parity NO
Stop bits 1
Modbus type RTU
Exceptions Disabled
Modbus RTU packet time 3[bytes Time]
Over write protection Disabled
Port B
Mode SLAVE
Message response time 500[ms]
Baud Rate. 9600
Data bits 8
Parity NO
Stop bits 1
Modbus type RTU
Exceptions Disabled
Modbus RTU packet time 3[bytes Time]
Slave Tables
Port A, 1, 254, Port B, 0
Port Master, ID start, ID Finish, Port Slave, Offset. Port C, 1, 254, Port B, 0
Port D, 1, 254, Port B, 0
Others
Internal memory ID 240
Click !
To remove the rail module, first remove the input terminals. Then, insert a screwdriver into
the lower lock of the device's DIN connector and force the connector down until the module
disengages
Riel DIN
Riel DIN