"Thread border router required" with Eve and Matter

Maybe to recap (sorry I often run out of time to go back through the Thread to figure out what the state of things are), is that

  • You have a device on an Apple Home Thread network and you are trying to use HA Matter to add this device.
  • The Matter log says during commissioning it is trying to reach a device for commissioning that has ip6 address fd9c:b44b:422f:0:8f13:c397:d8b:78a5 but the Matter server can’t reach it, so the commissioning fails.
  • OTBR logs says it is getting routes advertisements from 3 routers
    • Received Router Advertisement from fe80:0:0:0:3e7c:3fff:fee4:9e80 on infra netif 2
    • Received Router Advertisement from fe80:0:0:0:14e4:bea2:c94e:8fdf on infra netif 2
    • The 3rd router’s Router Advertisement does not contain routes (only PIO), so we can ignore it
  • Looking at various places in the log, it is the second router that is advertising the route of interest
    • Processing RIO (fd9c:b44b:422f:0::/64, 1800 seconds)
  • Sometime later the OTBR is sending Neighbor Solicitations to these two routers, and neither are responding and it removes the route of interest:
    • No response to all Neighbor Solicitations attempts from router fe80:0:0:0:14e4:bea2:c94e:8fdf.
      ExternalRoute fd9c:b44b:422f:0::/64 - State: Added -> NoEntry
    • No response to all Neighbor Solicitations attempts from router fe80:0:0:0:d9f1:8d3a:a4e1:628a

So the question (I think) is why is the router (most likely the Apple TBR) whose LLA is fe80:0:0:0:14e4:bea2:c94e:8fdf dropping out and reappearing?

My first thought would be to go to a different linux machine on the same LAN and ping that address to see if there are any drop outs. For Ubuntu:
$ ping -6 -D -i 10 fe80:0:0:0:14e4:bea2:c94e:8fdf -I <Interface-name>
Since this is a link local address, the ping command requires you specify which interface to send the ping out over, for example eth0.
This should ping the offending router every 10 secs and provide a timestamp. I would say check it after several minutes to see if intervals were skipped.

If this looks ok, then I would go into your HA probably any shell will do and try pinging that same link local address periodically. My HAOS’s ping command doesn’t appear to have a lot of bells and whistles, the -D -i flags don’t seem to be supported and using then provides no output (even for failed pings)…which can be confusing because a positive ping also has no output, whereas a failed ping does.

@wmaker I need to buy you a beer (please replace with whatever beverage or similarly-valued product would be appropriate).

As it turns out, one of my IPv6 addresses was mysteriously missing from the configuration, and the routes couldn’t properly function. Since HA does keep the network interface’s details even after network changes, it stands to reason that, while the routes would form correctly from the point of view of HA, they would not match with the OS-level routes, and packets would be promptly dropped. It’s probably a lapse of judgement on my part, but that appears to be what the problem was.

It was due to your prompting that I got to investigate routes, so, like I said, I owe you one.

Sooooooo… did you manually change the host routes? What is the correct user-servicable action here? I think I’m in the same boat, but don’t know what to do.

(I’m on HAOS, if that matters)

1 Like

I finally managed to connect my Eve motion sensor using these instructions combined with using bluetooth on my home assistant device (an Intel NUC). At first it didn’t work using my iPhone, only after placing the Motion Sensor next to the Intel NUC I managed to connect it to Home Assistant using the instructions. It has been stable for a couple of days now on several places in the house.

Where do i get my own dataset?
Thanks

Here (See my screenshot):

Hello beautiful people, i just added my Eve Energy (updated to Matter) in Home Assistant.

UPDATE Eve Energy to Matter :
Use Eve iphone App, go in the Eve Energy Device settings, and the Eve app will propose you to upgrade Eve Energy to Matter. Save new Matter QR Code needed later to add it in the Apple Home.
Once updated to Matter, go in the Apple Home app > add new device > scan new QR Code > your Eve Energy is added to Apple Home.
Next how to add it to Home Assistant :

WORKED WELL :
1/ Apple Home app on iphone - enable pairing mode
Select Eve Energy device > settings (in the bottom of the page) > Turn On Pairing Mode
2/ Home Assitant on iPhone
It did not work on the PC but worked well from the iPhone Home Assistant App (because Bluetooth involved at some point ?).
Home Assitant on iPhone > Integrations > Add Integration blue button > Add Matter device > Eve Energy is detected and proposed > next > next > next : it’s added.
Now you see your device in the Matter section in Home Assistant.

DID NOT WORK :
I have my Apple TVs and HomePods in the Thread section with message " You don’t have a preferred network yet." and the button “Add an open thread border router”.
But there is no need to do anything in the Thread section to make your Matter Eve Energy work in Home Assistant.
Also i tryed first ADD ENTRY button in the Matter section from the wab page on PC, but it does not work like this. You must use iPhone Home Assistant app to add your Matter devices as described above.

IPV6 WARNING with Matter :
Because i have two internet boxes (fiber + cellular when fiber breaks) i have router with dual wan,
i discovered that matter uses ipv6 and when my fiber fails and i am on the cellular box, ipv6 doesn’t work so all Matter devices are “Unawalable” in Apple Home and Apple devices can not reach internet because i have static ipv6 setup to my fiber router (via my GT-AXE16000 asus router).
So Matter adds new problems linked to ipv6, and you should not go matter if you could have ipv6 issues at home.

Best regards :slight_smile:





Hello!
I’m trying to get my feet wet with matter via thread and purchased a SkyConnect as well as an eve Motion (Matter) sensor. I followed the instructions listed here:

https://skyconnect.home-assistant.io/procedures/enable-multiprotocol/

… and everything looks like it does in the screenshots.

But when I try to add my eve device using the iOS app as described here:

I get from this screen:

to this screen:

… unless I reset the eve sensor (by using a pin to hold down the reset button for 10 seconds). Then, I get this result:

… As far as I can tell everything is configured correctly. Can anyone tell me what I’m doing wrong?

I read above about websockets and the like but that goes well beyond my skill level. I feel like I’m close to getting it working, no?

Any help would be greatly appreciated!

Best regards,
Andrew

You don’t need a high skill level. I can can assist you. Does your Homeassistant server have Bluetooth?

Thanks KolBusa for your swift response. It’s a Home Assistant Yellow, I believe the RPi CM4 that powers it has Bluetooth…

Ok, if your raspi has wlan it will also support bluetooth.
First, we need to access the thread dataset value from the thread integration.
Settings → devices & services → Thread → Configure → little i

Here’s the same screenshot from my installation:

How do you get the pairing code which need to provide in the second step? I see the label on my eve devices (homekit code, qr and some long letter and numbers), but none of them works. I don’t have apple device with thread to migrate my devices to matter in eve app

1 Like

Now step 2:

We need:

  • our locl homeassistant network address. (my: 192.168.2.130)
  • A Browser browsing our homeassistant (my: 192.168.2.130:8123). This tab is focussed
  • On this page we open the development tools of the browser (key F12) and switch to “console” tab in the development tools
  • there we can start with step 2: Talking to the matter server and sending it the thread dateset via websocket. Therefore you can paste this into the console. Please change network address and thread dataset. And post here a screenshot of your result.
var socket = new WebSocket("ws://192.168.2.130:5580/ws");
socket.addEventListener("message", (event) => {
    console.log("Message from server ", event.data);
});

socket.addEventListener("open", (event) => {
    console.log("WebSocket is open");
    var message = {
        "message_id": "1",
        "command": "set_thread_dataset",
        "args": {
            "dataset": "0e080000000000010000000300000b35060004001fffe0020823890fd24ab1fb3d0708fd32b595bafdd8d30510d4b788583c85b27e2463f14f248fe94b030e686f6d652d617373697374616e74010263e30410bbe3fea1a3a4db87a91b276b3aba21ca0c0402a0f7f8"
        }
    };
    socket.send(JSON.stringify(message));
});

1 Like

For step 3 we need the pairing code. My eve motion device has on the bottom a sticker with four things:

  • matter logo with “matter”
  • qr code
  • paring code (my: 3084-602-3139) ← we need this
  • another code

Method 1:
Sell your device and buy a matter-ready eve device.

Method 2:
Buy an iphone and a homepod so you can apply the matter update to your eve device. Alternative visit a friend with this setup and do it there.

1 Like

Hi!

So far so good…

I have the pairing code, as well…:

What’s the next step?

Edit:
Your value of thread_credentials_set is false. Maybe this will be a problem…

Good!
Bring the eve device in range of the bluetooth signal of your rapsi. And we hope, that your bluetooth is working…
In step 3 you will commission the matter server with the eve device matter pairing code, like this (just change the network address and post result here with a screenshot):

var socket = new WebSocket("ws://192.168.2.130:5580/ws");
socket.addEventListener("message", (event) => {
    console.log("Message from server ", event.data);
});

socket.addEventListener("open", (event) => {
    console.log("WebSocket is open");
    var message = {
        "message_id": "2",
        "command": "commission_with_code",
        "args": {
            "code": "33976113343"
        }
    };
    socket.send(JSON.stringify(message));
});
3 Likes

Done:

thread_credentials_set is now true.

… but a few seconds later, this appeared:

… I assume the CM4 is w/o wireless/BT. :frowning:

I was sure that I had BlueTooth since I paired some flic-buttons to my HA, but I know remember that this was using a different Pi as a Bluetooth-proxy.

I have several other Pis flying around. Could I run this procedure on a different instance of HA? Or I could purchase a bluetooth dongle (USB)…? Or maybe using an ESP32 as bluetooth proxy via esphome?

Best regards,
Andrew

Bluetooth dongle should work. You could also borrow one from a neighbor, because you need it only for commission. I haven’t tried the other methods (ESP32, Bluetooth-Proxy).

You can go to http://192.168.2.130:8123/config/hardware (change to your network address) and click “ALL HARDWARE”. There you can search for “blue”. This is my result:

So I know that Bluetooth is running on my Homeassistant server.