WS52x – 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 WS52x TSL model, their descriptions, and how to use them.
Usage
- Have an overview of the configurable properties and their default values of WS52x.
- 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": 1200, // The interval for data reporting (second).
"set_socket":{ // Socket on/off settings.
"status": 0
},
"power_consumption_enable": true, // Enable to record power consumption.
"led_indicator_mode": true, // Enable LED indicator.
"button_lock_config":{ // Button lock settings.
"enable": false
},
"overcurrent_alarm":{ // Overcurrent alarm settings.
"enable": false,
"current": 10
},
"overcurrent_protect":{ // Overcurrent protection settings.
"enable": false,
"current": 10
}
}
}
Description
The following table provides the description and valid values for the configurable properties of WS52x.
Parameter | Type | Description | |
---|---|---|---|
reporting_interval | Integer |
Specify the interval for data reporting (Unit: Second).
|
|
set_socket | Struct | Socket on/off settings. | |
status | Enum |
Specify the status of socket. Valid value:
|
|
power_consumption_enable | Boolean |
Decide whether to record power consumption. Valid value:
|
|
led_indicator_mode | Boolean |
Decide whether to enable button LED indicator. Valid value:
|
|
button_lock_config | Struct | Button lock settings. | |
enable | Boolean |
Decide whether to lock the button. Valid value:
|
|
overcurrent_alarm | Struct | Overcurrent alarm settings. | |
enable | Boolean |
Decide whether to send alarms when current reaches the threshold. Valid value:
|
|
current | Integer |
Specify the overcurrent threshold value (Unit: Amp).
Note: the max value depends on the
model of WS52x among 10 to 16A.
|
|
overcurrent_protect | Struct | Overcurrent protection settings. | |
enable | Boolean |
Decide whether to stop power supply when current reaches the threshold. Valid value:
|
|
current | Integer |
Specify the overcurrent threshold value (Unit: Amp).
Note: the max value depends on the
model of WS52x among 10 to 16A.
|