Description

Milesight LoRaWAN gateways support sending data packets to third party MQTT/HTTP/HTTPS server. We can create a new application on gateway, which can define the method of decoding the data sent from LoRaWAN end-device and choosing HTTP(S) data transport protocol to send data to HTTP(s) server.


Requirement

  • Milesight LoRaWAN Gateway: UG6x, UG8x
  • HTTP/HTTPS Server


Configuration

Step1. Enable the gateway built-in network server.

Go to Packet Forwarder > General to enable the localhost server address.

Enable the Network server on Network Server > General page.


Step2. Add an Application and Profiles.

Go to Network Server > Applications to add a new application, then click save.

Name: user-defined, arbitrary value

Description: user-defined, arbitrary value

Payload Codec: None or custom your decoder

Go to Network Server>Profiles to add a new profile, then click save.

Name: user-defined, arbitrary value

Max TXPower: default value

Other parameters can be checked from LoRaWAN nodes user guides or you can keep all settings by default.


Step3. Add LoRaWAN nodes to the gateway.

Go to Network Server > Device, add a new device, click save&apply.

Device Name: user-defined, arbitrary value

Description: user-defined, arbitrary value

Device-Profile: choose one of corresponding profiles added before.

Application: choose one of corresponding applications added before.

Other values can be confirmed with the LoRaWAN node manufacturers.


When the status of it is “activated”, that’s mean above steps are done correctly.


Step4. Forward data to HTTP(s) server.

Go to Network Server > Applications to add a “data transmission” for the application.

Fill in the HTTP(s) URL information for each data type, click save.

Uplink data: the URL address to receive all uplink data.

Join notification: the URL address to receive join notification.

ACK notification: the URL address to receive all ACK notification.

Error notification: the URL address to receive all error notification.

Note: If there is user credentials when we access to HTTP(s) server, please add HTTP header, and fill in correct account and password.

If we get data packet on the corresponding URL of HTTP server like below, that’s mean we have connected with HTTP server successfully.

Note: The difference of forwarding data to HTTPS server is that you need upload related gateway certification on your HTTPS server (Contact Milesight to get certification).


FAQ

Q1. Why did the server not receive the data sent by the gateway?

A1: Go to Maintenance > Tools > Ping, confirm the gateway can ping to the HTTP address you filled in successfully like below, then check all of above values filled in are correct.


Q2. How to send decoded data packet to HTTP/HTTPS server?

A2: Refer to How to Use Payload Codec on Milesight Gateway.