Tuya device programming can be extremely frustrating. The devices are produced by thousands of different OEMs, and absolute compatibility is not guaranteed. I have been banging my head against a wall trying to get a thermostat to work properly–even though there is device support in Apilio to set the temperature, it isn’t working as advertised (I can currently only set the temperature to the nearest 2.5C). Whether this is a fault with Apilio or how the device specifies the services it supports I am not sure (and don’t really care), but what I do know is that it IS possible to program the device to do what I would like it to–I just can’t do it (quite) in Apilio.
There are also other frustrating things that I have come up against that would be good to find a solution for–Tuya smart lamps don’t seem to support setting their colour (even from within Smart Life itself!), which is absolutely bizarre given that is the main reason for having a coloured smart light bulb.
Having played around with the Tuya cloud programming interface, I have a suggestion for two things that it would be brilliant for Apilio to add (for all Tuya devices, irrespective of type), which would make all my headaches go away (for the moment, anyway!).
Support the generic Tuya “Send commands” command. This takes a JSON command string that allows you to do anything with a Tuya device. For my specific issues, it would allow me to set the temperature of my thermostats and also to specify the colour of my smart bulbs. To create this interface would be very easy for the Apilio developers as it is a pre-built command that just takes a string argument. Users would obviously have to be careful what they actually passed as the string, but it onus would be on the Apilio users to use this with care.
Support the generic Tuya “Get the status of a single device” command. If this could be done to return the output string from that command into a string variable of your choice, then it would be possible to extract values that are extremely useful yet not supported in the current interface. Going back to my headaches, for my thermostats this would let me read the current temperature; for my smart bulbs I could get the current colour.
I know that each of these are standard Tuya commands and so cannot be hard to implement given that Apilio is already making similar calls. They are easily prototyped for any device in question within the Tuya cloud developer environment, which is why I know for certain that if I had access to these calls I could get my devices to function as required. However, the way that Tuya works it is essentially impossible to replicate these calls from Apilio using web hooks.
Is there any chance of implementing these? Please? I’m sure they would enhance Tuya programming for lots of people…