Update READ.me

MQTT-SN transparent Gateway to transparent/aggrigating gateway.


Signed-off-by: tomoaki <tomoaki@tomy-tech.com>
This commit is contained in:
tomoaki
2019-01-15 17:18:16 +09:00
parent c7b8ef1e54
commit 284b5d5b46
4 changed files with 13 additions and 9 deletions

View File

@@ -1,4 +1,7 @@
**MQTT-SN** requires a MQTT-SN Gateway which acts as a protocol converter to convert **MQTT-SN messages to MQTT messages**. MQTT-SN client (UDP) can not communicate directly with MQTT broker(TCP/IP). # MQTT-SN Transparent / Aggrigating Gateway
**MQTT-SN** requires a MQTT-SN Gateway which acts as a protocol converter to convert **MQTT-SN messages to MQTT messages**. MQTT-SN client over SensorNetwork can not communicate directly with MQTT broker(TCP/IP).
This Gateway can run as a transparent or aggrigating Gateway by specifying the gateway.conf.
### **step1. Build the gateway** ### **step1. Build the gateway**
```` ````
@@ -36,12 +39,12 @@ BrokerPortNo=1883
BrokerSecurePortNo=8883 BrokerSecurePortNo=8883
# #
# When AggregateGateway=YES or ClientAuthentication=YES, # When AggregatingGateway=YES or ClientAuthentication=YES,
# All clients must be specified by the ClientList File # All clients must be specified by the ClientList File
# #
ClientAuthentication=NO ClientAuthentication=NO
AggregateGateway=NO AggregatingGateway=NO
QoS-1=NO QoS-1=NO
Forwarder=NO Forwarder=NO
@@ -82,7 +85,7 @@ ShearedMemory=NO;
Client should know the MulticastIP and MulticastPortNo to send a SEARCHGW message. Client should know the MulticastIP and MulticastPortNo to send a SEARCHGW message.
**GatewayId** is used by GWINFO message. **GatewayId** is used by GWINFO message.
**KeepAlive** is a duration of ADVERTISE message in seconds. **KeepAlive** is a duration of ADVERTISE message in seconds.
when **AggregateGateway** or **ClientAuthentication** is **YES**, All clients which connect to the gateway must be declared by a **ClientsList** file. when **AggregatingGateway** or **ClientAuthentication** is **YES**, All clients which connect to the gateway must be declared by a **ClientsList** file.
Format of the file is ClientId and SensorNetwork Address. e.g. IP address and Port No etc, in CSV. more detail see clients.conf. Format of the file is ClientId and SensorNetwork Address. e.g. IP address and Port No etc, in CSV. more detail see clients.conf.
When **QoS-1** is **YES**, QoS-1 PUBLISH is available. All clients which send QoS-1 PUBLISH must be specified by Client.conf file. When **QoS-1** is **YES**, QoS-1 PUBLISH is available. All clients which send QoS-1 PUBLISH must be specified by Client.conf file.
When **PredefinedTopic** is **YES**, **Pre-definedTopicId**s specified by **PredefinedTopicList** are effective. This file defines Pre-definedTopics of the clients. In this file, ClientID,TopicName and TopicID are declared in CSV format. When **PredefinedTopic** is **YES**, **Pre-definedTopicId**s specified by **PredefinedTopicList** are effective. This file defines Pre-definedTopics of the clients. In this file, ClientID,TopicName and TopicID are declared in CSV format.

View File

@@ -19,12 +19,12 @@ BrokerPortNo=1883
BrokerSecurePortNo=8883 BrokerSecurePortNo=8883
# #
# When AggregateGateway=YES or ClientAuthentication=YES, # When AggregatingGateway=YES or ClientAuthentication=YES,
# All clients must be specified by the ClientList File # All clients must be specified by the ClientList File
# #
ClientAuthentication=NO ClientAuthentication=NO
AggregateGateway=NO AggregatingGateway=NO
QoS-1=NO QoS-1=NO
Forwarder=NO Forwarder=NO

View File

@@ -40,7 +40,7 @@ void Aggregater::initialize(void)
{ {
char param[MQTTSNGW_PARAM_MAX]; char param[MQTTSNGW_PARAM_MAX];
if (_gateway->getParam("AggregateGateway", param) == 0 ) if (_gateway->getParam("AggregatingGateway", param) == 0 )
{ {
if (!strcasecmp(param, "YES") ) if (!strcasecmp(param, "YES") )
{ {

View File

@@ -7,14 +7,14 @@ It is dual licensed under the EPL and EDL (see about.html and notice.html for mo
There are three sub-projects: There are three sub-projects:
1. MQTTSNPacket - simple de/serialization of MQTT-SN packets, plus helper functions 1. MQTTSNPacket - simple de/serialization of MQTT-SN packets, plus helper functions
2. MQTTGateway - MQTT-SN transparent gateway - connects MQTT-SN clients with an MQTT server. See the README within the project for more information. 2. MQTTGateway - MQTT-SN transparent/aggregating gateway - connects MQTT-SN clients with an MQTT server. See the README within the project for more information.
3. MQTTSNClient - high(er) level C++ client (not yet complete) 3. MQTTSNClient - high(er) level C++ client (not yet complete)
The *MQTTSNPacket* directory contains the lowest level C library with the smallest requirements. This supplies simple serialization The *MQTTSNPacket* directory contains the lowest level C library with the smallest requirements. This supplies simple serialization
and deserialization routines. They serve as a base for the higher level libraries, but can also be used on their own. and deserialization routines. They serve as a base for the higher level libraries, but can also be used on their own.
It is mainly up to you to write and read to and from the network. It is mainly up to you to write and read to and from the network.
The *MQTTSNGateway* directory contains an MQTT-SN to MQTT transparent gateway (see the MQTT-SN specification for a description of that.) It can The *MQTTSNGateway* directory contains an MQTT-SN to MQTT transparent/aggregating gateway (see the MQTT-SN specification for a description of that.) It can
be used to connect the MQTT-SN client to an MQTT server. be used to connect the MQTT-SN client to an MQTT server.
The *MQTTSNClient* directory contains the next level C++ library. This is intended to mirror the way the MQTTClient works in the Paho embedded The *MQTTSNClient* directory contains the next level C++ library. This is intended to mirror the way the MQTTClient works in the Paho embedded
@@ -45,3 +45,4 @@ Discussion of the Paho clients takes place on the [Eclipse Mattermost Paho chann
General questions about the MQTT protocol are discussed in the [MQTT Google Group](https://groups.google.com/forum/?hl=en-US&fromgroups#!forum/mqtt). General questions about the MQTT protocol are discussed in the [MQTT Google Group](https://groups.google.com/forum/?hl=en-US&fromgroups#!forum/mqtt).
More information is available via the [MQTT community](http://mqtt.org). More information is available via the [MQTT community](http://mqtt.org).