CN109714204A - A kind of LoRa terminal node and its configuration method - Google Patents

A kind of LoRa terminal node and its configuration method Download PDF

Info

Publication number
CN109714204A
CN109714204A CN201811610683.7A CN201811610683A CN109714204A CN 109714204 A CN109714204 A CN 109714204A CN 201811610683 A CN201811610683 A CN 201811610683A CN 109714204 A CN109714204 A CN 109714204A
Authority
CN
China
Prior art keywords
lora
instruction
node module
node
terminal
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201811610683.7A
Other languages
Chinese (zh)
Inventor
万能
刘斐斓
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Individual
Original Assignee
Individual
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Individual filed Critical Individual
Priority to CN201811610683.7A priority Critical patent/CN109714204A/en
Publication of CN109714204A publication Critical patent/CN109714204A/en
Pending legal-status Critical Current

Links

Landscapes

  • Mobile Radio Communication Systems (AREA)

Abstract

A kind of LoRa terminal node and its configuration method, which comprises the serial ports parameter of setting LoRa node module, externally to provide operation interface;The parameter that the LoRa node module is arranged in AT order is inputted under AT command mode;It after the LoRa node module has handled an AT order, returns one " OK " or " ERROR ", receives next AT instruction;Wherein, the LoRa node module is embedded or is external in the LoRa terminal node.LoRa terminal node provided in an embodiment of the present invention and its configuration method, it can be convenient configuration of the user to terminal node, enable terminal node to quickly access LoRa ad hoc network according to the demand of user, expand the application range of LoRa ad hoc network, improves the experience of user.

Description

A kind of LoRa terminal node and its configuration method
Technical field
The present invention relates to Lora technical field more particularly to a kind of LoRa terminal node and its configuration methods.
Background technique
LoRaWAN is a set of communications protocol and system architecture for the design of LoRa electric communication network.Lora communication system System generally comprises terminal, base station, network server, this four parts of application server.Star network is used between base station and terminal Network topology is able to due to the long range characteristic of LoRa, between them using single-hop transmission.Terminal node can be issued multiple simultaneously Forward process is then done to the LoRaWAN protocol data between network server and terminal in base station, base station, by LoRaWAN data point It has not been carried on LoRa radio frequency transmission and TCP/IP.
LoRa ad hoc network is the wireless access product based on LoRa/LoRaWAN technology, and user needs to connect using user terminal Enter LoRa ad hoc network to complete the communication with third-party application platform, but existing user terminal, a part is to list more early ratio More mature terminal, this Terminal Type need to carry out secondary development to terminal when accessing LoRa ad hoc network, and process is more troublesome, and And if user does not know the configuration order to terminal, it cannot achieve the configuration to terminal node, greatly reduce user experience, Affect the application range of LoRa ad hoc network.
Summary of the invention
In view of the drawbacks of the prior art, the present invention proposes a kind of LoRa terminal node and its configuration method, in this way, It can be convenient configuration of the user to terminal node, terminal node enabled to quickly access LoRa according to the demand of user from group Net expands the application range of LoRa ad hoc network, improves the experience of user.
According to an aspect of the present invention, the invention proposes a kind of configuration method of LoRa terminal node, the methods Include:
The serial ports parameter of LoRa node module is set, externally to provide operation interface;
The parameter that the LoRa node module is arranged in AT order is inputted under AT command mode;
It after the LoRa node module has handled an AT order, returns one " OK " or " ERROR ", receives next AT instruction;
Wherein, the LoRa node module is embedded or is external in the LoRa terminal node.
According to an aspect of the present invention, week is sent by the heartbeat message of LoRa terminal node described in AT instruction modification Phase.
According to an aspect of the present invention, all AT orders are using character string AT as prefix, and the character in order is using big Form is write, when using an AT order, using<carriage return><line feed>as terminating.
According to an aspect of the present invention, before the LoRa node module returns to one " OK " or " ERROR ", institute LoRa node module output Solicited echo message is stated, the Solicited echo message is that the LoRa node module exists When handling an AT instruction, the information relevant to AT instruction of return.
According to an aspect of the present invention, the format of the Solicited echo message has the following two kinds:
<enter><wrap>+ CMD1:<parameter><enter><wrap>
<carriage return><line feed>OK<carriage return><line feed>
Or
<enter><wrap><parameter><enter><wrap>
<carriage return><line feed>OK<carriage return><line feed>.
According to an aspect of the present invention, before the LoRa node module exports Solicited echo message, if The LoRa node module receives downlink message, then exports Unsolicited information, the Unsolicited information is for leading to Know that user has received data message.
According to an aspect of the present invention, the format of the unsolicited echo message is as follows:
<enter><wrap>+ MSG:<parameter><enter><wrap>.
According to an aspect of the present invention, the AT order include it is following at least one: send data command, read receive To data command, serial port baud rate modify instruction, the inquiry instruction that whether networks, software and hardware version number inquiry instruction, node mould Block instruction of restarting, factory configuration restore instruction.
According to an aspect of the present invention, the present invention also provides a kind of LoRa terminal node, the LoRa terminal nodes It include: user terminal and LoRa node module, the LoRa node module executes above-mentioned configuration method.
LoRa terminal node proposed by the present invention and its configuration method can be convenient configuration of the user to terminal node, make LoRa ad hoc network can be quickly accessed according to the demand of user by obtaining terminal node, expanded the application range of LoRa ad hoc network, mentioned The high experience of user.
By referring to the following drawings and to the detailed description of a specific embodiment of the invention, feature and advantage of the invention It will become apparent.
Detailed description of the invention
Fig. 1 is LoRa terminal node configuration method flow diagram of the invention;
Fig. 2 is LoRa node module configuration interface schematic diagram of the invention.
Specific embodiment
With reference to the attached drawing in the embodiment of the present invention, technical solution in the embodiment of the present invention carries out clear, complete Ground description, it is clear that described embodiments are only a part of the embodiments of the present invention, instead of all the embodiments.Based on this Embodiment in invention, every other reality obtained by those of ordinary skill in the art without making creative efforts Example is applied, shall fall within the protection scope of the present invention.
Unless otherwise defined, all technical and scientific terms used herein and belong to technical field of the invention The normally understood meaning of technical staff is identical.Term as used herein in the specification of the present invention is intended merely to description tool The purpose of the embodiment of body, it is not intended that in the limitation present invention.Term " and or " used herein includes one or more phases Any and all combinations of the listed item of pass.
Such as Fig. 1, the invention proposes a kind of configuration methods of LoRa terminal node, which comprises
The serial ports parameter of LoRa node module is set, externally to provide operation interface;
The parameter that the LoRa node module is arranged in AT order is inputted under AT command mode;
It after the LoRa node module has handled an AT order, returns one " OK " or " ERROR ", receives next AT instruction;
Wherein, the LoRa node module is embedded or is external in the LoRa terminal node.
Specifically, LoRaWAN node module externally provides operation interface in the form of serial ports, and serial ports default setting is 115200 (baud rates), 8 (data bit), 1 (stop position).There are two types of operating modes for the operation interface: AT command mode and data Transparent transmission mode.Under AT command mode, user can by the various AT of offer instruct setting terminal module all kinds of parameters (from And modify its behavior), sending and receiving for data can also be carried out.Under data penetration transmission mode, user can only pass through terminal mould Block carries out the transparent transmission transmitting-receiving of data, cannot carry out parameter setting to terminal module.
Fig. 2 is LoRa node module configuration interface schematic diagram of the invention.After terminal module powers on or restarts, default into Enter AT instruction mode, following character string will be got:
<carriage return><line feed>Cluing LoraWAN<carriage return><line feed>OK<carriage return><line feed>
Once user receives the above character string by serial ports, indicates terminal module start completion, enters AT instruction mode, It has been prepared for receiving and handling AT instruction.
Equipment starting after default enter AT command set mode, using CN470 preceding 8 channels from 470.3MHz to 471.7MHz.Default device belongs to CLASS_C, and is networked using ABP mode, works in AT command set mode.Serial ports connection ginseng Number is as follows, and baud rate can be set, with reference to AT+BAUDRATE order.
According to an aspect of the present invention, all AT orders are using character string AT as prefix, and the character in order is using big Form is write, when using an AT order, using<carriage return><line feed>as terminating.
Specifically, all AT orders must be using character string AT as prefix.And the character in AT order must be using big Write form.
When using an AT order, it is necessary to<carriage return><line feed>(namely r n, 0x0D0A) as terminating.
If not with any order after AT character, terminal module will return to " OK ".If AT character is with a nothing The order of effect, terminal module will return to " ERROR ".
According to an aspect of the present invention, week is sent by the heartbeat message of LoRa terminal node described in AT instruction modification Phase.
After LoRa node module networks, heartbeat message can be regularly sent, is divided between default time 20 seconds.It can be instructed by AT The time interval that heartbeat message is sent is modified, can also be configured by NS server.
According to an aspect of the present invention, before the LoRa node module returns to one " OK " or " ERROR ", institute LoRa node module output Solicited echo message is stated, the Solicited echo message is that the LoRa node module exists When handling an AT instruction, the information relevant to AT instruction of return.The format of the Solicited echo message has as follows Two kinds:
<enter><wrap>+ CMD1:<parameter><enter><wrap>
<carriage return><line feed>OK<carriage return><line feed>
Or
<enter><wrap><parameter><enter><wrap>
<carriage return><line feed>OK<carriage return><line feed>.
According to an aspect of the present invention, before the LoRa node module exports Solicited echo message, if The LoRa node module receives downlink message, then exports Unsolicited information, the Unsolicited information is for leading to Know that user has received data message.The format of the unsolicited echo message is as follows:
<enter><wrap>+ MSG:<parameter><enter><wrap>.
Specifically, after terminal module has handled an AT order, it can finally return that one " OK " or " ERROR ", Indicate that it can receive next AT instruction, it means that when terminal executes an AT order, in no return " OK " or Before " ERROR ", it will be unable to the new AT instruction of processing.Before final " OK " or " ERROR ", terminal module can To export the relevant Solicited echo message of some and current AT order.And Unsolicited information never occurs Between Solicited echo message and " OK " or " ERROR " that finally returns that.Here Solicited echo message we can To be interpreted as terminal module when handling an AT instruction, returns and the AT instructs relevant information.And Unsolicited information Similar notice or message, such as terminal module receive a downlink message, by Unsolicited information notify user or Host computer.
According to an aspect of the present invention, the AT order include it is following at least one: send data command, read receive To data command, serial port baud rate modify instruction, the inquiry instruction that whether networks, software and hardware version number inquiry instruction, node mould Block instruction of restarting, factory configuration restore instruction.
Specifically, the format of above-mentioned AT instruction and its parameter are as follows:
1、AT+SEND
The order is used to that LoRaWAN terminal module is called to send data.
Parameter declaration:
<time>: decimal system shape data, unit millisecond (ms)
0: expression needs to send data immediately;N: indicating using the time as interval, periodically transmission data.
When host computer calls the order to send message, it is proposed that only with sending mode immediately, not use periodicity sending Mode, periodicity sending mode are served only for the debugging of LoRaWAN terminal module.
<mode>: for the content format of expression parameter<data>." HEX ": indicate<data>content format be 16 into The format of serial data processed, that is, the format of HexToString.Such as need to send 16 binary data strings of 5 bytes: 0x11, 0x22,0x33,0xAA,0xEF.Changing into HexToStr format should be character string " 112233AAEF ".It is recommended that host computer uses When LoRaWAN terminal module, the transmission of message is carried out only with " HEX " mode." ASC ": indicate that<data's>to be sent is interior Hold the format that format is character string.Character string sending mode is served only for the debugging of LoRaWAN terminal module.
<port>: the specified AppPort port numbers for sending message and using.Value range 0~255.
<data>: the data to be sent, format are as described above.
<errno>: shaping, value range 1-255 indicate type of error.
2、AT+RECV
The order is used to read the data received from LoRaWAN terminal module.
Parameter declaration:
<size>: decimal system shape data indicates the length for the data that this is received.
0: no data need to receive;
<type>: type of message, 0: unicast;1: multicast;
<app_port>: expression receives the AppPort port numbers that data use, value range 0~255;
<data>: indicating the data received, unified to use HexToString, the form of 16 binary data strings.
<errno>: shaping, value range 1-255 indicate type of error.
3、AT+BAUDRATE
The order is used to be arranged and inquire the serial port baud rate of LoRaWAN module.Default data position 8, stop position 1. The order can only modify rate.After modifying baud rate, needs to restart module, can just come into force.
Parameter declaration:
<rate>: decimal system integer.
Serial port baud rate supports 9600,38400,57600,115200 this 4 kinds of baud rates;
<errno>: integer, value range 1-255 indicate type of error.
4、AT+JOINSTAT
Whether what the order was used to inquire LoRaWAN terminal module has been added to LoRaWAN network.
Parameter declaration:
<state>:
OFFLINE: network is not added;ONLINE: network has been added;
5、AT+VER
The order is used to inquire the software and hardware version number of LoRaWAN terminal module.
Parameter declaration:
<version>: character string, software and hardware version number
6、AT+REBOOT
The order, which is used to execute LoRaWAN terminal module, restarts.LoRaWAN relevant parameter is set up, is come into force if you need to parameter, It is generally necessary to actively restart module.
After module starting, company-information is printed at first, secondly prints banner string.
7、AT+DEFAULTCFG
The order is used to restore the factory default configuration of LoRaWAN terminal module.
According to an aspect of the present invention, the present invention also provides a kind of LoRa terminal node, the LoRa terminal nodes It include: user terminal and LoRa node module, the LoRa node module executes above-mentioned configuration method.
According to another aspect of the present invention, the present invention also provides a kind of LoRa terminal node, the LoRa terminal sections Point includes: user terminal and LoRa node module, and the LoRa node module executes configuration method as described above.
LoRa terminal node proposed by the present invention and its configuration method can be convenient configuration of the user to terminal node, make LoRa ad hoc network can be quickly accessed according to the demand of user by obtaining terminal node, expanded the application range of LoRa ad hoc network, mentioned The high experience of user.
The above description is only a preferred embodiment of the present invention, is not intended to limit the scope of the invention, all at this Under the design of invention, using equivalent structure transformation made by description of the invention and accompanying drawing content, or directly/it is used in it indirectly He is included in scope of patent protection of the invention relevant technical field.

Claims (9)

1. a kind of LoRa terminal node and its configuration method, which is characterized in that the described method includes:
The serial ports parameter of LoRa node module is set, externally to provide operation interface;
The parameter that the LoRa node module is arranged in AT order is inputted under AT command mode;
It after the LoRa node module has handled an AT order, returns one " OK " or " ERROR ", receives next AT Instruction;
Wherein, the LoRa node module is embedded or is external in the LoRa terminal node.
2. the method according to claim 1, wherein passing through the heartbeat of LoRa terminal node described in AT instruction modification Message sending cycle.
3. the method according to claim 1, wherein all AT orders are using character string AT as prefix, in order Character use patterns of capitalization, when using an AT order, using<carriage return><line feed>as terminating.
4. the method according to claim 1, wherein the LoRa node module return one " OK " or Before " ERROR ", the LoRa node module exports Solicited echo message, and the Solicited echo message is described LoRa node module is when handling an AT instruction, the information relevant to AT instruction of return.
5. according to the method described in claim 4, it is characterized in that, the format of the Solicited echo message has following two Kind:
<enter><wrap>+ CMD1:<parameter><enter><wrap>
<carriage return><line feed>OK<carriage return><line feed>
Or
<enter><wrap><parameter><enter><wrap>
<carriage return><line feed>OK<carriage return><line feed>.
6. the method according to claim 1, wherein being responded in LoRa node module output Solicited Before information, if the LoRa node module receives downlink message, Unsolicited information is exported, it is described Unsolicited information is for notifying user to have received data message.
7. according to the method described in claim 6, it is characterized in that, the format of the unsolicited echo message is as follows:
<enter><wrap>+ MSG:<parameter><enter><wrap>.
8. the method according to claim 1, wherein the AT order include it is following at least one: send data Instruction, read the data command received, serial port baud rate modification instruction, the inquiry instruction that whether networks, software and hardware version number look into Ask instruction, node module instruction of restarting, factory configuration recovery instruction.
9. a kind of LoRa terminal node, which is characterized in that the LoRa terminal node includes: user terminal and LoRa node mould Block, the LoRa node module execute such as the described in any item configuration methods of claim 1-8.
CN201811610683.7A 2018-12-28 2018-12-28 A kind of LoRa terminal node and its configuration method Pending CN109714204A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811610683.7A CN109714204A (en) 2018-12-28 2018-12-28 A kind of LoRa terminal node and its configuration method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811610683.7A CN109714204A (en) 2018-12-28 2018-12-28 A kind of LoRa terminal node and its configuration method

Publications (1)

Publication Number Publication Date
CN109714204A true CN109714204A (en) 2019-05-03

Family

ID=66258750

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811610683.7A Pending CN109714204A (en) 2018-12-28 2018-12-28 A kind of LoRa terminal node and its configuration method

Country Status (1)

Country Link
CN (1) CN109714204A (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105721438A (en) * 2016-01-19 2016-06-29 烽火通信科技股份有限公司 LTE gateway processing AT instruction method based on Linux

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105721438A (en) * 2016-01-19 2016-06-29 烽火通信科技股份有限公司 LTE gateway processing AT instruction method based on Linux

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
JENNY LIUJUNY: "《LoraWAN模块AT指令使用手册》", 《HTTPS://WWW.DOCIN.COM/P-2027293168.HTML》 *
佚名: "《Lora模块参数配置说明书》", 《HTTPS://JINGYAN.BAIDU.COM/ARTICLE/0AA2237578A4FF88CC0D64C4.HTML》 *

Similar Documents

Publication Publication Date Title
CN108513283A (en) One kind matching network method, equipment, terminal, medium and computer equipment
CN104883656B (en) A kind of method and its system for setting up stable state piconet based on bluetooth
WO2020125168A1 (en) Heartbeat packet-based data sending and receiving method, and storage medium and processor
CN105450489A (en) HEBus efficient fieldbus system for preferably realizing shortest message in output and communication method
CN113437998B (en) Operation and maintenance debugging method and system, nonvolatile storage medium and processor
CN107409270B (en) Method and apparatus for establishing a connection between devices
CN107820262B (en) Parameter configuration method, device and system
CN108494816A (en) Data transmission method, system, equipment based on LPWAN and readable storage medium storing program for executing
CN108012250A (en) Data transmission method and data transmission device
CN103685530A (en) Automatic upgrade control method and system for WLAN current network APs
CN112751937A (en) Distributed edge intelligent Bluetooth Mesh gateway system and implementation method
CN112202877A (en) Gateway linkage method, gateway, cloud server and user terminal
JP6432294B2 (en) COMMUNICATION SYSTEM, COMMUNICATION SYSTEM CONTROL METHOD, AND PROGRAM
CN111245660B (en) Network-based equipment upgrading self-adaptive transmission method
CN109714204A (en) A kind of LoRa terminal node and its configuration method
CN104852835A (en) Smart device WIFI communication system and control method thereof
CN110149398B (en) User management method for intelligent door lock of intelligent home
CN107181614B (en) Wifi network, networking method thereof and data transmission method
CN107071921A (en) A kind of terminal equipment control method and system based on wireless management frame
JP7447263B2 (en) Network structures and methods for transmitting/receiving packets between network elements within a network
CN105338195A (en) Terminal power saving method and terminal
CN105871635B (en) The method that a kind of multiple WIFI module parameters in local area automatically configure
CN101932143B (en) Method for starting self-configuration of evolution Remote Radio Unit
CN106658532A (en) Multi-subnode large-scale networking method based on 2.4GHz wireless technology
CN111447270A (en) Data forwarding middleware for Internet of things

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
TA01 Transfer of patent application right
TA01 Transfer of patent application right

Effective date of registration: 20200731

Address after: 518000 Tianxin automobile life center, 46 Meilin Road, Maling community, Meilin street, Futian District, Shenzhen City, Guangdong Province

Applicant after: Lingxi industrial Internet (Shenzhen) Co., Ltd

Address before: Wujiang District of Suzhou City, Jiangsu province 215211 Lili town FENHU Road No. 558

Applicant before: Wan Neng

WD01 Invention patent application deemed withdrawn after publication
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20190503