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

Rotary smart scene controller doesn't work for dimming #218

Closed
1 of 3 tasks
nicktrigger opened this issue May 3, 2024 · 13 comments
Closed
1 of 3 tasks

Rotary smart scene controller doesn't work for dimming #218

nicktrigger opened this issue May 3, 2024 · 13 comments
Labels
bug Something isn't working stale

Comments

@nicktrigger
Copy link

LocalTuya Version

3.2.5.1

Home Assistant Version

2024.4.4

Environment

  • Does the device work using the Home Assistant Tuya Cloud component?
  • Is this device connected to another local integration, including Home Assistant and any other tools?
  • The devices are within the same HA subnet, and they get discovered automatically when I add them

What happened?

I am not able to add an automation for rotation on my scene controller to dim or brighten lights. It works perfectly with tuya smart life.

There is a button that is recognised and works as expected, the diary dial doesn't seem to be discovered and doesn't do anything when I manually add the DP.
Screenshot_20240503_193526_Home Assistant
Screenshot_20240503_193552_Home Assistant

Steps to reproduce.

Added new device through configure
dp 1 for button found. World as expected
No more dps found, manually added. Can't get rotary knob to do anything

From tuya developer site

{
"result": [
{
"active_time": 1714284718,
"bind_space_id": "48728372",
"category": "wxkg",
"create_time": 1714284718,
"custom_name": "living room lights Smart Knob",
"icon": "smart/icon/ay1536047723331OpdLN/98dec7f47c676e969719297c55adec81.png",
"id": "eb9ecfa4b188abd87f5qcz",
"ip": "",
"is_online": true,
"lat": "-8.6800",
"local_key": "",
"lon": "115.5200",
"model": "ERS-10TZBVK-AA",
"name": "Smart Knob",
"product_id": "4fjiwweb",
"product_name": "Smart Knob",
"sub": true,
"time_zone": "+08:00",
"update_time": 1714536383,
"uuid": "70ac08fffe264478"
}
],
"success": true,
"t": 1714658400792,
"tid": "444d5a1c088c11efa098724a8b78ed1e"
}

{
"result": {
"category": "wxkg",
"functions": [
{
"code": "mode",
"desc": "{"range":["remote_control","wireless_switch"]}",
"name": "模式切换",
"type": "Enum",
"values": "{"range":["remote_control","wireless_switch"]}"
}
],
"status": [
{
"code": "switch_mode1",
"name": "无线开关1",
"type": "Enum",
"values": "{"range":["click","double_click","press"]}"
},
{
"code": "battery_percentage",
"name": "电池电量",
"type": "Integer",
"values": "{"unit":"%","min":0,"max":100,"scale":0,"step":1}"
},
{
"code": "mode",
"name": "模式切换",
"type": "Enum",
"values": "{"range":["remote_control","wireless_switch"]}"
},
{
"code": "knob_switch_mode_1",
"name": "旋钮开关1",
"type": "Enum",
"values": "{"range":["clockwise_rotation","anticlockwise_rotation"]}"
}
]
},
"success": true,
"t": 1714658531269,
"tid": "92288ee3088c11efaae33e3874d12f34"
}

Relevant log output

No response

Diagnostics information.

localtuya-d3d7c7bd6a0d6eae5b514de424d066c4-living room lights Smart Knob-dca6444bb0b40301154a06c80a0f0a9f.json

@nicktrigger nicktrigger added the bug Something isn't working label May 3, 2024
@xZetsubou
Copy link
Owner

You can't add DPS "12 and 11" as switch they aren't bool type. you will need to configure them as "select entity"

  1. configure -> choose reconfigure existing device -> select your device.
  2. Uncheck from entities DPS 11,12 to delete there entities and keep click on submit until it saves and delete the entities.
  3. Again configure -> choose reconfigure existing device -> select your device
  4. Check on [add new entity(s)
  5. Add 2 with "select" platform.

For DPID 11 option values be like this:

remote_control: Remote Control
wireless_switch:  Wireless Switch

For DPID 12 option values:

clockwise_rotation: Clockwise
anticlockwise_rotation:  Counter-Clockwise

tip: it seems your device doesn't poll the status correctly since you added the all DPS manual, at the start of your manual DPS add zero e.g. 0,1,10,11,12. Zero will restore the last state in Home Assistant.

@nicktrigger
Copy link
Author

nicktrigger commented May 4, 2024 via email

@xZetsubou
Copy link
Owner

Have you tried to monitor the device from Developer tools -> events then listen to localtuya_device_dp_triggered or localtuya_device_triggered then trigger DP 12 and see if it reports anything in events or not.

@nicktrigger
Copy link
Author

nicktrigger commented May 4, 2024 via email

@xZetsubou
Copy link
Owner

If the device it self doesn't reports the changes on DP12 which kinda weird? then there is nothing I can do here. usually even if the DP doesn't found automatically at least it might send the it states later if it triggered if not then nothing can be done.

@nicktrigger
Copy link
Author

I wonder if there is some other dp that I can't see where this gets reported. Is there a way I could see what the dp numbers are from tuya directly?

@nicktrigger
Copy link
Author

Or what it is sending to tuya cloud to execute the commands?

@xZetsubou
Copy link
Owner

If you downloaded the device diagnostics you can see "device_cloud" there is "dps_data" that literally pulled the device dps. however you still able to see the device logs from IOT, in devices tab, btw what is this device? what is clockwise_rotation","anticlockwise_rotation is even means?

@nicktrigger
Copy link
Author

nicktrigger commented May 4, 2024 via email

@nicktrigger
Copy link
Author

nicktrigger commented May 4, 2024 via email

@xZetsubou
Copy link
Owner

Does Smart Life it self even detects the changes on DP12 if you manually rotate it? judging by the situation I guess no.

@nicktrigger
Copy link
Author

nicktrigger commented May 6, 2024 via email

Copy link

This issue is stale because it has been open 14 days with no activity. Remove stale label or comment or this will be closed in 5 days.

@github-actions github-actions bot added the stale label May 20, 2024
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale May 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working stale
Projects
None yet
Development

No branches or pull requests

2 participants