[HELP] Tuya Curtain Robot Bluetooth Integration

Hi all,
I’ve done the “mistake” of buying an alternative to the SwitchBot Curtain on aliexpress:

Integrating it has been a headache because I can find it with the Passive BLE monitor integration, the official Tuya integration, and the Tuya V2 integration but none of them can “call” on the device to make something happen. Only get some status.

Here are the three responses I get from Tuya, Tuya V2, and Passive BLE Monitor:

– Passive BLE Monitor ----------------------- Tuya ------------------------------- Tuya V2 -------------

Tried using the SwitchBot integration, but I can’t get that to work either.
Also tried the Local Tuya integration, but I can only see it in the Tuya Platform and not in HA when trying to discover the device. Probably because it is Bluetooth.
Any ideas?

Think from communication ability perspective. Only your mobile phone with bluetooth has ability to communicate with that device, assuming that there is no support for Bluetooth hub. If this is correct, it would be very difficult to imitate to communicate with that device over home assistant OR someone brave should decode the communication between phone and device, write an integration for it so your home assistant can communicate with it over bluetooth.

Using Local Tuya I am able to talk to it and get information from it. The trouble is actually sending information back. And since my phone can do it, it shouldn’t be anything in the way of my Raspberry Pi doing the same? I can do that with the Xiaomi Mi Flora which also is through a phone app using bluetooth.

Mi Flora and some other passive devices are broadcasting their data publicly and many of them are using same messaging rules, so reverse engineering one solves the rest. It should be called Bluetooth Low Energy (ble).

On the other hand your device requires two way communication and has a different brand than Xiao, definitely using different messaging rules for understanding your commands.

You said that this is a Bluetooth device but localtuya communicates via local network, so it requires an ip address. I am curious how you made it. Do you mena tuya v1 or tuya v2 integrations probably?

Ok, so I will have to reverse engineer the signals somehow using BLE.

Sorry my mistake on the local tuya thing, I can’t find it there because no, it doesn’t have any IP address. But it has a mac address. And it comes up in the Tuya Smart Developer Center as a device where I can get all the information I need for all sensors and such. But sending an actual command to the device, that is where I am stuck. Do you know anything about that @anon63427907 ?

As called out earlier, to send a command to Bluetooth device, some developers should take the lead and reverse engineer the protocol.

MAC address is (probably) unique identifier to manage Bluetooth communication but non-of existing tuya integrations are supporting to communicate over bluetooth.

Maybe you can buy a tuya bluetooth hub which has a dedicated network connection and you would be able to access your device later on.

I stumbled across this the other day while looking at the Tuya IR remote I have. It looks a Tuya bluetooth hub should be coming out soon. Might keep your eye on AliExpress.

https://developer.tuya.com/en/docs/iot/avs-ir-speaker-solution?id=K9wvgcy6gs1sq

The IR remote I have isn’t listed as a supported product in the integration but I have been able to get it to work in HA very easily.

1 Like

I’ve done the “same mistake” buying this product. But to solve this problem, you just need to buy a Tuya Bluetooth Gateway, add the gateway to the SmartLife app, add the motor throw the gateway in the app and use Tuya V2 to control it in Home Assistant. I’m using it this way right now. The only problem is that sometimes there is a delay to actually open/close the curtain, but I guess that this is a problem in how the blueooth connection works in this case.

I just wish that these product was zigbee.

My Tuya Gateway: Moeshouse multi modo inteligente gateway zigbee wifi bluetooth malha hub trabalhar com tuya inteligente app controle de voz via alexa casa do google|Controle de casa inteligente| - AliExpress

2 Likes

i am not sure about pricing of bluetooth curtain motor and bluetooth gateway, but, may be, it is not too late to switch to zigbee or wifi based solution :slight_smile:

You can use the tuya robots Mac with the switchbot curtain custom integration and it’ll show the cover entity with correct status but that’s it. No calls work to the devices unfortunately

1 Like

That’s a step forward :slight_smile:

Also: The Tuya v2 beta integration shows a cover entity for the curtain robot, but you can’t control it as everything is greyed out. I’m hoping once they build out their new[?] API more, they’ll add more features to these entities.

I have the same gateway, added covers to the app, configured Tuya v2 integration in Hassio, but still can not see curtain robot in Hassio. How have you added it in Hassio?

Edited: I figured it out, my Tuya integration was not properly set up. Everything works like a charm.

2 Likes

How did you get this to work? I just got these and the Tuya app shows them but the controls are grayed out

Has anyone ever managed to get these Tuya bluetooth curtain robots integrated?

I have tried blutooth gateways but that did not work.

Whatever I have tried, 99% of the time, they are greyed out. Weirdly, one of mine did seem available for a very short time. It then greyed out again without any action from me and I have no idea why it even showed up as available.

Ideally, it would be great to get battery charge/illumination readings but just opening/closing consistently in HA would be a start.

Aliexpress seem to still be selling them so hopefully some smart tech HA user may be on the case.

I got them to work some times, but they are very unreliable since it seems they have to ‘wake up’ somehow in order to receive information. In the end I gave up and bought SwitchBot Curtain instead which worked without too much difficulties.

It is probably a way to get these Tuya ones to work as well, but with all the work to get it there I don’t think it’s worth it.

Hi, have you had any progress since then?
Have you tried using the bt curtain with this tuya ble integration?

Hi @ferbulous, I ended up giving this project up and buying a SwitchBot because of the easier integration. But I hope this thread helps someone who struggles with the same thing. There were some things I just couldn’t do with the Tuya-enabled curtain robot. Such as calling it to get status and such.

https://github.com/xZetsubou/hass-localtuya
with this dev via gateway it works correctly

2 Likes

If anyone can confirm that @iPilla suggestion works I can mark this as the solution.