The NOOB-IEST NOOB Broadlink RM

So I installed Assistant on my RPI and can successfully login.

I then edited the configuration.yaml file to include the language for RM Broadlink and amended the IP Address and MAC Address for my device.

Now I would like to control a Hunter Douglas Fan/Light that I can currently control using the e-control app on iOS.

How do I sniff the codes for on/off for the lights and fan?

I followed the instructions by going into Developer Tools to call for a service, selected Broadlink and ‘Call’ and then selected a command from e-control, but nothing after that…

I think I’ve read the instructions incorrectly.

in stead off selecting a command from e control you should use the remote from the lights or fan so the broadlink can give the code to HA.

the other way is to use the import method from the econtrol files.

So… just so I understand. Go into HA as the instructions state… hit ‘CALL’ then use the RF controller and turn on the light?

Where do I look for the code to copy back into configuration.yaml

thats the way and the code will show up in the HA log and as persistant notification.

Great! Where is the log, I see all sorts of things in the web GUI but not a log showing me details of everything.

info beneath developers menu on the left side

Yup… complete NOOB

The only thing I see is the (i) icon which is ‘About’ which does not seem to show logs, but rather errors.

that is your log (a log can contain errors :wink: )

and as it seems you have done something wrong in the yaml making that the broadlink isnt connected to HA correctly.

gotcha… let examine that again. Thank you for your help.

1 Like

the first time you connect your broadlink you dont have any switches so the yaml should look like:

  - platform: broadlink
    host: your_ip
    mac: 'your_mac'
    timeout: 15

after you have recieved a code it should look like

  - platform: broadlink
    host: your_ip
    mac: 'your_mac'
    timeout: 15
    switches:
      kaarsen_aan:
        friendly_name: kaarsen aan
        command_on: 'a_recieved_code'
        command_off: 'a_recieved_code'

So this is what my configuration file looks like:

# Example configuration.yaml entry
switch:
  - platform: broadlink
    host: 192.168.7.170
    mac: '34:ea:e7:e6:f4'
    timeout: 15

When I make the call and turn on the light this is the log:

2017-07-13 00:50:57 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/usr/lib/python3.4/asyncio/tasks.py", line 233, in _step
    result = coro.throw(exc)
  File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/core.py", line 1023, in _event_to_service_call
    yield from service_handler.func(service_call)
  File "/srv/homeassistant/lib/python3.4/site-packages/homeassistant/components/switch/broadlink.py", line 75, in _learn_command
    auth = yield from hass.async_add_job(broadlink_device.auth)
  File "/usr/lib/python3.4/asyncio/futures.py", line 388, in __iter__
    yield self  # This tells Task to wait for completion.
  File "/usr/lib/python3.4/asyncio/tasks.py", line 286, in _wakeup
    value = future.result()
  File "/usr/lib/python3.4/asyncio/futures.py", line 277, in result
    raise self._exception
  File "/usr/lib/python3.4/concurrent/futures/thread.py", line 54, in run
    result = self.fn(*self.args, **self.kwargs)
  File "/home/homeassistant/.homeassistant/deps/broadlink/__init__.py", line 175, in auth
    response = self.send_packet(0x65, payload)
  File "/home/homeassistant/.homeassistant/deps/broadlink/__init__.py", line 217, in send_packet
    packet[0x2f] = self.mac[5]
IndexError: index out of range

Your mac address is wrong. It must have 6 sets of 2.

XX:XX:XX:XX:XX:XX

1 Like

good catch, i would never have noticed that.

1 Like