Milesight UC100 User manual

IoT Controller
Featuring LoRaWAN®
UC100
User Guide

2
Safety Precautions
Milesight will not shoulder responsibility for any loss or damage resulting from not following the
instructions of this operating guide.
The device must not be remodeled in any way.
Do not place the device close to objects with naked flames.
Do not place the device where the temperature is below/above the operating range.
Power off the device when installing or wiring.
Make sure electronic components do not drop out of the enclosure while opening.
The device must never be subjected to shocks or impacts.
Declaration of Conformity
UC100 is in conformity with the essential requirements and other relevant provisions of the CE,
FCC, and RoHS.
Copyright © 2011-2024 Milesight. All rights reserved.
All information in this guide is protected by copyright law. Whereby, no organization or individual
shall copy or reproduce the whole or part of this user guide by any means without written
authorization from Xiamen Milesight IoT Co., Ltd.
For assistance, please contact
Milesight technical support:
Email: iot.support@milesight.com
Support Portal: support.milesight-iot.com
Tel: 86-592-5085280
Fax: 86-592-5023065
Address: Building C09, Software Park III,
Xiamen 361024, China

3
Revision History
Date
Doc Version
Description
May 27, 2022
V 1.0
Initial version
Dec. 5, 2022
V 1.1
Add active pass-through feature and two-way
pass-through feature on RS485
Jan 24, 2024
V 1.2
1. Add data storage and retransmission feature
2. Increase to 32 Modbus channels
3. Add downlink commands to configure Modbus
channels
4. Add Modbus channel alarm feature

4
Contents
1. Product Introduction......................................................................................................................... 5
1.1 Overview ...................................................................................................................................5
1.2 Features ................................................................................................................................... 5
2. Hardware Introduction ...................................................................................................................... 5
2.1 Packing List ..............................................................................................................................5
2.2 Hardware Overview ................................................................................................................. 6
2.3 LED and Reset Button ..............................................................................................................6
2.4 Dimensions (mm) .................................................................................................................... 6
3. Device Installation ............................................................................................................................. 6
4. Operation Guide .................................................................................................................................7
4.1 Log in the ToolBox ...................................................................................................................7
4.2 LoRaWAN Settings .................................................................................................................. 8
4.3 General Settings .................................................................................................................... 11
4.4 RS485 Settings ...................................................................................................................... 12
4.5 IF-THEN Command ............................................................................................................... 15
4.6 Milesight D2D Settings..........................................................................................................17
4.7 Data Storage .......................................................................................................................... 19
4.8 Data Retransmission .............................................................................................................20
4.9 Maintenance .......................................................................................................................... 21
4.9.1 Upgrade ....................................................................................................................... 21
4.9.2 Backup .........................................................................................................................22
4.9.3 Reset to Factory Default .............................................................................................23
5. Device Payload ................................................................................................................................ 23
5.1 Device Information ................................................................................................................ 23
5.2 Modbus Channel Data ...........................................................................................................24
5.3 Modbus Channel Alarm ........................................................................................................ 26
5.4 Downlink Command .............................................................................................................. 27
5.5 Historical Data Enquiry ..........................................................................................................29

5
1. Product Introduction
1.1 Overview
UC100 is an IoT controller used for remote control and data acquisition from Modbus RS485
devices via LoRaWAN®networks. It can read up to 32 Modbus RTU devices and support Modbus
transparent transmission between server and RS485 devices as a Modbus to LoRaWAN®
converter. Besides, UC100 supports multiple trigger conditions and actions which can work
autonomously even when the network drops.
1.2 Features
Easy to connect with diverse wired sensors through RS485 interfaces
Support LoRaWAN®wireless communication
Multiple triggering conditions and actions
Embedded watchdog for work stability
Industrial metal case design with a wide operating temperature range
Compliant with standard LoRaWAN®gateways and network servers
Quick and easy management with Milesight IoT Cloud solution
2. Hardware Introduction
2.1 Packing List
1 × Quick Guide
If any of the above items are missing or damaged, please contact your sales representative.
1 × UC100 Device
1 × Type-C Cable
& Power Adapter
1 × Terminal
Block
2 × Wall Mounting
Kits

6
2.2 Hardware Overview
120Ω Terminal Resistor Switch: the device will add a 120Ω termination resistor to avoid
data-corrupting reflections if RS485 data rate is high or cable length is long.
2.3 LED and Reset Button
The reset button is inside the device.
Function
Action
LED Indication
Work Status
System is functioning properly
Static On
Fail to acquire data from data interfaces
Slowly Blinks
Device upgrade or system error
Static On
Reboot
Press and hold the button for more than 3 seconds.
Slowly Blinks
Reset
Press and hold the button for more than 10 seconds.
Quickly Blinks
2.4 Dimensions (mm)
3. Device Installation
UC100 device can be placed on a desktop or mounted to a wall.
1. Take off the back cover of UC100 device, and fix the wall plugs into the wall according to the
drilling position as referred.

7
2. Screw the cover on the mounting positions and install back the device.
4. Operation Guide
4.1 Log in the ToolBox
1. Download ToolBox software from Milesight website.
2. Power on the UC100 device, then connect it to computer via the type-C port.
3. Open the ToolBox and select type as General, then click password to log in ToolBox. (Default
password: 123456)

8
4. After logging in the ToolBox, you can change device settings.
4.2 LoRaWAN Settings
LoRaWAN settings are used for configuring the transmission parameters in LoRaWAN®network.
Basic LoRaWAN Settings:
Configure join type, App EUI, App Key and other information. You can also keep all settings by
default.

9
Parameters
Description
Device EUI
Unique ID of the device on the label.
App EUI
Default App EUI is 24E124C0002A0001.
Application Port
The port is used for sending and receiving data, the default port is 85.
Working Mode
Fixed as Class C.
Join Type
OTAA and ABP modes are available.
Application Key
Appkey for OTAA mode, default is 5572404C696E6B4C6F52613230313823.
Device Address
DevAddr for ABP mode, default is the 5th to 12th digits of SN.
Network Session
Key
Nwkskey for ABP mode, default is 5572404C696E6B4C6F52613230313823.
Application
Session Key
Appskey for ABP mode, default is 5572404C696E6B4C6F52613230313823.
RX2 Data Rate
RX2 data rate to receive downlinks or send/receive D2D commands.
RX2 Frequency
RX2 frequency to receive downlinks or send/receive D2D commands. Unit: Hz
Spread Factor
If ADR is disabled, the device will send data via this spread factor.
Confirmed Mode
If the device does not receive ACK packet from network server, it will resend
data once.

10
Rejoin Mode
Reporting interval ≤ 35 mins: the device will send a specific number of
LinkCheckReq MAC packets to the network server every reporting interval or
every double reporting interval to validate connectivity; If there is no response,
the device will re-join the network.
Reporting interval > 35 mins: the device will send a specific number of
LinkCheckReq MAC packets to the network server every reporting interval to
validate connectivity; If there is no response, the device will re-join the
network.
Set the number of
packets sent
When rejoin mode is enabled, set the number of LinkCheckReq packets sent.
ADR Mode
Allow the network server to adjust datarate of the device.
Tx Power
The transmit power of device.
Note:
1) Please contact sales for device EUI list if there are many units.
2) Please contact sales if you need random App keys before purchasing.
3) Select OTAA mode if you use Milesight IoT Cloud to manage devices.
4) Only OTAA mode supports rejoin mode.
LoRaWAN Frequency Settings:
Go to LoRaWAN Settings > Channel to select supported frequency and select channels to send
uplinks. Make sure the channels match what you set in the LoRaWAN®gateway.

11
If the frequency is one of CN470/AU915/US915, enter the index of the channel that you want to
enable in the input box, making them separated by commas.
Examples:
1, 40: Enabling Channel 1 and Channel 40
1-40: Enabling Channel 1 to Channel 40
1-40, 60: Enabling Channel 1 to Channel 40 and Channel 60
All: Enabling all channels
Null: Indicates that all channels are disabled
4.3 General Settings
Parameters
Description
Device ID
Show the SN of the device.
Reporting Interval
Reporting interval of transmitting Modbus channel data to the network
server. Range: 1-1080 mins, default: 20 mins
Data Storage
Disable or enable reporting data storage locally.

12
Data
Retransmission
Disable or enable data retransmission.
D2D
Enable or disable Milesight D2D Feature.
D2D Key
Set a unique key the same as the setting in Milesight D2D controller or
agent device. The default is 5572404C696E 6B4C6F52613230313823.
Change Password
Change the password to log in ToolBox.
4.4 RS485 Settings
UC100 supports to set up communications with RS485 via two ways: Modbus channels or
Modbus RS485 bridge LoRaWAN®.
Basic Serial Settings:
UC100 has one RS485 port for Modbus RTU device connection. The basic serial settings should
be the same as RS485 terminal devices.
Parameters
Description
Stop Bit
1 bit/2 bit is available.
Data Bit
8 bit is available.
Parity
None, Odd and Even are available.
Baud Rate
1200/2400/4800/9600/19200/38400/57600/115200 are available.
Execution Interval
(ms)
The execution interval between each Modbus channel command.
Max Resp Time
The maximum response time that the UC100 waits for the reply to the

13
(ms)
command. If it does not get a response after the max response time, it is
determined that the command has timed out.
Max Retry Times
Set the maximum retry times after the device fails to read data from RS485
terminal devices.
Modbus Channels:
UC100 supports to work as a Modbus RTU Client (Master) to poll the data from the RS485
device and return the data to the network server.
Click to add Modbus channels, then save configurations.
Parameters
Description
Channel ID
Select the channel ID you want to configure from 32 channels.
Name
Customize the name to identify every Modbus channel.
Slave ID
Set a Modbus slave ID of a terminal device.
Address
The starting address for reading.
Quantity
Set read how many digits from the starting address, it fixes to 1.
Type
Select the data type of Modbus channels.
Byte Order
Set the Modbus data reading order if you configure the type as Input register
or holding register.
INT32/Float: ABCD, CDBA, BADC, DCBA
INT16: AB, BA
Sign
The tick indicates that the value has a plus or minus sign.
Fetch
Click to send a Modbus read command to test if the RS485 device can reply
with the correct values. Note that do not click frequently to avoid the fetch
failure due to the slow response of RS485 devices.
Example: as this setting, the device will send command: 01 03 00 00 00 01
84 0A

14
Modbus RS485 bridge LoRaWAN®:
UC100 supports to work as a relay to set up the communication between the server and RS485
devices. There are two pass-through modes:
Active Pass-through: the network server can send any command to the RS485 device and the
RS485 device can only react according to server commands.
Two-way Pass-through: not only can network server send any command to the RS485 device,
but also the RS485 device supports transmitting the data to the network server actively.
Note: When Two-way Pass-through is enabled, Modbus channels can’t be used and the
corresponding IF-THEN command will not work.
Parameters
Description
Modbus RS485
bridge LoRaWAN®
Enable or disable the Modbus RS485 bridge LoRaWAN®feature.
Pass-through
Mode
Select from Active Pass-through or Two-way Pass-through.
Port
The communication port between the RS485 device and the network server.
Range: 2-84, 86-223.

15
4.5 IF-THEN Command
UC100 supports configuring locally IF-THEN commands to do some actions automatically even
without a network connection. One device can be added 16 commands at most.
1. Go to the Command page, and click “Edit” to add commands.
2. Set an IF condition based on the terminal device data or UC100 device status.
Condition
Description
Channel
When the value of a Modbus channel, reaches the condition.
For coil/discrete type, the condition is False/True;
For other types, the condition is Above/Below/Within/Change.
Is continued for: the threshold value should last for some time.

16
Set lockout time: after the lockout time, UC100 will check if the value still
reaches the threshold and matches the condition. 0 means this condition will
only be detected once.
The time interval of value change: the change value should last for some time.
Note: The parameter will be hidden if you enable Two-way Pass-through
feature.
Received a
Milesight D2D
control
command
This only works with the Milesight D2D feature is enabled.
3. Set THEN action according to your request. You can add at most 3 actions in one command.
Action
Description
Report a threshold
packet
Report as threshold alarm packet to network server when the value of
selected Modbus channel value reaches the threshold.
Report a packet on
shift change
Report as change alarm packet to network server when the value of
selected Modbus channel value changes a specific range.
Send a LoRaWAN®
message
Send a custom message to the network server.
Restart the Device
Reboot the device.
Send a Milesight
D2D control
command
This only works with Milesight D2D feature is enabled.
Send a Modbus
command via the
RS485 interface
Send a Modbus RTU command to the RS485 device.

17
4.6 Milesight D2D Settings
Milesight D2D protocol is developed by Milesight and used for setting up transmission among
Milesight devices without a gateway. When the Milesight D2D setting is enabled, UC100 can
work as a Milesight D2D controller to send control commands to other devices or work as a
Milesight D2D agent to receive commands to trigger a reboot or message to the network server.
1. Go to General > Basic page, enable Milesight D2D feature and define a unique Milesig
ht D2D key which is the same as Milesight D2D controller or agent devices. (Default Mil
esight D2D Key: 5572404C696E6B4C6F52613230313823)
2. Go to LoRaWAN Settings > Basic to configure the RX2 datarate and RX2 frequency. When
UC100 works as Milesight D2D controller, it will send commands as RX2 settings.

18
3. Go to Command page to set corresponding operations.
When the RS485 channel triggers, UC100 can work as Milesight D2D controller to send a control
command to control the Milesight D2D agent device. The command should be a 2-byte
hexadecimal number.
When UC100 receives a Milesight D2D command, it can work as a Milesight D2D agent to reboot
the device, send a LoRaWAN®message or send Modbus command to RS485 terminal devices.

19
4.7 Data Storage
UC100 supports storing 1000 pieces of data locally and export data via ToolBox. The device will
record the data according to reporting interval even not joining to network.
1. Go to Status page to click Sync to sync the device time or select LoRaWAN®version as 1.0.3
to enquire the time from network server when joining network.
2. Go to General > Basic to enable data storage feature.
3. Go to Maintenance > Backup and Reset , click Export to select the data time period and click
Save to export data.

20
4. Click Clear to clear all stored data inside the device as required.
4.8 Data Retransmission
UC100 supports data retransmission to ensure the network server can get all data even if
network is down for some times. There are two ways to get the lost data:
Network server sends downlink commands to enquire the historical data for specifying time
Other manuals for UC100
2
Table of contents
Other Milesight Controllers manuals

Milesight
Milesight UC100 User manual

Milesight
Milesight UC100-868M User manual

Milesight
Milesight UC50 Series User manual

Milesight
Milesight UC300 User manual

Milesight
Milesight UC500 Series User manual

Milesight
Milesight UC51 Series User manual

Milesight
Milesight UC300 User manual

Milesight
Milesight UC50 Series User manual

Milesight
Milesight UC50 Series User manual

Milesight
Milesight WS558 User manual