Holman WiFi Tap timers intergration?

Thanks @funtastix & @NeriedAU and everyone else who’s contributed on this. It’s working well for me.

I did try a few of the no name ZigBee water controllers and while the ZigBee part worked fine, the actual water solenoids were rubbish.

The Holman units seem to be good quality.

@funtastix could you please post the relevant part of your /config/.storage/core.config_entries file?
I’d like to add in those extra DPS’s.

It’s all posted up at post 147 or 148. I am thinking of reorganising my setup a bit and just making one config file per unit. Today I’ve been able to make a template switch to turn on and off the timers, proving the concept that it can all be controlled from HA. I’m thinking of putting up a GitHub repo or contributing to the NeriedAU one to describe my full approach. I’m still working on getting the changes back into the main localtuya, but there’s a problem with multiple devices that I’m stuck at.

I’ve uploaded my full approach into a branch on my github here:

3 Likes

Hey folks - bit late on this one. I’ve been using the WX1 taps for a while (not yet integrated into HA). Was at Bunnings yesterday and saw the Bluetooth only version (BX1 and BX2). I was wondering if it would be possible to integrate those directly into HA if it’s close enough to my Raspberry Pi (I also have some of the ESP32 Bluetooth Relays as well).

Has anyone managed to do that?

1 Like

@deanpribetic so; you might face a few issues with discovery, as well as reverse engineering whatever bluetooth protocol is in use.
Not impossible, but with the localtuya/wifi versions you have at least the Tuya protocol for read values, push values and the mapping in this thread.
It’s a fair bit of work even with that however!

1 Like

Hi all, if you’re after a super simple and straight-forward way to integrate the Holman tap timers into Home Assistant like I was then use the following video from Lewis at Everything Smart Home to get it working through Google Home. Now, you have to use input booleans to manually set the status of the tap (e.g. running) in HA but I’m happy with that as a bodgy workaround for very little effort in terms of setup. Now I have a nice and easy button on my dashboard or I use automations to turn the sprinkler on and off accordingly. Hope that helps anyone who has been bashing their head against the wall trying to get these working (I have the WX1). If you don’t have Google Home then I don’t know how to help you.

3 Likes

Hi.
I’d like to add the socket to HA as well as the WX1. I have the CID for the socket - but what DPS are associated with the socket?
Thanks for all your work on the WX1 - excellent stuff.

Hi all. Thanks to all previous posters for their work on decoding the DPs on this. The tuya-local integration via HACS now recognises the WX1 Tap Timer. See the PR here Create holman_wx1_taptimer.yaml by Brazen00 · Pull Request #979 · make-all/tuya-local · GitHub. I did not get the full functionality to work, as tuya-local does not have a set_dp service, but the basic functionality is there.

1 Like

Hi All,
I’m fairly new to this, but managed to get my WX2 working after a few hours effort. Thought i’d share the things I got caught on as others might find it handy:

  1. I used @NeriedAU fork of Local Tyua (Thanks Ash), having previously had installed the rospogrigo fork I had some trouble when switching over to NeriedAU’s version. I ended up resolving this by deleting the LocalTyua folder from \custom_components and rebooting my HAOS device completely.
    After copying the new version back into custom_components and re installing, I was trying to verify it was indeed the NeriedAU’s version. Clicking the ‘Documentation’ button in the LocalTuya integration actually took me to rospogrigo’s github fork. It looks like the documentation link may not have been updated as a part of the fork. I note on my install the ‘do not configure a cloud api account’ is unticked by default, which was an indicator I was now using the correct version.

  2. I was having trouble locating the ‘CID’ value for my tap timer. I couldn’t find clear instructions how to get Tuya-cli installed/working, but ended up finding the value using the Tuya IOT platform ‘Industry Basic Service’ API via the dev website, under ‘Industry Devices Management’ > ‘Get Device Information’ and checking the device_id of the timer itself, I located the ‘Node_id’ value, which works as the CID. In my instance the socket was 01B and the tap timer 011.

  3. Once I entered the correct CID and added the device in LocalTuya, I souced a list of the dp_id’s using the ‘query properties’ API under Tyua IOT Platform > Device control.

Thanks for the tips @danielcheney

Just for the ease of anyone else using the WX2, the dps values are

{
  dps: {
    '101': 0,
    '102': 0,
    '103': 0,
    '105': '2',
    '106': '0',
    '107': 15,
    '108': true,
    '113': '0',
    '114': '24',
    '115': false,
    '117': false,
    '119': '1',
    '120': 0,
    '125': false,
    '127': 'HOLxxxxx-xxx-xxx-xxx',
    '150': 0,
    '151': 0,
    '152': 25,
    '153': '3',
    '154': 10,
    '155': true,
    '160': '24',
    '161': false,
    '162': false,
    '166': false
  },
  cid: 'C21'
}

unfortunately it seems that the CIDs are different between people so one will need to them themselves (using ether tuya-cli or the above instructions for Tuya IOT platform)

As far as the DPS values for the wx2, it appears that the second valve has the same values as valve 1 + 49 (e.g. 101 on valve one is 150 on valve 2)

I’ve switch all my devices from LocalTuya to a more robust one on HACS TuyaLocal, don’t get the two confused, they are very different.
Once the device is in the library of devices any user can use the config that is already defined, no need to guess what ID’s do what.
I know for a fact that the device “holman_wx1_taptimer” is already available to use.
Just a note, you must delete the LocalTuya device before using it with TuyaLocal.
Just need the usual, Device IP address, Tuya Device ID and Tuya Local Key.
Give it a go.

Anyone able to give me any information on an alternative to the Holman wifi hub. Mine took a power spike which killed it and Holman do not supply hub separately.

1 Like

Unfortunately the wx1 and wx2 use a proprietary signal to connect to the hub so I don’t think there are any alternatives to the hub itself.

If there aren’t any on the secondhand market, getting a wx1 with a hub and selling the wx1 is probably your best option. Otherwise you will need to replace the timer and hub with another brand.

For the WX2 owners out there. I’ve gone with a “tuya-local” approach. I’m not sure on the pros & cons of tuya-local vs local tuya, but upon seeing that a only device file needed to be created seemed to be the path of least hassle/resistance for me. Have put my device file in a gist. It works as is for me but I’m sure some of the other dps values might come into play when other sensors are deployed etc. I’ll refine it over the coming days…

For anyone following at home, have raised “new device” request.

Hey, thanks for putting this together. I’m trying to add my WX2 now. Installed the HACS integration, have the local keys, and downloaded your gist to the devices folder. When I add it in the UI, it doesn’t pick up the device and gives an option of one of these three

Is there anything else I need to do to add a new device to the tuyalocal integration?

Here is my tuya-cli get output:

{
  dps: {
    '101': 0,
    '102': 0,
    '103': 14,
    '105': '2',
    '106': '0',
    '107': 25,
    '108': true,
    '113': '0',
    '115': false,
    '117': false,
    '120': 0,
    '125': false,
    '127': 'HOL9H007-062-055-000',
    '150': 0,
    '151': 0,
    '152': 27,
    '153': '0',
    '154': 25,
    '155': true,
    '160': '0',
    '161': false,
    '162': false,
    '166': false
  },
  cid: '991'
}

Side note, the product id seems to be different for me. I tried changing it but it didn’t help.

{
  "result": [
    {
      "active_time": 1695509296,
      "category": "wg2",
      "create_time": 1695444492,
      "custom_name": "",
      "icon": "smart/icon/ay1556838860681oKmdO/1746f926ee7e6541d8188bf6ec32801f.png",
      "id": "xxx",
      "ip": "xxx",
      "is_online": true,
      "lat": "xxx",
      "local_key": "xxx",
      "lon": "xxx",
      "model": "Emate gateway",
      "name": "Wi-Fi Hub",
      "product_id": "v9vxvkwqa48ayhlr",
      "product_name": "Wi-Fi Hub",
      "sub": false,
      "time_zone": "+10:00",
      "update_time": 1695509296,
      "uuid": "xxx"
    }
  ],
  "success": true,
  "t": 1695514650101,
  "tid": "xxx"
}

Howdy - that product_id matches my Hub. I assume the product_id in my gist matches your actual timer tap? FYI - that Garza is the one that mine default maches too. I assume you added the holman_wx2_taptimer.yaml to the devices folder and restarted?

Easiest way to debug is to turn on debugging for the add-on - it makes it pretty easy to see what the issue is.

logger:
  default: info 
  logs:
    custom_components.tuya_local: debug

Feel free to post your debug output here (should just need to look at the Holman WX2 Tap Timer lines when it is trying to match) - maybe screenshot the tuya-local add integration screen too.

@FrontBottom Oh nice one thanks! Yep, confirming the actual tap is the same id.

Going to give it a go with the debug and see what happens. :crossed_fingers:

EDIT: Found the culprit from the log:

2023-09-24 15:16:05.586 DEBUG (MainThread) [custom_components.tuya_local.helpers.device_config] Not match for Holman WX2 Tap Timer, missing required DPs: [{'114': 'str'}, {'119': 'str'}]

My DPs did not contain 114 (12/24 time setting) and 119 (metric/imperial units). So I toggled both of those settings in the app and it worked!

This was outright the most painful integration ever, thanks all for the wealth of information in this thread, finally got there!

Here are some notes for what I needed to do:

  1. Create the iot developer account as per https://github.com/codetheweb/tuyapi/blob/d88fd6c84b228b42f0b6aedd84f0ac3cdb1a5523/docs/SETUP.md
  2. Link SmartLife app in the iot backend (could be the Tuya app too)
  3. Add the plug manually in the SmartLife app (it wouldn’t automatically detect for me). Used one of the zigbee gateways and it managed to find it. I suspect there may be more than one gateway that you can choose, it’ll pick up the right one anyway.
  4. Install tuya-cli and go through the wizard to get the local keys and the device CID
  5. Toggle the 24H time setting and the Metric/Imperial setting in the app
  6. Install tuya-local in HACS
  7. Copy the WX2 timer YAML file from the gist into Home Assistant /config/custom_components/tuya_local/devices directory (if it doesn’t exist already)
  8. Add the tap timer in tuya-local (Device id from the hub, Local Key of the hub, CID of the tap timer).

Nice - looks like 114 & 119 will need to be made optional too. Will add that to the issue.

(For others reading your steps - for step 6.5, don’t forget to copy the new device file into the tuya-local devices folder and restart!)

@FrontBottom Cheers. True indeed, will update the steps :ok_hand: