Closed TheBisk closed 1 month ago
Hi,
please provide the remaining and requested screenshots. Many thanks!
Do you need something else? Thanks
Hello, can try this DDF
{
"schema": "devcap1.schema.json",
"manufacturername": "Third Reality, Inc",
"modelid": "3RSPE01044BZ",
"vendor": "Third Reality",
"product": "Smart plug",
"sleeper": false,
"status": "Gold",
"subdevices": [
{
"type": "$TYPE_ON_OFF_PLUGIN_UNIT",
"restapi": "/lights",
"uuid": [
"$address.ext",
"0x01"
],
"items": [
{
"name": "attr/id"
},
{
"name": "attr/lastannounced"
},
{
"name": "attr/lastseen"
},
{
"name": "attr/manufacturername"
},
{
"name": "attr/modelid"
},
{
"name": "attr/name"
},
{
"name": "attr/swversion"
},
{
"name": "attr/type"
},
{
"name": "attr/uniqueid"
},
{
"name": "state/alert"
},
{
"name": "state/on",
"refresh.interval": 360
},
{
"name": "state/reachable"
}
]
},
{
"type": "$TYPE_POWER_SENSOR",
"restapi": "/sensors",
"uuid": [
"$address.ext",
"0x01",
"0x0b04"
],
"items": [
{
"name": "attr/id"
},
{
"name": "attr/lastannounced"
},
{
"name": "attr/lastseen"
},
{
"name": "attr/manufacturername"
},
{
"name": "attr/modelid"
},
{
"name": "attr/name"
},
{
"name": "attr/swversion"
},
{
"name": "attr/type"
},
{
"name": "attr/uniqueid"
},
{
"name": "config/on"
},
{
"name": "config/reachable"
},
{
"name": "state/current",
"refresh.interval": 360
},
{
"name": "state/lastupdated"
},
{
"name": "state/power",
"read": {
"at": "0x050b",
"cl": "0x0b04",
"ep": 1,
"fn": "zcl:attr"
},
"parse": {
"at": "0x050b",
"cl": "0x0b04",
"ep": 1,
"eval": "Item.val = Attr.val / 10"
},
"refresh.interval": 360
},
{
"name": "state/voltage",
"read": {
"at": "0x0505",
"cl": "0x0b04",
"ep": 1,
"fn": "zcl:attr"
},
"parse": {
"at": "0x0505",
"cl": "0x0b04",
"ep": 1,
"eval": "Item.val = Attr.val / 10"
},
"refresh.interval": 360
}
]
},
{
"type": "$TYPE_CONSUMPTION_SENSOR",
"restapi": "/sensors",
"uuid": [
"$address.ext",
"0x01",
"0x0702"
],
"items": [
{
"name": "attr/id"
},
{
"name": "attr/lastannounced"
},
{
"name": "attr/lastseen"
},
{
"name": "attr/manufacturername"
},
{
"name": "attr/modelid"
},
{
"name": "attr/name"
},
{
"name": "attr/swversion"
},
{
"name": "attr/type"
},
{
"name": "attr/uniqueid"
},
{
"name": "config/on"
},
{
"name": "config/reachable"
},
{
"name": "state/consumption"
},
{
"name": "state/lastupdated"
}
]
}
],
"bindings": [
{
"bind": "unicast",
"src.ep": 1,
"cl": "0x0006",
"report": [
{
"at": "0x0000",
"dt": "0x10",
"min": 1,
"max": 300
}
]
},
{
"bind": "unicast",
"src.ep": 1,
"cl": "0x0702",
"report": [
{
"at": "0x0000",
"dt": "0x25",
"min": 10,
"max": 300,
"change": "0x0000000A"
}
]
},
{
"bind": "unicast",
"src.ep": 1,
"cl": "0x0B04",
"report": [
{
"at": "0x0505",
"dt": "0x21",
"min": 10,
"max": 300,
"change": "0x00000001"
},
{
"at": "0x0508",
"dt": "0x21",
"min": 10,
"max": 300,
"change": "0x00000064"
},
{
"at": "0x050B",
"dt": "0x29",
"min": 10,
"max": 300,
"change": "0x00000001"
}
]
}
]
}
Based on this one https://github.com/dresden-elektronik/deconz-rest-plugin/blob/master/devices/third_reality/3RSP02028BZ_smart_plug.json
Tested quickly and it seems to work. Now i have the switch and the sensors for power and consuption. I will test it better next days.
Thank you Smanar
i made some test and it seems that:
is there a way to reset the consumption and start from 0? the value looks read only...
Power Off
Power
Consumption
Simple meetering
Do you have the same capture for electrical measurement ? Or use a device with a known power to see the convertion needed ? (a 10W bulb for exemple). what do you have as current ?
For consumption can replace
{
"name": "state/consumption"
},
by
{
"name": "state/consumption",
"read": {
"at": "0x0000",
"cl": "0x0702",
"ep": 1,
"fn": "zcl:attr"
},
"parse": {
"at": "0x0000",
"cl": "0x0702",
"ep": 1,
"eval": "Item.val = Attr.val / 10"
},
"refresh.interval": 365
},
Here it's just a "/10" to show you how it work because a divisor = 360 000 (from your capture) I m not sure it's something reliable. Better to get 2 value with 1 h delay and a constant power.
To reset consumption, with the GUI try on cluster 0x0000 the reset factory request.
Electrical Measurement
So from the device, same convertion than for voltage 1/10 for power. So need
"eval": "Item.val = Attr.val / 10"
like it's already done in the DDF, not seem bad for me.
To reset consumption, with the GUI try on cluster 0x0000 the reset factory request.
i dont know how to do that...
This is the last working DDF, thanks Smanar
{
"schema": "devcap1.schema.json",
"manufacturername": "Third Reality, Inc",
"modelid": "3RSPE01044BZ",
"vendor": "Third Reality",
"product": "Smart plug",
"sleeper": false,
"status": "Gold",
"subdevices": [
{
"type": "$TYPE_ON_OFF_PLUGIN_UNIT",
"restapi": "/lights",
"uuid": [
"$address.ext",
"0x01"
],
"items": [
{
"name": "attr/id"
},
{
"name": "attr/lastannounced"
},
{
"name": "attr/lastseen"
},
{
"name": "attr/manufacturername"
},
{
"name": "attr/modelid"
},
{
"name": "attr/name"
},
{
"name": "attr/swversion"
},
{
"name": "attr/type"
},
{
"name": "attr/uniqueid"
},
{
"name": "state/alert"
},
{
"name": "state/on",
"refresh.interval": 360
},
{
"name": "state/reachable"
}
]
},
{
"type": "$TYPE_POWER_SENSOR",
"restapi": "/sensors",
"uuid": [
"$address.ext",
"0x01",
"0x0b04"
],
"items": [
{
"name": "attr/id"
},
{
"name": "attr/lastannounced"
},
{
"name": "attr/lastseen"
},
{
"name": "attr/manufacturername"
},
{
"name": "attr/modelid"
},
{
"name": "attr/name"
},
{
"name": "attr/swversion"
},
{
"name": "attr/type"
},
{
"name": "attr/uniqueid"
},
{
"name": "config/on"
},
{
"name": "config/reachable"
},
{
"name": "state/current",
"refresh.interval": 360
},
{
"name": "state/lastupdated"
},
{
"name": "state/power",
"read": {
"at": "0x050b",
"cl": "0x0b04",
"ep": 1,
"fn": "zcl:attr"
},
"parse": {
"at": "0x050b",
"cl": "0x0b04",
"ep": 1,
"eval": "Item.val = Attr.val / 10"
},
"refresh.interval": 360
},
{
"name": "state/voltage",
"read": {
"at": "0x0505",
"cl": "0x0b04",
"ep": 1,
"fn": "zcl:attr"
},
"parse": {
"at": "0x0505",
"cl": "0x0b04",
"ep": 1,
"eval": "Item.val = Attr.val / 10"
},
"refresh.interval": 360
}
]
},
{
"type": "$TYPE_CONSUMPTION_SENSOR",
"restapi": "/sensors",
"uuid": [
"$address.ext",
"0x01",
"0x0702"
],
"items": [
{
"name": "attr/id"
},
{
"name": "attr/lastannounced"
},
{
"name": "attr/lastseen"
},
{
"name": "attr/manufacturername"
},
{
"name": "attr/modelid"
},
{
"name": "attr/name"
},
{
"name": "attr/swversion"
},
{
"name": "attr/type"
},
{
"name": "attr/uniqueid"
},
{
"name": "config/on"
},
{
"name": "config/reachable"
},
{
"name": "state/consumption",
"read": {
"at": "0x0000",
"cl": "0x0702",
"ep": 1,
"fn": "zcl:attr"
},
"parse": {
"at": "0x0000",
"cl": "0x0702",
"ep": 1,
"eval": "Item.val = Attr.val / 10"
},
"refresh.interval": 365
},
{
"name": "state/lastupdated"
}
]
}
],
"bindings": [
{
"bind": "unicast",
"src.ep": 1,
"cl": "0x0006",
"report": [
{
"at": "0x0000",
"dt": "0x10",
"min": 1,
"max": 300
}
]
},
{
"bind": "unicast",
"src.ep": 1,
"cl": "0x0702",
"report": [
{
"at": "0x0000",
"dt": "0x25",
"min": 10,
"max": 300,
"change": "0x0000000A"
}
]
},
{
"bind": "unicast",
"src.ep": 1,
"cl": "0x0B04",
"report": [
{
"at": "0x0505",
"dt": "0x21",
"min": 10,
"max": 300,
"change": "0x00000001"
},
{
"at": "0x0508",
"dt": "0x21",
"min": 10,
"max": 300,
"change": "0x00000064"
},
{
"at": "0x050B",
"dt": "0x29",
"min": 10,
"max": 300,
"change": "0x00000001"
}
]
}
]
}
i dont know how to do that...
Do you have the GUI, you have used it for capture. Just select the cluster 0x0000 "basic" (the blue number) and on the cluster panel you will the button.
The DDF is finished ? do you want to make a PR or want I make it ? (to have it officialy)
I think that is better if you make the PR (I don't know how to do that). Thanks
Is there already an existing issue for this?
Product name
Third Reality 3RSPE01044BZ
Manufacturer
Third Reality
Model identifier
3RSPE01044BZ
Device type to add
Switch
Node info
Endpoints and clusters
Basic
Identify
Simple Metering
Electrical Measurement
DDF