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 lights should be off after recovering from a power outage #1865

Open
ntompson opened this issue Dec 8, 2024 · 1 comment
Open

Tuya lights should be off after recovering from a power outage #1865

ntompson opened this issue Dec 8, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@ntompson
Copy link

ntompson commented Dec 8, 2024

The problem

After a power outage, my Tuya light restores to the last state. It should default to off, like my other smart light bulbs. If I happened to have the Tuya light turned on when the power fails, I get woken up in the middle of the night when the power is restored.

Environment

  • Localtuya version: v5.2.2
  • Home Assistant Core version: 2024.11.4
  • [] Does the device work using the Home Assistant Tuya Cloud component ? Not sure
  • [] Does the device work using the Tinytuya (https://github.com/jasonacox/tinytuya) command line tool ? Not sure
  • [] Was the device working with earlier versions of localtuya ? Which one? I can't remember
  • [] Are you using the Tuya/SmartLife App in parallel ? No

Steps to reproduce

  1. Turn Tuya light on in HA
  2. Power fails (can simulate by flipping the breaker)
  3. Power restored
  4. Tuya light automatically turns on
  5. People in bed curse

DP dump

    DPS [20] VALUE [True] 
    DPS [21] VALUE [white] 
    DPS [22] VALUE [41] 
    DPS [23] VALUE [308] 
    DPS [25] VALUE [000e0d0000000000000000c80000] 
    DPS [26] VALUE [0] 

Provide Home Assistant traceback/logs

put your log output between these markers

Additional information

@ntompson ntompson added the bug Something isn't working label Dec 8, 2024
@ankurgogate
Copy link

ankurgogate commented Dec 13, 2024

Have you tried setting the relay status on your tuya device using smartLife app?

If you want to use HomeAssistant
you can go to Developer Tools -> Actions

Search for LocalTuya: Set datapoint
Below is the data to be sent to the device
device_id: "<device_id>"
dp: 38 # This can be different for your device please check developer platform from tuya to use right ID
value: "off" # Possible values -> "off" / "on" / "memory"

If this works for your case, you can then create a helper for dropdown and write automation on change in the dropdown selected value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants