The technical principle of LoRaWAN and its application in water,electricity and gas

April 25, 2023
Latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas

The technical principle of LoRaWAN and its application in water,electricity and gas

With the gradual development of the Internet of Things, many applications of the Internet of Things have small data packets and a high tolerance for delay, which requires a wide range of deployment, or are located in remote, basement, underground and other places with serious shielding. It is not easy for existing wireless communication or mobile communication technology to transmit signals.The communication technology with long distance and low power consumption developed in response to the above situation is collectively called Low Power Wide Area Network (LPWAN).

LPWAN has the advantages of low power consumption, long distance and super large number of connections, so it is suitable for applications requiring large-scale deployment and small amount of data transmission. This feature is very consistent with the application requirements of intelligent energy meter information acquisition.LPWAN can be divided into two camps according to the frequency band used: authorized frequency band and non authorized frequency band. The development of non authorized frequency band LPWAN technology is earlier, and the main technology is LoRaWAN.

Introduction to LoRaWAN

LoRaWAN is a set of communication protocol and system architecture designed for LoRa long-distance communication network.It defines how data is transmitted in the LoRaWAN network (the network here refers to nodes, gateways, and servers), defines the type of messages, data frame structure, and security encryption methods, introduces the specific operation of network access, and explains the difference between master and slave computers.

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  0

LoRaWAN fully considers several factors such as node power consumption, network capacity, security and network application diversity in the design of protocol and network architecture.

LoRaWAN network architecture

The following is the network architecture of LoRa:

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  1

A LoRaWAN network architecture includes four parts: terminal, gateway, network server and application server.Star and cellular network topologies are used between gateway and terminal. Due to the long-distance characteristics of LoRa, single hop transmission can be used between them.The terminal node can send to multiple gateways at the same time. The gateway forwards the LoRaWAN protocol data between the NS and the terminal, transmits the LoRaWAN data between the terminal and the gateway through LoRa radio frequency, and transmits the LoRaWAN data between the gateway and the network server through TCP/IP protocol.

Overview of LoRaWAN protocol

1、Classification of terminal nodes

In terms of technical specifications, the LoRaWAN transmission rate is about 30bit/s-50kbit/s, the transmission distance is about 2-5km in urban areas and up to 15km in suburban areas. It supports two-way transmission. The transmission modes can be divided into Baseline (Class A), Beacon (Class B) and Continuous (Class C) according to the delay requirements and power consumption,The Class A mode can only be transmitted when the terminal device sends a request, with the lowest power consumption, and is used in water meters and gas meters;Class C is the continuous transmission of data with the shortest transmission delay. Class C is generally used in electricity meters.

2、Uplink and downlink transmission of terminal node

This is the sequence diagram of the uplink and downlink of Class A. At present, RX1 of the receive window generally starts 1 second after the uplink, and RX2 of the receive window starts 2 seconds after the uplink.

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  2

Class C and A are basically the same, except that when Class A sleeps, it opens the receive window RX2.

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  3

3、Networking of terminal nodes

There are two screening modes for terminal network access: Over the Air Activation (OTAA) and Activation by Personalization (ABP).

Commercial LoRaWAN networks generally follow the OTAA activation process, so that security can be guaranteed.In this way, DevEUI, AppEUI, and AppKey parameters need to be prepared.

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  4

DevEUI is a globally unique ID similar to IEEE EUI64, which identifies a unique terminal device.It is equivalent to the MAC address of the device.

AppEUI is a globally unique ID similar to IEEE EUI64, which identifies a unique application provider

AppKey is assigned to the terminal by the application owner. It needs to be configured on the network server and burned on the corresponding terminal.

After the terminal initiates the join process, it issues the networking command. After the NS (network server) confirms that there is no error, it will make a networking reply to the terminal and assign the network address DevAddr (32-bit ID). Both parties use the relevant information in the networking reply and the AppKey to generate the session keys NwkSKey and AppSKey, which are used to encrypt and verify data.NwkSKey is stored on the network server for communication between the network server and the terminal;AppSKey is saved in the application server for communication with the network server.

If the second screening method, ABP activation, is used, the three final LoRaWAN communication parameters DevAddr, NwkSKey, and AppSKey are configured directly, and the join process is no longer required.In this case, the device can send application data directly.Due to the lack of two-way authentication, illegal terminals may access the network or be induced by pseudo base stations.Therefore, in general, commercial projects use the OTAA activation process.

4、Data receiving and sending

After accessing the network, the application data is encrypted using AES128 bit encryption algorithm.The following figure shows the security mechanism of each part in the communication process:

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  5

Network servers and terminal nodes use MIC verification to ensure correctness.MIC verification uses AES-CMAC algorithm, including frame count (to prevent retransmission attacks) and NwkSKey (to prevent packet tampering), and uses AppSKey encryption to encrypt user data (as shown in the figure below)

 

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  6

 

LoRaWAN specifies two types of data frames: Confirmed or Unconfirmed, that is, the type that requires a response and the type that does not require a response.The manufacturer can select the appropriate type according to the application needs.

In addition, we can see from the introduction that one of the major considerations of LoRaWAN design at the beginning is to support application diversity.In addition to using AppEUI to divide applications, FPort application ports can also be used to process data separately during transmission.The value range of FPort is (1~223), which is specified by the application layer.

5、ADR mechanism

LoRa modulation has spread spectrum factor, and different spread spectrum factors will have different transmission distance and transmission rate, and will not affect data transmission.

In order to expand the capacity of the LoRaWAN network, a LoRa adaptive data rate - ADR mechanism is designed on the protocol. Devices with different transmission distances will use the fastest data rate as possible according to the transmission situation.This also makes the overall data transmission more efficient.

LORAWAN Features

LoRaWAN is characterized by wireless transmission, strong anti-interference ability, encrypted communication, wide coverage, low power consumption, large connection and low cost.

Long distance: Thanks to the gain of spread spectrum modulation and forward error correction code, LoRa achieves about twice the communication distance of cellular technology.

Large capacity: There are many nodes in the Internet of Things. A LoRaWAN network can easily connect tens of thousands of nodes.

Easy capacity expansion: When a LoRaWAN network needs to increase capacity, you can add gateways.

Security: LoRaWAN is a double encrypted Internet of Things.It is suitable for information application of water and electricity meters.

Technical indicators of gateway and module

1、gateway

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  7

Intelligent gateway G200 (indoor)

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  8

 

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  9

Intelligent gateway G500 (outdoor)

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  10

2. LoRaWan module

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  11

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  12

Measured data

1、Pull distance test

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  13

At a straight-line distance of 3.7KM from the test site, the signal strength is - 94, the signal to noise ratio is - 6.0, and the data packets of the internal antenna and external antenna are normal.

2、In building penetration test

The gateway is installed in the surface well on the 15th floor of Building 4 in a community

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  14

 

In the data in the table above, the signal strength is more than - 100dbm (far more than the module's receiving sensitivity limit of - 139dbm), and the signal-to-noise ratio is more than - 10, which can achieve two-way reliable communication. Therefore, if the gateway is placed on the 15th floor, the signal coverage of the whole building on the 32nd floor can be achieved.

3、Data upload success rate test

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  15

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  16

From the above test data, we can see that 120 tables can upload data within 3 minutes, with an average success rate of more than 99%.

4、conclusion

(1) The use of built-in antenna in the city can ensure normal communication within 2-3km, and the use of external directional antenna can achieve a longer distance.

(2) The signal can penetrate 10-15 floors.

(3) One 8-channel half duplex gateway can ensure 120 meters to complete reliable data transmission within 3 minutes.If a 16 channel half duplex gateway is used, the data of more than 200 meters can be reliably transmitted.

7、 Application case

This case is a large park in Turkmenistan, which gathers a series of infrastructures such as office buildings, residences, sports venues and shops.It is about 2.3km wide and 4.3km long.

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  17

The red dot indicates the location of the gateway

 

This is a large park, which uses the following Internet of Things devices:

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  18

As can be seen from the above data, the park not only uses many types of IoT devices, but also a large number.With LoRaWan technology, the frequency band is 864-865MHz customized for it. 55 smart gateways G200 (indoor) and 55 smart gateways G500 (outdoor) are used to complete the access networking of all devices. At the same time, one network server can receive the data transmitted by all devices and perform efficient processing.

The overall system architecture used in the case is shown in the following figure:

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  19

 

All the equipment and services in this case are deployed locally in the customer's campus in an integrated manner, which can ensure the security and privacy of data transmitted by all equipment.

If customers need, they can also deploy the network server, access platform or application platform in the cloud, or directly use the existing application platform to obtain and process data through docking with the access platform.

The application platform can provide various services required by customers for different devices according to the data collected by different devices:

latest company news about The technical principle of LoRaWAN and its application in water,electricity and gas  20