[APP][Pro] Tuya Zigbee App

Hi, l will try below, but would like to create a very big disclaimer: I’m not experienced with Github or driver/software development at all and was just trying stuff, accepting the fact that I might break something in my Homey configuration and needed to rely on a backup (or worse). So I will write down what I did, but it’s at your own risk :upside_down_face: .

In my case there was already a driver for my device, but the model number was not mentioned in the driver. Oh and I am using the test version of the Tuya app on my Homey Pro '23.

Step 1:
Interview your device in the Homey developer view.

Step 2:
Copy the interview results. In my case the manufacturer and model information were most relevant:
Manufacturer: _TZ3000_wkr3jqmr
Model-id: TS0004

Step 3:
Went to the Github site of the Tuya App and found comparable requests/issues. I added my request to the existing issues. Hoping that the developer would eventually integrate my device in the official software/drivers.

Step 4:
Browsed to the “<> Code” section of the github of the Tuya app and selected “SDK 3 - default”

Step 5:
Browsed to the drivers folder of my device: /drivers/relay_board_4_channel https://github.com/JohanBendz/com.tuya.zigbee/tree/SDK3/drivers/relay_board_4_channel

Step 6:
There are 4 driver files in this folder. I opened and read each one of them and found the model types definition in “driver.compose.json”:

"zigbee": {
      "manufacturerName": [
        "_TZ3000_hdlpifbk",
        "_TZ3000_excgg5kb",
        "_TZ3000_u3oupgdy"
      ],

Click the pencil on the top right side of your screen “edit the file in your fork of this project”. This will create a “personal copy” of the app/driver in Github.

Step 7:
Added my “manufacturerName” to the list (beware of the " and , in the list):

     "zigbee": {
      "manufacturerName": [
        "_TZ3000_hdlpifbk",
        "_TZ3000_excgg5kb",
        "_TZ3000_u3oupgdy",
        "_TZ3000_wkr3jqmr"
      ],

Click “Commit Changes”, give it a name/description and “save changes”.
Click “Create Pull Request”.

I believe this will create a fork of this project in your own github space.

Step 8:
Go to your personal fork and check if the committed changes in the driver are still there. I don’t know why, but in my case I had to redo the changes in my own fork.

From this point I continued with @robertklep’s suggestions:

Step 9:
Click the “<> Code” option and select “download zip”.
Save the zip to a convenient location on your computer and unzip it. I placed it directly in C:\ because that makes step 11 a little easier in Windows 11.

Step 10:
Install Homey CLI following the instructions.

This requires some additional steps of installing and authorizing the CLI on your homey. Just follow the instructions.

Step 11:
Open a command prompt in admin mode (windows 11) and browse to the unzipped folder with the complete Tuya app and drivers on your local computer.
Within this folder you’ll find a “homey app install” file.
Run this file.

Step 12:
I restarted the Tuya app on my Homey, paired the device and it was found and installed.

Step 13:
Walk to the fridge and get yourself a beer, you’ve just been able to create your own driver within Github (without really understanding what you just did). :innocent: :nerd_face: :joy:

Oh and one final remark. I really don’t know what happens if the Tuya Zigbee app gets an official update. I think it will overwrite my own driver which might break my device’s functionality if it was not included in the official app. Does anyone know if that will happen and how to prevent that?

3 Likes