tinytuya: Device with 22id doesn't work

I tried the fix but tinytuya wizard report:

Product ID = keyxet94msd94uvq  [Valid payload]:
    Address = 192.168.1.7,  Device ID = bf534c9207553e222bjcki, Local Key = "LOCAL_KEY",  
    Version = 3.3,  MAC = 68:57:2d:25:be:9a Unexpected error for 192.168.1.7: Unable to poll

This code report “None”

import tinytuya
a = tinytuya.OutletDevice('bf534c9207553e222bjcki', '192.168.1.7', 'my_local_key', 'device22')
a.set_version(3.3)
a.set_dpsUsed({"1": None})
data =  a.status()
print(data)

About this issue

  • Original URL
  • State: open
  • Created 2 years ago
  • Comments: 17 (5 by maintainers)

Most upvoted comments

@resetpointer No, there is no API command to query the device version, at least that I’ve been able to find (and I looked pretty hard while rewriting the scanner). The best you can do is profile a device by sending various commands to see how it reacts; i.e. only a v3.4 device will respond to “negotiate session key,” only v3.1 allow polling the status without the local key, etc. Now that I think about it, it probably wouldn’t be a bad idea to make a function that does this for you.