Deconz-rest-plugin: Loratap Tuya Smart Life ZigBee 3.0 Curtain Blind Switch for Roller Shutter Electric motor

Created on 13 Aug 2020  路  38Comments  路  Source: dresden-elektronik/deconz-rest-plugin

All 38 comments

I'm also interested in the Loratap device working with deconz. It looks like they are pretty much the same. But I think no one knows until someone connects it with deconz.

The Zemismart should work. At least with the next release I think See:
https://github.com/dresden-elektronik/deconz-rest-plugin/issues/2999 or https://zigbee.blakadder.com/Zemismart_ZM-CSW002-D.html

@lukinno1 I've changed your request to a User question as this is not a device request.

We need the device in order to add support for it. Without that we can't do anything 馃槩

As @janmo0 mentioned, the Zemismart should have a degree on support in the next beta.

We need the device in order to add support for it. Without that we can't do anything 馃槩

Ok, I ordered one to investigate. But need to wait at least 1 month for arrival.

As @janmo0 mentioned, the Zemismart should have a degree on support in the next beta.

You mean only basic functionality like up, down and stop?
Was already wondering how and if the set position is working?!

The only thing I could see in #2999 within the window covering cluster ist the 0x0015 and 0x0016 for 'Acceleration Time - Lift' and 'Deceleration Time - Lift' and maybe the mode on 0x0017 (which is used by the Ubisis Shutter J1 for setting the device into a configuration mode)

@janmo0 Great! Feel free to open a new device request issue when you get it!

@SwoopX might be able to answer this as he created the PR.

The only thing I could see in #2999 within the window covering cluster ist the 0x0015 and 0x0016 for 'Acceleration Time - Lift' and 'Deceleration Time - Lift' and maybe the mode on 0x0017 (which is used by the Ubisis Shutter J1 for setting the device into a configuration mode)

I don't know what you got that idea. The devices are controlled by the corresponding cluster commands, that's it. You'll probably see the lift percentage in the corresponding attribute then.

I got the device today. It's working with Deconz via API or GUI.

Bildschirmfoto 2020-08-29 um 18 03 02
Bildschirmfoto 2020-08-29 um 18 03 55

In Phoscon its shown as:
Bildschirmfoto 2020-08-29 um 18 16 02

I'm just wondering how to configure the device. Right now full open or close is around 10 seconds. What if the shade needs more or less to fully close or open?

You can use the "lift" field to select the level.
Perhaps in phoscon using the brightness slider.

Maybe there is a way of entering Calibration Mode using the buttons. Has anyone been able to do it? I have the same issue.

Right, I have same reaction for 2 other tuya covering. And one of them need a remote to set calibration.
without calibration the setLevel fonction don't work.

Right, I have same reaction for 2 other tuya covering. And one of them need a remote to set calibration.
without calibration the setLevel fonction don't work.

But have you been able to calibrate any of your devices?

I can use the set level function without calibration on the Loratap device. But as default the device send power for 10 seconds. Or if I set to 50% then for 5 seconds.
That should be no problem for only open and close if the blinds close within 10 seconds and the motor has an mechanical or electric endstop.
But the set level function could be wrong then.

As said before, in the Ubisis Shutter J1 the 0x0017 setting is used to put the device into a configuration mode. As I read from the manual.

This is from the Loratap manual:

IMG_20200905_181505

IMG_20200905_181545

I can use the set level function without calibration on the Loratap device. But as default the device send power for 10 seconds. Or if I set to 50% then for 5 seconds.
That should be no problem for only open and close if the blinds close within 10 seconds and the motor has an mechanical or electric endstop.
But the set level function could be wrong then.

As said before, in the Ubisis Shutter J1 the 0x0017 setting is used to put the device into a configuration mode. As I read from the manual.

This is from the Loratap manual:

IMG_20200905_181505

IMG_20200905_181545

I have tried writing the 0x0017 parameter using VNC conection but I always get "writing failed". Does anyone know how can I achieve this?

Right, I have same reaction for 2 other tuya covering. And one of them need a remote to set calibration.
without calibration the setLevel fonction don't work.

But have you been able to calibrate any of your devices?

Not me, but yes he do https://github.com/dresden-elektronik/deconz-rest-plugin/issues/3161#issuecomment-687270616

e to calibrate any of your devices?

In this case the calibration was triggered by a RF remote control. In the case of your switch and mine (I have one branded as Losonho) it seems, by the use manual that you sent me (the one that came with mine doesn't even mention it) that the app ( tuya app) can trigger the calibration, so for sure there is some kind ok command that can be sent to do it.

The Ubisis Shutter J1 uses the 0x0017 for this, but in Deconz implementation it is created a Sensor as a workaround to trigger this. Maybe someone could change the code in order to also create this sensor for these switches and we could test. (unfortunately I don't know how to do it)

On my side I have searched and I haven't see on a zigbee project some information about a zigbee "calibration" command.
In all devices, it s always build in the hardware or with a 433 mhz remote (and the app)

On my side I have searched and I haven't see on a zigbee project some information about a zigbee "calibration" command.
In all devices, it s always build in the hardware or with a 433 mhz remote (and the app)

See the pictures of the manual on the above pictuture. The user manual I received only mentions how to pair but the one @janmo0 received shows how to calibrate in Tuya app. So the zigbee command exists.

Also when I look at window_covering.cpp I can see it was created using ZigBee Home Automation Public Application Profile Document 05-3520-29. In this document you can see on page 183 that it mentions attribute 0x0017 (sorry if I'm not using the correct naming). The usage of this attribute 0x0017 has been used for the implementation of the "Ubisys Shutter Control J1". This was done by creating a sensor. Maybe this kind of workaround could be applied to all of cover devices. Unfortunately this is an idea but I don't know how to program it.

No cover devices will work out of the box without calibrating it. So I believe zigbee aliance has inserted this in their code, and I hope deconz will allow this some day!

Ha right.
For my device, I don't think it will work because they are using the tuya cluster but for you why not.
Have you try with deconz ? you can set this value in the GUI, but I m not sure for the value
From actual code

            <value name="Reversed" value="0"></value>
            <value name="Calibration Mode" value="1"></value>
            <value name="Maintenance Mode" value="2"></value>
            <value name="LED feedback" value="3"></value>

But from file and your doc

  • 0x0017 bitmap8, Mode (bit0=if the motor direction is reversed, bit1=the device is in calibration, bit2=maintenance mode)

So for me the calibration mode will be 0/1/0 = 2

I have tried writing the 0x0017 parameter using VNC conection but I always get "writing failed". Does anyone know how can I achieve this?

Same here 馃槙

@janmo0 Keep clicking the buttons to keep it awake. Battery devices are sometimes annoying.

@janmo0 Keep clicking the buttons to keep it awake. Battery devices are sometimes annoying.

It's no battery driven device. It's always on main voltage.

Aah, My bad then :( @janmo0

I m not sure but if the device don't support this attribute, you have another message ? "Unsupported something" no ?

This value is grayed or not in the table ? have you tried to read it ?

After reading the value is greyed out in the table.

ok, so bad luck.
There is an user that have asked for tuya documentation, I will ask to him.

But this working mode is possible without the gateway ?
It s possible the gateway just memorise the value up and down level and make the device stop itself.

I have found this under tuya documentation

Maybe it can help!

Ha nice, not usefull for you, but it seem there is an attribute 0xF000 in the windows clovering cluster

0xF000 > Tuya Private Report Attr > Window Cover Status >0/1/2 > defaut(1)

a) After the device receives the 0x00 (open) command, it will immediately report the 0 (open) state through Tuya鈥檚 private reporting attribute 0xF000, and control the curtain switch relay to keep it open; run to the curtain switch stroke position, stop the curtain switch relay, And report 1 (stop) status.

b) After the device receives the 0x01 (close) command, it immediately reports the 2 (close) state through Tuya鈥檚 private reporting attribute 0xF000, and controls the curtain switch relay to keep it off; it runs to the curtain switch stroke position and stops the curtain switch relay. And report 1 (stop) status.

c) After the device receives the 0x02 (stop) command, it immediately reports the 1 (stop) state through Tuya's private reporting attribute 0xF000.

Issue with same problem on Z2M repo: https://github.com/Koenkk/zigbee2mqtt/issues/4257

As there hasn't been any response in 21 days, this issue has been automatically marked as stale. At OP: Please either close this issue or keep it active It will be closed in 7 days if no further activity occurs.

As there hasn't been any response in 28 days, this issue will be closed. @ OP: If this issue is solved post what fixed it for you. If it isn't solved, request to get this opened again.

Ha nice, not usefull for you, but it seem there is an attribute 0xF000 in the windows clovering cluster

0xF000 > Tuya Private Report Attr > Window Cover Status >0/1/2 > defaut(1)

a) After the device receives the 0x00 (open) command, it will immediately report the 0 (open) state through Tuya鈥檚 private reporting attribute 0xF000, and control the curtain switch relay to keep it open; run to the curtain switch stroke position, stop the curtain switch relay, And report 1 (stop) status.
b) After the device receives the 0x01 (close) command, it immediately reports the 2 (close) state through Tuya鈥檚 private reporting attribute 0xF000, and controls the curtain switch relay to keep it off; it runs to the curtain switch stroke position and stops the curtain switch relay. And report 1 (stop) status.
c) After the device receives the 0x02 (stop) command, it immediately reports the 1 (stop) state through Tuya's private reporting attribute 0xF000.

Hello

Why my device in conbee is lost/ not working..i see this device like heiman but in vnc i can readed cluster only one. Then like not enable.

Did you have the same problem?

I think the guys @ Z2M made some progress with the calibration mode issue. Anybody here can check if this is usable for deconz?

https://github.com/Koenkk/zigbee2mqtt/issues/4257#issuecomment-711031302

Ha yep probably

(0x0102) | Write Attributes (0x02) | 0xf001 | 8-Bit (0x30) | 0 (0x00) | Start Calibration
(0x0102) | Write Attributes (0x02) | 0xf001 | 8-Bit (0x30) | 1 (0x01) | End Calibration

Will try to add thoses command to api to test.

To test you can try to edit the xml file > https://github.com/Smanar/deconz-rest-plugin/commit/85a76c2ed9668121c1b7f73a82ae586945039883

Then restart deconz, you will have new option in cluster 0x0102.

But I m reading the z2m issue, it seem you still need a switch for that ? and the timer is memorised on the switch.

To test you can try to edit the xml file > Smanar@85a76c2

Then restart deconz, you will have new option in cluster 0x0102.

But I m reading the z2m issue, it seem you still need a switch for that ? and the timer is memorised on the switch.

It's working!
The device is a switch only. Used for controlling rollershades.

Would it be possible to get the light mode setting also working?

(0x0006) | Write Attributes (0x02) | 0x8001 | 8-Bit (0x30) | 0 (0x00) | Light Mode 1
(0x0006) | Write Attributes (0x02) | 0x8001 | 8-Bit (0x30) | 1 (0x01) | Light Mode 2
(0x0006) | Write Attributes (0x02) | 0x8001 | 8-Bit (0x30) | 2 (0x02) | Light Mode 3

Will the settings be later available in the REST API too?

I will add it on deconz GUI, but what is "light mode " on a shutter ?

Will the settings be later available in the REST API too?

IDK, the calibration is only needed 1 time, not sure It s usefull to make a command usable by third app for that.

And BTW you have a cluster 0x0f41 in deconz ? on the GUI ?

I will add it on deconz GUI, but what is "light mode " on a shutter ?

It is used for the button lighting. I think it's for "always on", "always off" and "only at touch" I think.

IDK, the calibration is only needed 1 time, not sure It s usefull to make a command usable by third app for that.

Ok. Just tought it would be added because the Ubisys J1 device has the calibration available via API: #813

And BTW you have a cluster 0x0f41 in deconz ? on the GUI ?

I'm running 2.05.78 and don't have this cluster. Or at least. I didn't found.

Ok so have added the light mode in the XML.
Have added the calibration command, it s an hidden command, to use it PUT, PATCH /api/<apikey>/lights/<id> with {"calibration":true}

If you can test the calibration command ?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ScharV picture ScharV  路  5Comments

qm3ster picture qm3ster  路  3Comments

lynix picture lynix  路  4Comments

mvasicek picture mvasicek  路  4Comments

wizkidorg picture wizkidorg  路  3Comments