Search found 33 matches

by merlot
Friday 30 August 2019 12:20
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

Many thanks for the reply!! Just a detail, to activate protocol V3.3 do I only need to edit the tuyapi/index.js file (by replacing 3.1 by 3.3) ? is that enough? As I've mentioned before "Then you can add device.set_version(3.3) in the get_dps.py after creating the device and the get_dps.py should ...
by merlot
Thursday 29 August 2019 12:00
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

For your referencie, activating the DEBUG (uncommenting the line and commentig de loggin ERROR level one in the ___init__.py) this is what I get from get_dps.py for a dual socket with version 3.3 of plug protocol: INFO:pytuya:pytuya version 7.0.4 INFO:pytuya:Python 3.5.3 (default, Sep 27 2018, 17:25 ...
by merlot
Saturday 24 August 2019 8:51
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

I don't have any bulb but I guessed that you'd need at least one DPS to turn it on or off. But not sure at all

Enviado desde mi Redmi Note 4 mediante Tapatalk

by merlot
Friday 23 August 2019 22:08
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

Have you tried the get_dps and turnON, turnOFF scripts?

Enviado desde mi Redmi Note 4 mediante Tapatalk

by merlot
Friday 16 August 2019 11:23
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

I think that in the pytuya readme you can see some options.

I'have used PacketCapture app in my android device, capturing packets from SmartLife app and searching in the packets for the keys or DPS.

Enviado desde mi Redmi Note 4 mediante Tapatalk

by merlot
Saturday 10 August 2019 14:36
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

Nice job! :D As I don't have any devices of these kind I was unable to contribute. Build the plugin for a friend. [emoji14] I guess a pull request with modified source would be preferred in this case? So we can keep wild growth of plugins under control [emoji38] ? It should be tested for previous ...
by merlot
Saturday 10 August 2019 14:33
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

Hello all, Many Thanks for the work performed. By any chance, will i be able to command, with the plugin, the following switch : https://m.ru.aliexpress.com/item/32963064005.html Thanks in avance for the answer [emoji16] Hello, I don't know. It's adapted for some plugs, with measurement option. A ...
by merlot
Thursday 08 August 2019 15:34
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

Hi,
If the devID ànd localkey are correct, you might have a different device and you'll have to investigate further.
For instance try to print the data you receive

Enviado desde mi Redmi Note 4 mediante Tapatalk

by merlot
Wednesday 07 August 2019 20:57
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

My modified plugin works fine, with the mentioned errors, for multisocket plug https://i.imgur.com/2x5eqDC.jpg Some weird problems You can see that V*A != W. But I have observed that I get the same values in Smart Life app. It's like the W is calculated for 110V not the real one. So, perhaps I'll ...
by merlot
Wednesday 07 August 2019 19:24
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

Got it https://i.imgur.com/3dpOP03.jpg The only problem is that I get this error after switching on or off the plug. But it is turned on or off 2019-08-07 18:53:31.532 Error: (Plug Cuina) 'onCommand' failed 'ValueError':'Input strings must be a multiple of 16 in length'. 2019-08-07 18:53:31.532 ...
by merlot
Wednesday 07 August 2019 11:58
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

@sincze I have modified the code and requested a pull in github. This afternoon I'll try to create a new params (Port or SerialPort) to select 3.1 or 3.3 protocol. Anyway, I think the plugin is not working for 3.3 (I get no data in the devices) and I think that it's because the plugin is not using ...
by merlot
Monday 05 August 2019 13:37
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

I answer myself. The problem for a dual socket plug is in this code for val in self.__unit2dps_id_list: if(val <= max_dps): #single socket dps Domoticz.Device(Name="Tuya SmartPlug (Switch)", Unit=val, TypeName="Switch").Create() Domoticz.Log("Tuya SmartPlug Device (Switch) #" + str(val) +" created ...
by merlot
Monday 05 August 2019 12:31
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

Hi, I ran this command but nothing appears, but I have installed it during the plugin installation (git clone https://github.com/clach04/python-tuya.git) If I run the test.py file of the pytuya installation, I get this output pi@domoticz:~/domoticz/plugins/Domoticz-Tuya-SmartPlug-Plugin/python-tuya ...
by merlot
Monday 05 August 2019 11:06
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

tete wrote: Monday 05 August 2019 9:53

Hi merlot,
I don't know what version I am using. How can I find out the version? How can I update it?
sudo pip3 show pytuya

Unfortunately, I couldnn't upgrade using the --upgrade option in pip3 and I had to copy/paste the __init from the project git site.
by merlot
Monday 05 August 2019 0:02
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

We could look into that integration indeed with a dropdown box 3.1 / 3.3 for now ? Will you do? Or are you asking me to do it? I can try, but I'm a newbie in git and I'm not sure how to contribute. Anyway, after solving this issue, now, with the tixi_sincze plugin, after adding a dual plug, I get ...
by merlot
Sunday 04 August 2019 23:17
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

I'm trying to configure a teckin sp22 plug but I get this message: pi@domoticz:~/domoticz/plugins/Domoticz-Tuya-SmartPlug-Plugin $ ./get_dps.py 192.168.0.171 60417563840d8e68fe98 Unexpected status() payload=b'3.3\x00\x00\x00\x00\x00\x00\x9d\xa4\x00\x00\x00\x01N\xcc\x8f\xb0>@,B=\xbe\xe9 \xcf\xd2\x8f ...
by merlot
Sunday 04 August 2019 23:15
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

We could look into that integration indeed with a dropdown box 3.1 / 3.3 for now ? Will you do? Or are you asking me to do it? I can try, but I'm a newbie in git and I'm not sure how to contribute. Anyway, after solving this issue, now, with the tixi_sincze plugin, after adding a dual plug, I get ...
by merlot
Sunday 04 August 2019 16:29
Forum: Python
Topic: [REQUEST] Plugin for Tuya
Replies: 373
Views: 100732

Re: [REQUEST] Plugin for Tuya

And some more time later ... I've solved the mistery. I was working with pytuya 7.0.3, but now I've seen that there is a 7.0.4 that includes support for 3.3 protocol while the previous one was just for 3.1. Now, using that pytuya and adding a device.set_version(3.3) in the get_dps.py just before the ...
by merlot
Sunday 21 July 2019 17:34
Forum: DIY Hardware and Protocols
Topic: SMA Sunny Boy 1.5
Replies: 90
Views: 19968

Re: SMA Sunny Boy 1.5

I have create a v2 version to change from a Custom sensor to a type kWh, but I don't understand how it works. From the inverter I get: - instant power (W) - Dayly generated Energy (kWh) - Total generated Energy (kWh) The device type kWh can be updated with two values, power and energy, and I ...
by merlot
Sunday 21 July 2019 17:17
Forum: DIY Hardware and Protocols
Topic: SMA Sunny Boy 1.5
Replies: 90
Views: 19968

Re: SMA Sunny Boy 1.5

I'm sorry but I don't know 3.0 version of Sunny Boy and probably it won't work. Or the ID's are different

Anyway, put some Domoticz.Log(r.text) after the requests to see what you get from it and modify the script to adapt it to that device