WS201 – Configurable Properties
You can update a device's settings by modifying the configurable properties of its TSL model via API. This topic provides the configurable parameters for WS201 TSL model, their descriptions, and how to use them.
Usage
- Have an overview of the configurable properties and their default values of WS201.
- Copy the example code and remove the comments and parameters that do not require modification.
- Edit the desired properties according to the detailed properties
description.Note: Make sure that the edited example code complies with the JSON format requirements.
- Use the edited example code as the body parameters of Update Device Properties Incrementally.
Configurable properties
- Click a property to view its detailed description and valid values.
- Configure the example code as needed, then use it as the body parameters of Update Device Properties Incrementally to save time and effort.
{
"properties": {
"reporting_interval": 64800, // The interval for data reporting (second).
"sleep_setting":{ // Device hibernate settings.
"enable": true,
"start_time": 1320, // Hibernate start time is 22:00.
"end_time": 540, // Hibernate start time is 9:00.
"monday": true
},
"depth_setting": 500, // The distance from bottom of container to sensor(mm).
"collecting_interval": 1800, // The interval for data collecting (second).
"alarm1": { // Threshold alarm 1 settings.
"enable": true,
"value": 30,
"disable": false
},
"time_zone": 0 // Set UTC / Western European Time as the device's time zone.
}
}
Description
The following table provides the description and valid values for the configurable properties of WS201.
Parameter | Type | Description | |
---|---|---|---|
reporting_interval | Integer |
Specify the interval for data reporting (Unit: Second).
|
|
sleep_setting | Struct | Device hibernate settings. | |
enable | Boolean |
Decide whether to enable hibernate settings. Valid value:
|
|
start_time | Integer |
Specify the start time of hibernate (Unit: minute).
|
|
end_time | Integer |
Specify the stop time of hibernate (Unit: minute).
|
|
monday | Boolean |
Decide whether to hibernate every Monday. Valid value:
|
|
tuesday | Boolean |
Decide whether to hibernate every Tuesday. Valid value:
|
|
wednesday | Boolean |
Decide whether to hibernate every Wednesday. Valid value:
|
|
thursday | Boolean |
Decide whether to hibernate every Thursday. Valid value:
|
|
friday | Boolean |
Decide whether to hibernate every Friday. Valid value:
|
|
saturday | Boolean |
Decide whether to hibernate every Saturday. Valid value:
|
|
sunday | Boolean |
Decide whether to hibernate every Sunday. Valid value:
|
|
depth_setting | Integer |
Specify the distance from the bottom of container to sensor (Unit: mm).
|
|
collecting_interval | Integer |
Specify the interval for data collecting (Unit: Second).
|
|
alarm1 | Struct |
Alarm threshold 1 settings. |
|
enable | Boolean |
Decide whether to enable the first threshold alarm for this device. Valid value:
|
|
value | Integer |
Specify the number of tissue remaining percentage (Unit: %).
|
|
disable | Boolean |
Decide whether to enable alarm dismiss report. Valid value:
|
|
alarm2 | Struct |
Alarm threshold 2 settings. |
|
enable | Boolean |
Decide whether to enable the first threshold alarm for this device. Valid value:
|
|
value | Integer |
Specify the number of tissue remaining percentage (Unit: %).
|
|
time_zone | Enum |
Specify the time zone for this device.
|