Milesight IoT Cloud supports simply calculations including addition, subtraction, multiplication, and division on controller RS485 values. Simply, a variable is any raw data within a channel in Milesight IoT Cloud. The final value is a variable that results from the standard-based computation of other variables within Milesight IoT Cloud. This function is very useful to extend your application’s functionality.

This article explains how and when to use a formula on Milesight IoT Cloud formula setting to execute calculations.


  • Milesight LoRaWAN Controller: UC50X Series/UC11XX/UC11-N1
  • Milesight LoRaWAN Gateway: work as network server
  • RS485 terminal device: Temperature and Humidity Sensor


Develop a Temperature and Humidity Sensor that reads the register value, then simple calculations are needed for the register value to get the accurate value in the end.

Take Temperature and Humidity Sensor in this kit as an example, it can calculate and convert temperature and humidity based on the following formulas:

Soil Temperature = x/10

Soil Humidity = x/10

  1. Connect RS485 terminal device to LoRaWAN Controller.
  2. Connect Milesight LoRaWAN gateway to Milesight IoT Cloud, please refer to this article: How to Connect Milesight Gateway to Milesight IoT Cloud
  3. Connect Milesight Controller to Milesight IoT Cloud.
  4. Create Modbus channels via ToolBox.
  5. Create Modbus channels in Milesight IoT Cloud.
  • Go to My devices -> Devices, click Settings
  • Go to Devices -> Basic Settings -> Interface Settings to create channels. The settings should be the same as ToolBox.6. Enter the Formula According to the User Manual of the Sensor.
  • If you wish to convert temperature from °C to °F, you need to implement the function below:

    1.8* x+ 32 => 1.8*(x/10) + 32


                                                                                      ----END- --