RFLink Help

Hi there,

Can someone help me with this RFLink configuration issue? I cannot work out where I’m going wrong!

I’m running Home Assistant (0.105.5) off a NUC. I also have a raspberry Pi 3B in another room, which has an 866 Mhz RFLink module and Arduino Mega board connected to it over USB. I bought this as a kit, pre-soldered from nodo-shop - so it should be all good (I don’t trust my own soldering skills). I have flashed this RFLink board to the latest firmware using “avrdude” (version R47), confirmed ok. Both the NUC and the Pi are connected over Ethernet to the same network, and assigned static IP from the DHCP pool.

With that in place, I have done the following:

  1. Logged onto the Pi and run the following command:
socat /dev/ttyACM0,b57600 TCP-LISTEN:8844,reuseaddr
  1. Gone into HA and added the following lines to my configuration.yaml:
# 866Mhz RF Devices using RFLink (ArduinoMEGA)
rflink:
  host: 192.168.10.242 #this is the static IP of the raspberry Pi 3B
  port: 8844

Result? I’m seeing this in my HA logs. I can see HA fails to connect to the Pi, so what am I missing?

Error connecting to Rflink, reconnecting in 10
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/rflink/__init__.py", line 234, in connect
    transport, protocol = await connection
  File "/usr/local/lib/python3.7/asyncio/base_events.py", line 958, in create_connection
    raise exceptions[0]
  File "/usr/local/lib/python3.7/asyncio/base_events.py", line 945, in create_connection
    await self.sock_connect(sock, address)
  File "/usr/local/lib/python3.7/asyncio/selector_events.py", line 473, in sock_connect
    return await fut
  File "/usr/local/lib/python3.7/asyncio/selector_events.py", line 503, in _sock_connect_cb
    raise OSError(err, f'Connect call failed {address}')
ConnectionRefusedError: [Errno 111] Connect call failed ('192.168.10.242', 8844)

pardon but the latest is 0.48 :wink:
Is what you’re trying to do is a standard way as described in HA docs?
I think you either connect your RFLink to RPi (which runs HA) via USB (I use this method) or via some sort of TCP interface (there are many implementations, haven’t tried them myself).
In your case what’s on the RPi?

Hi @AhmadK,

My Home Assistant NUC is in my loft/attic, too far from where I have RF devices. The Raspberry Pi is in the same room as the RF kit. In the HA docs (https://www.home-assistant.io/integrations/rflink/) it does document a “host” configuration variable, which uses the setup I’ve outlined. This should allow HA to connect to RFLink over the network, rather than having the RFLink kit directly connected to HA over USB.

yes, but I still don’t know (as I pointed earlier, there are many different ways to do that)

Morning @AhmadK,

The pi is running a stock install of Raspbian (buster). The Pi is only running the socat command, it performs no other functions. The CPU, RAM and Storage are all fine.

Cheers,
Chris

Oh, I see. Not so familiar with Linux either so can’t help… :
The only suggestion is to check somehow if your board is actually working - by installing HA on RPi’s SD and configuring RFLink locally.

Did you just copy the socat line from the documentation, or did you verify first that your RfLink is connected to /dev/ttyACM0 ?

Hi Francis,

It’s definitely connected to /dev/ttyACM0 … I just used the path to upgrade the RFLink firmware to the latest version!

C.

This is looking to be a bit of a lost cause. Can I frame the question another way … how are you controlling 868MHz based RF devices? I can turn to a broadlink hub for 433Mhz, but I need to cover the 868MHz band as well.

You can always connect your Rflink to an esp and use this :