# US 2013/0159447 A1 · System, gateway, and method for automatic setting configuration by learning commands

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2013/0159447 A1
- Document ID: US20130159447A1
- Status: Published application
- Kind: A1
- Application number: 13/325,060
- Filed: 2011-12-14
- Published: 2013-06-20
- Earliest claimed: 2011-12-14
- Assignees: Moxa Inc.
- Inventors: Bo Er WEI; Kuo Wei Chu
- Web page: https://patentgrep.com/patent/US20130159447A1

## CPC

- H04L 41/0806: for initial configuration or provisioning, e.g. plug-and-play
- H04L 41/0886: {Fully automatic configuration}
- H04L: TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION (arrangements common to telegraphic and telephonic communication H04M)

## Abstract

A system, a gateway, and a method for automatic setting configuration by learning commands are provided. The invention collects communication commands sent in a first network, stores target data accessed by a first device in the first network according to the communication command to an address, and maps the address to an I/O module used to access the target data by a second device. The system and the method can set the configuration of a gateway automatically, and achieve the effect of enhancing the efficiency of gateway configuration setting.

## Claims

### Claim 1

A method for automatic setting configuration by learning commands applied to a gateway, the method comprising the steps of:
setting communication parameters of a first communication protocol used by the gateway;
connecting the gateway to a first network using the first communication protocol, the first network including at least one first device;
collecting at least one communication command transmitted in the first network until a stop collecting condition is satisfied; and
mapping the address of storage location for target data accessed by the communication command to at least one communication I/O module for a second device connected to the gateway using a second communication protocol to access the target data via the communication I/O module.

### Claim 2 (depends on 1)

The method of claim 1, wherein the step of collecting at least one communication command transmitted in the first network uses the gateway as a slave/sniffer device in the first communication protocol to receives/sniff the communication commands sent from a mater device in the first communication protocol to a plurality of slave devices with different slave addresses or destination nodes of different destination node addresses and to record the communication commands after receiving/sniffing the communication commands.

### Claim 3 (depends on 1)

The method of claim 1, wherein the step of collecting at least one communication command transmitted in the first network is followed by the step of determining whether each of the communication commands is first collected, defining the trigger mode of the first collected communication command as ‘data change’ and defining the trigger mode of non-first collected communication command as ‘periodic transmission’, and calculating a polling interval of the non-first collected communication command.

### Claim 4 (depends on 1)

The method of claim 1, wherein the step of collecting at least one communication command transmitted in the first network further includes the step of determining whether the communication commands are supported by the gateway and recording the communication commands when supported or recording slave address and function code or destination node addresses and command code in the communication commands when not supported.

### Claim 5 (depends on 1)

The method of claim 1, wherein the stop collecting condition is that when the communication command collecting time reaches a specific system cycle, that the number of collected communication commands within a specific time does not increase any more, or defined by the received communication commands, the number of received communication commands, and/or the time used to collect the communication commands.

### Claim 6 (depends on 1)

The method of claim 1, wherein mapping the address of storage location for target data accessed by the communication command to at least one communication I/O module for a second device connected to the gateway using a second communication protocol to access the target data via the communication I/O module comprise steps of:
determining a length of the target data from the communication command;
from an input/a output block in the internal memory, determining first free address which doesn't occupied by other target data as the storage address;
configuring the communication I/O module according to the length of the target data; and
mapping the communication I/O module to the storage address.

### Claim 7 (depends on 6)

The method of claim 6, wherein the step of from an input/a output block in the internal memory, determining for first free address which doesn't occupied by other target data as the storage address is determining the free address from bottom address to top address of the input/output block.

### Claim 8

A system for automatic setting configuration by learning command applied to a gateway that connects to at least a first network with a first device using a first communication protocol via a first communication interface and connects to a second network with a second device using a second communication protocol via a second communication interface, the system comprising:
a setting module for setting communication parameters of the first communication protocol used by the gateway;
a condition judging module for determining whether a stop collecting condition is satisfied;
a command collecting module for collecting a plurality of communication commands transmitted in the first network via the first communication interface until the condition judging module determines that the stop collecting condition is satisfied; and
a data mapping module for storing target data accessed by a communication command in internal memory of the gateway and mapping the address of storage location of the target data to at least one communication I/O module for the second device to access the target data via the communication I/O module.

### Claim 9

A gateway for automatic setting configuration by learning commands, comprising:
an internal memory;
a first communication interface for connecting to a first network with a first communication protocol, the first network including at least one first device;
a second communication interface for connecting to a second network with a second communication protocol, the second network including at least one second device;
a setting module for setting communication parameters of the first communication protocol used by the first communication interface;
a condition judging module for determining whether a stop collecting condition is satisfied;
a command collecting module for collecting a plurality of communication commands transmitted in the first network via the first communication interface until the condition judging module determines that the stop collecting condition is satisfied; and
a data mapping module for storing target data accessed by a communication command in the internal memory and mapping the address of storage location of the target data to at least one communication I/O module for the second device to access the target data via the communication I/O module.

### Claim 10 (depends on 9)

The gateway of claim 9, wherein the command collecting module sets the gateway as a slave/sniffer device in the first communication protocol to receive/sniff the communication commands sent from the master device to slave devices of different slave addresses and the destination nodes of different destination node addresses and to record the communication commands after receiving/sniffing the communication commands.

### Claim 11 (depends on 9)

The gateway of claim 9, wherein the gateway further includes a trigger mode judging module for determining whether each of the communication commands is first collected, defining the trigger mode of the first collected communication command as ‘data change’ and defining the trigger mode of non-first collected communication command as ‘periodic transmission’, and calculating a polling interval of the non-first collected communication command.

### Claim 12 (depends on 9)

The gateway of claim 9, wherein the command collecting module determines whether the communication commands are supported by the gateway and recording the communication commands when supported or recording the slave address and function code or destination node addresses and command code in the communication commands when not supported.

### Claim 13 (depends on 9)

The gateway of claim 9, wherein the stop collecting condition is that when the communication command collecting time reaches a specific system cycle, that the number of collected communication commands within a specific time does not increase any more, or defined by the received communication commands, the number of received communication commands, and/or the time used to collect the communication commands.

### Claim 14 (depends on 9)

The gateway of claim 9, wherein the gateway further includes a display module for displaying the number of collected communication commands, the number of unsupported communication commands, the number of invalid communication commands, slave address and function code or destination node addresses and command code that do not support the communication commands, or the slave address or destination node addresses with invalid communication commands.

### Claim 15 (depends on 9)

The gateway of claim 9, wherein the data mapping module configures the communication I/O module according to length of the target data and maps the communication I/O module to the storage address after determines first free address which doesn't occupied by other target data as the storage address from an input/a output block in the internal memory.

### Claim 16 (depends on 15)

The gateway of claim 15, wherein the data mapping module determines the free address from bottom address to top address of the input/output block.

### Claim 17 (depends on 9)

The gateway of claim 9, wherein first communication protocol is a fieldbus protocol that uses communication commands to access data.

### Claim 18 (depends on 9)

The gateway of claim 9, wherein second communication protocol uses I/O data exchange for communication.
