socket
Power socket or power supply connector. Examples:
- Built-in socket
- Extension cable
- Network filter
- Socket adapter
Available device functions
The device can have all the functions listed below or some of them. E.g. if the smart socket cannot measure the current energy consumption, there is no need in including the current
,power
, voltage
functions in its model description.
The device has a mandatory online
function: all sockets must have it.
Function | Mandatory? | Description |
child_lock | Power button child safety lock | |
current | Existing current, mA | |
on_off | Turning the device on and off remotely | |
online | ✔︎ | Device availability: offline or online |
power | Existing power, W | |
voltage | Existing voltage, V |
Socket model description example
The model shall be described in accordance with the model structure. The example describes a socket that can be switched on/off remotely, measure the current energy consumption and block the power button to protect children. The socket has a time-out timer.
Besides, allowed values for the power
function (consumed power) of the model are changed: devices of this model can measure the power from 10 to 45,000 W at an interval of 1 W.
{
"id": "QWERTY124",
"manufacturer": "Xiaqara",
"model": "SM1123456789",
"hw_version": "3.1",
"sw_version": "5.6",
"description": "Xiaqara smart socket",
"category": "socket",
"features": [
"online",
"on_off",
"sleep_timer",
"child_lock",
"current",
"power",
"voltage"
],
"allowed_values": {
"power": {
"type": "INTEGER",
"integer_values": {
"min": "10",
"max": "45000",
"step": "1"
}
}
}
}
User's socket description example
The device shall be describe in accordance with the device structure. The example contains no socket model description as we believe that models are described independently and the model ID will be enough (in this case, QWERTY124).
{
"id": "ABCD_004",
"name": "My socket",
"default_name": "Smart socket",
"nicknames": ["Intelligent socket", "Manageable socket"],
"home": "My home",
"room": "Living room",
"groups": ["Video equipment", "Sound"],
"model_id": "QWERTY124",
"hw_version": "3.1",
"sw_version": "5.6",
"partner_meta": {
"internal-id": 1234,
"specificity": "microchip 2A"
},
}