Haiku/SenseMe Smart Fan Support

It would be nice to have a component for the Haiku Fans.

I saw that there was this that someone was working on for smart things, but I haven’t seen any working solution yet:

It seems like there is one python implementation out there as well:

I saw a video about Haiku Smart Fan tweeted by Smart Home Solver.

Pardon me for resurrecting the thread (yes, I got a “Review This Topic?” message), but I don’t know if Haiku Smart Fan supports local API access. Whether this smart fan has local API influences my purchasing decisions.

What I saw in the video is incredible, but the lack of local API access will hold me back. It will conflict with me being so security-minded.

It appears as though someone has done some of this work (unofficially) on github: https://github.com/sean9keenan/BigAssFansAPI

Also they have created a homebridge plugin which would be nice to test out. It would be nice for this become a component on hass but I don’t have the necessary coding know-how.

Just installed an L-Series fan and setup the Haiku HomeBridge app and it works great.

I hope someone gets this working with HA!

1 Like

Stumbled upon this the other day:

I tested and it seems to work great.

I run everything through docker so trying to figure out how to convert this into a container. Anyone interested in this, let me know and let’s try to figure this out!

1 Like

I noticed that the L series doesn’t have senseme does the API still work? What can you control through Home-Assistant? Did you end up building a container? I can probably help you out if you haven’t do it yet. I have’t order the fan yet so I wont able to test the container.

I have both an L series with the WiFi module and also the wall control with SenseMe (I don’t think Haiku sells this anymore for the L series).

I am pretty sure both the WiFi and Wall Control units show as 2 separate things using haiku2mqtt, so all you would need is the WiFi module. I can try disconnecting the Wall Control to confirm that since I have not tested it that way.

I tried building a docker container… it looks like it builds fine. I was unsure what the start script should be so I only tested by having it start up bin/bash and then I go in there and manually run the program. Anyways cannot get it to actually work through docker and unsure if its because of using Kitematic to test with or something else.

When I install Node on my laptop, install the program through NPM and run through the command line, it works!

After its running you have access to these MQTT topics:

Which is basically everything.

I have not connected it to Home Assistant yet, but since its using MQTT could use the MQTT Fan and MQTT Light components to control it.

Anyways, I just wanted to put it into a docker container because I use docker for everything and didn’t want to spin up a VM just to run this.

If you send me your Dockerfile I could probably help finish it. Do you have it in github?

Has anyone managed to get this working with Home Assistant? I have two Haiku fans, each with their own wall control units. I would love to be able to control these through Home Assistant!

Not yet but I am looking at buying one of these fans. Currently running hass.io on a Raspberry Pi 3 and I use cloudmqtt to supply owntracks data

After reading the thread above could this be as easy as installing node.js on the Pi then this package (https://github.com/forty2/haiku2mqtt) and pointing to my mqtt broker? The only thing I am concerned about is the example shown for a remote broker only has the host not the login credentials. Can you have more than one mqtt broken with hassio? If so I could start the inbuilt broker and use that?

1 Like

Ok I finally had a closer look at this and the first problem is I cant seem to work out how to install node.js when I am running HASSIO on my Raspberry Pi? Has anyone actually made any progress with getting this to work?

I have been working on a custom component that works with the Haiku SenseMe Fan. The custom senseme hub component supports the fan and light if installed. It should work under all Home Assistant installations including Hassio. Give it a try and let let me know how it works.

This integration has been significantly updated. See this post.


Requires Tom Faulkner’s python library. Occasionally the library fails to communicate with fan and errors are shown in the log. This is also true for the background monitor that updates the fan state every minute or so. Note: Home Assistant/Hass.io will automatically install this library using pip.

1 Like

Dude… yes… it works!

Testing with a Haiku L Series.

Could you just confirm which directories and files you pulled from TomFaulkner and where you placed them?

Thanks for your work on this!

You only add the three senseme.py files for the custom component. Home Assistant will automatically install the SenseMe library from TomFaulkner using pip. After successfully placing the three senseme.py files in the correct directories and restarting Home Assistant you will see the SenseMe library files from TomFaulkner in config/deps/lib/python3.6/senseme.

Thanks I am making progress. No error for the component is generated now when I have a basic entry of just “max_number_fans: 1”

But I am getting this error (I see some reference to lights below and I dont have a light with the fan. not sure if that matters):
2018-07-22 22:21:30 ERROR (MainThread) [homeassistant.helpers.entity] Update for fan.alfresco fails
Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity.py”, line 196, in async_update_ha_state
yield from self.async_device_update()
File “/usr/local/lib/python3.6/site-packages/homeassistant/helpers/entity.py”, line 319, in async_device_update
yield from self.hass.async_add_job(self.update)
File “/usr/local/lib/python3.6/concurrent/futures/thread.py”, line 56, in run
result = self.fn(*self.args, **self.kwargs)
File “/config/custom_components/fan/senseme.py”, line 180, in update
self._hub.update()
File “/usr/local/lib/python3.6/site-packages/homeassistant/util/init.py”, line 318, in wrapper
result = method(*args, **kwargs)
File “/config/custom_components/senseme.py”, line 279, in update
self._light_on = self._device.get_attribute(“LIGHT;PWR”) == ‘ON’
File “/config/deps/lib/python3.6/site-packages/senseme/senseme.py”, line 478, in get_attribute
return response_dict[attribute]
KeyError: ‘LIGHT;PWR’

Edit: I can turn the fan on from HA but the switch in HA immediately moves back to off even though the fan is on,

Having never tested a fan without a light I’m not surprised there is an error like this. The component doesn’t add a light when the fan indicates there isn’t one but the update which is in the hub part of the component still checks light status. I have updated the component on Github. That should fix this problem. Is there another problem…

This integration has been significantly updated. See this post.

I am not seeing the fan now. Not sure of the reason? On the first try an hour ago the fan wasnt detected but then it was after a restart. I have tried restarting multiple times now.

I have tried this:

senseme:
  max_number_fans: 1

and this:

senseme:
  max_number_fans: 1
  include:
    - "Alfresco"

I take it there are no errors in the log and you have looked at the states developer tool for any fan that might be your senseme fan. Try adding some logging statements to the senseme.py on the custom components directory (not fan or light directories).

Like this logger statement on line 85 which will put a warning “Found fan: ‘Living Room’” in the log.

line 84: newHub = SenseMeHub(newDevice)
line 85: _LOGGER.warning("Found fan: '%s'." % device.name)
line 86: if newHub.group: