Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TUYA curtain motor #4288

Closed
NMGAndy opened this issue Jan 28, 2021 · 26 comments · Fixed by #4223
Closed

TUYA curtain motor #4288

NMGAndy opened this issue Jan 28, 2021 · 26 comments · Fixed by #4223

Comments

@NMGAndy
Copy link

NMGAndy commented Jan 28, 2021

Device

  • Product name: TUYA CURTAIN MOTOR
  • Manufacturer: _TZE200_nogaemzt
  • Model identifier: TS0601
  • Device type :
    • Other: Window Covering

Screenshots

image
image
image

@Smanar
Copy link
Collaborator

Smanar commented Jan 28, 2021

Hello, easy to add #4223 , but are you able to compile the code for test ? You just need a linux but with full OS ?

@NMGAndy
Copy link
Author

NMGAndy commented Jan 29, 2021

Hello, easy to add #4223 , but are you able to compile the code for test ? You just need a linux but with full OS ?

I use it with docker on synology nas. Have no linux machine.

@Smanar
Copy link
Collaborator

Smanar commented Jan 29, 2021

Ok, so will be a surpise, but your device is router, so I don't think we can have problem.

@NMGAndy
Copy link
Author

NMGAndy commented Feb 2, 2021

Hello, easy to add #4223 , but are you able to compile the code for test ? You just need a linux but with full OS ?

Compiled the code and tested it with my device. Now I see open/close buttons in Home Assistant. They work.
The questions is how can I calibrate the motor now?

@Smanar
Copy link
Collaborator

Smanar commented Feb 2, 2021

Good question, there is no command for that on cluster 0xEF00 yet, what is written on the manual ? need to use the app, a button, a remote ?

@NMGAndy
Copy link
Author

NMGAndy commented Feb 17, 2021

Good question, there is no command for that on cluster 0xEF00 yet, what is written on the manual ? need to use the app, a button, a remote ?

I found how to calibrate the motor. It calibrates automatically when its shaft is blocked. I currently have no curtain rails so I blocked motor shaft manually to calibrate it (opened/closed positions).

But there is a problem. When I click OPEN button in Home Assistant, CLOSE button becomes disabled (not OPEN).
So If I open curtain I cannot close it. Or if I close curtain I cannot open it - CLOSE button still active, OPEN button disabled.

@Smanar
Copy link
Collaborator

Smanar commented Feb 17, 2021

But there is a problem. When I click OPEN button in Home Assistant, CLOSE button becomes disabled (not OPEN).
So If I open curtain I cannot close it. Or if I close curtain I cannot open it - CLOSE button still active, OPEN button disabled.

It mean the state is reversed.
Are you using the normal version or the one with modification ?

@NMGAndy
Copy link
Author

NMGAndy commented Feb 18, 2021

It mean the state is reversed.
Are you using the normal version or the one with modification ?

Version of what?

@Smanar
Copy link
Collaborator

Smanar commented Feb 18, 2021

Deconz version ^^. Because the PR was validated on the last.
Are are you still on the version you have recompiled ?

And if you can share the device json ? I just need bri/on/lift/open.

@Smanar
Copy link
Collaborator

Smanar commented Feb 21, 2021

Need more information @NMGAndy ?

@NMGAndy
Copy link
Author

NMGAndy commented Apr 6, 2021

Need more information @NMGAndy ?

Sorry for long reply.

I'm currently on latest firmware with same problem.
"alert": "none",
"bri": 254,
"lift": 100,
"on": false,
"open": true,
"reachable": true

@Smanar
Copy link
Collaborator

Smanar commented Apr 6, 2021

Ok, so there is a problem yes, On/open are the reverse of bri/lift.
Wich one deconz version are you using, the firmware is not important.
Have you tried the "reverse" command ? was repaired on last deconz version, but as you have a reverse only in 50% of command, not sure it can solve your issue.

@NMGAndy
Copy link
Author

NMGAndy commented Apr 7, 2021

Wich one deconz version are you using, the firmware is not important.
Have you tried the "reverse" command ? was repaired on last deconz version, but as you have a reverse only in 50% of command, not sure it can solve your issue.

Version 2.10.04
Reverse command - where I can find it?
I am using Home Assistant. There are only 2 buttons UP and DOWN and position slider to manipulate the motor in HA.

@NMGAndy
Copy link
Author

NMGAndy commented Apr 7, 2021

Tried to use the motor with Node Red instead of Home Assistant.
In Node Red I can use Switch command (TRUE - closes curtains, FALSE - opens).
Also I can use Brightness - 0 - closes curtains, 255 - opens.
Is it right behaviour?

@Smanar
Copy link
Collaborator

Smanar commented Apr 7, 2021

The reverse command is repaired only in 2.10.05 (or when you compile the code yourself)

In Node Red I can use Switch command (TRUE - closes curtains, FALSE - opens).
Also I can use Brightness - 0 - closes curtains, 255 - opens.

It s right for Switch command but not for Brigtness, I have made a change on the code, can you try it ?

sudo apt install deconz-dev
git clone --branch tuya_cov_4 https://github.com/Smanar/deconz-rest-plugin.git
cd deconz-rest-plugin
qmake && make -j2
sudo cp ../libde_rest_plugin.so /usr/share/deCONZ/plugins

You will have a "native" mode with command in the good order (if it work), don't need to re-include the device, just restart.

BTW, I have see your closed issue for another curtain motor, you have 2 motors with 2 differents manufacture name ?

@NMGAndy
Copy link
Author

NMGAndy commented Apr 8, 2021

It s right for Switch command but not for Brigtness, I have made a change on the code, can you try it ?

Sure! I'll try it. Thank you!

BTW, I have see your closed issue for another curtain motor, you have 2 motors with 2 differents manufacture name ?

Yes. I have both motors. No differences in clusters. Just manufacture name.

@Mimiix
Copy link
Collaborator

Mimiix commented Apr 8, 2021

@Smanar I'd like to have a full issue on it with screenshots. Tuya is way to unpredictable to assume it's the same. If you integrate it, please stick to #4723

@NMGAndy
Copy link
Author

NMGAndy commented Apr 8, 2021

sudo apt install deconz-dev
git clone --branch tuya_cov_4 https://github.com/Smanar/deconz-rest-plugin.git
cd deconz-rest-plugin
qmake && make -j2
sudo cp ../libde_rest_plugin.so /usr/share/deCONZ/plugins

Just tried this version. Everything is ok now with _TZE200_nogaemzt motor.
But _TZE200_zpzndjez is reversed.

@Smanar
Copy link
Collaborator

Smanar commented Apr 9, 2021

For the _TZE200_zpzndjez, it s not a new device, so if I reverse it, I will broke the installation of users that already use it.
So pls wait for some return first #4521

Edit:
BTW, the PR was in a not published version the (v2.10.5)
So yes, I can reverse it without problem, but I prefer wait a least 2/3 days for another return.

@NMGAndy
Copy link
Author

NMGAndy commented Apr 10, 2021

For the _TZE200_zpzndjez, it s not a new device, so if I reverse it, I will broke the installation of users that already use it.
So pls wait for some return first #4521

Edit:
BTW, the PR was in a not published version the (v2.10.5)
So yes, I can reverse it without problem, but I prefer wait a least 2/3 days for another return.

Ok. Thank you!

@Smanar
Copy link
Collaborator

Smanar commented Apr 14, 2021

@NMGAndy I have no answer from other user, so have reversed it too

Can you make tries again ? Same branch

cd deconz-rest-plugin
git pull
qmake && make -j2
sudo cp ../libde_rest_plugin.so /usr/share/deCONZ/plugins

@NMGAndy
Copy link
Author

NMGAndy commented Apr 15, 2021

@NMGAndy I have no answer from other user, so have reversed it too
Can you make tries again ? Same branch

@Smanar Both motors works properly now. Thank you!

@Smanar
Copy link
Collaborator

Smanar commented Apr 15, 2021

Ok, thx, making the PR.

@shlomki
Copy link

shlomki commented Nov 18, 2021

Having some trouble with this curtain motor, it's only recognized as a Smart Plug.
I'm running the latest version of deconz on beta (2.13.02 / 11/10/2021). I've tried to do inclusion twice without deleting, but it stays as smart plug. I also tried to delete and include again - still smart plug.
There was only one time that it was successful in becoming a covering device, but the up/down buttons in HA didn't work, so I decided to delete and try again, since then it's not being recognized as covering device.

Any ideas? @NMGAndy is it still working correctly for you? Which version of deconz do you have?

@shlomki
Copy link

shlomki commented Nov 18, 2021

I tried to turn on debug logs now and do inclusion again, all of the sudden it's being recognized correctly as a window cover device. Some voodoo in here maybe :)

@Smanar
Copy link
Collaborator

Smanar commented Nov 18, 2021

nope, it s a classic deconz issue.
It 's for that tuya device need 2 inclusions, to make short deconz have problem to reconize them (they are zigbee compliant, but not realy respect it, for exemple the firmware realy show him as plug).
Will be solved in some month with DDF file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants