Always "ha-thread-b862"

I have installed another Aqara U200 unit without any major problem in another instance of Home Assistant

When I try to add to the network the message appears:

  1. “Connecting to the device”
  2. “Generating Matter credentials”
  3. “Checking the connection to the XXX network”

and fail…

Could not connect to network Thread “ha-thread-b862

The interesting thing is that my newly created Thread network is not called this way

image

At first I thought that using multiple servers would cause a problem, so I removed the rest of the servers and only left one, deleted the mobile application data and reinstalled from scratch. Same problem and still showing the wrong network name.

Both using Sonoff ZBDongle-E with only OpenThread RCP firmware v4.4.4

Another test:

  • Only 2.4Ghz on the Wi-Fi network.
  • Companion App > Troubleshooting > “Sync Credentials in Thread”
  • Enable/disable IPv6 HA, Router…

Any suggestions?

Thread debug:

2024-10-24 10:35:36.166 DEBUG (MainThread) [homeassistant.components.thread.discovery] add_service Home Assistant OpenThread Border Router #8122._meshcop._udp.local.
2024-10-24 10:35:36.166 DEBUG (MainThread) [homeassistant.components.thread.discovery] _add_update_service Home Assistant OpenThread Border Router #8122._meshcop._udp.local. AsyncServiceInfo(type='_meshcop._udp.local.', name='Home Assistant OpenThread Border Router #8122._meshcop._udp.local.', addresses=[b'\xac\x1e\xe8\x01', b'\xac\x1e \x01'], port=49154, weight=0, priority=0, server='domo.local.', properties={b'rv': b'1', b'id': b"U\x02\\T\xce'\x8d\xba\x1a\xd9o&\x04\xdd\xb3\r", b'vn': b'Home Assistant', b'mn': b'OpenThread Border Router', b'nn': b'ha-thread-d9cc', b'xp': b'\xcb\x1dd\xa5\xe0\xe6\xe0\xdc', b'tv': b'1.3.0', b'xa': b'\xaa\xb3 g\xde\x96\x81"', b'sb': b'\x00\x00\x07\xb1', b'at': b'\x00\x00\x00\x00\x00\x01\x00\x00', b'pt': b'\x8d\xb0\xbfs', b'sq': b'O', b'bb': b'\xf0\xbf', b'dn': b'DefaultDomain', b'omr': b'@\xfd(\x92\xa2\xf8v\x00\x01'}, interface_index=None)
2024-10-24 10:35:36.167 DEBUG (MainThread) [homeassistant.components.thread.discovery] Failed to decode state bitmap in service AsyncServiceInfo(type='_meshcop._udp.local.', name='Home Assistant OpenThread Border Router #8122._meshcop._udp.local.', addresses=[b'\xac\x1e\xe8\x01', b'\xac\x1e \x01'], port=49154, weight=0, priority=0, server='domo.local.', properties={b'rv': b'1', b'id': b"U\x02\\T\xce'\x8d\xba\x1a\xd9o&\x04\xdd\xb3\r", b'vn': b'Home Assistant', b'mn': b'OpenThread Border Router', b'nn': b'ha-thread-d9cc', b'xp': b'\xcb\x1dd\xa5\xe0\xe6\xe0\xdc', b'tv': b'1.3.0', b'xa': b'\xaa\xb3 g\xde\x96\x81"', b'sb': b'\x00\x00\x07\xb1', b'at': b'\x00\x00\x00\x00\x00\x01\x00\x00', b'pt': b'\x8d\xb0\xbfs', b'sq': b'O', b'bb': b'\xf0\xbf', b'dn': b'DefaultDomain', b'omr': b'@\xfd(\x92\xa2\xf8v\x00\x01'}, interface_index=None)
2024-10-24 10:35:38.437 DEBUG (MainThread) [homeassistant.components.thread.discovery] update_service Home Assistant OpenThread Border Router #8122._meshcop._udp.local.
2024-10-24 10:35:38.438 DEBUG (MainThread) [homeassistant.components.thread.discovery] _add_update_service Home Assistant OpenThread Border Router #8122._meshcop._udp.local. AsyncServiceInfo(type='_meshcop._udp.local.', name='Home Assistant OpenThread Border Router #8122._meshcop._udp.local.', addresses=[b'\nZ\x00\x0f', b'\xac\x1e\xe8\x01', b'\xac\x1e \x01'], port=49154, weight=0, priority=0, server='domo.local.', properties={b'rv': b'1', b'id': b"U\x02\\T\xce'\x8d\xba\x1a\xd9o&\x04\xdd\xb3\r", b'vn': b'Home Assistant', b'mn': b'OpenThread Border Router', b'nn': b'ha-thread-d9cc', b'xp': b'\xcb\x1dd\xa5\xe0\xe6\xe0\xdc', b'tv': b'1.3.0', b'xa': b'\xaa\xb3 g\xde\x96\x81"', b'sb': b'\x00\x00\x07\xb1', b'at': b'\x00\x00\x00\x00\x00\x01\x00\x00', b'pt': b'\x8d\xb0\xbfs', b'sq': b'O', b'bb': b'\xf0\xbf', b'dn': b'DefaultDomain', b'omr': b'@\xfd(\x92\xa2\xf8v\x00\x01'}, interface_index=None)
2024-10-24 10:35:38.439 DEBUG (MainThread) [homeassistant.components.thread.discovery] Failed to decode state bitmap in service AsyncServiceInfo(type='_meshcop._udp.local.', name='Home Assistant OpenThread Border Router #8122._meshcop._udp.local.', addresses=[b'\nZ\x00\x0f', b'\xac\x1e\xe8\x01', b'\xac\x1e \x01'], port=49154, weight=0, priority=0, server='domo.local.', properties={b'rv': b'1', b'id': b"U\x02\\T\xce'\x8d\xba\x1a\xd9o&\x04\xdd\xb3\r", b'vn': b'Home Assistant', b'mn': b'OpenThread Border Router', b'nn': b'ha-thread-d9cc', b'xp': b'\xcb\x1dd\xa5\xe0\xe6\xe0\xdc', b'tv': b'1.3.0', b'xa': b'\xaa\xb3 g\xde\x96\x81"', b'sb': b'\x00\x00\x07\xb1', b'at': b'\x00\x00\x00\x00\x00\x01\x00\x00', b'pt': b'\x8d\xb0\xbfs', b'sq': b'O', b'bb': b'\xf0\xbf', b'dn': b'DefaultDomain', b'omr': b'@\xfd(\x92\xa2\xf8v\x00\x01'}, interface_index=None)

Sounds like you did not copy the thread credentials to your phone.

I use this:

“ha-thread-b862” is Thread network in other server/location… so HA not sync new network?

This is the way for Android phones to copy the credentials over (I do not have an iPhone, so no idea there)

On the Android Companion App open Settings → Companion App → Troubleshooting (I think that is what it is called in english, but it list logfiles and other tools to diagnostics as description of the item).
In this next window click the Sync Thread Login Credentials (Again it might not be named exactly that, but close to and there should not be that many options and it should be in the bottom)

It should say either something with “Added …” or “Already using the same credentials”.
The trick here is to run it again and make sure that it does not say “Added …” the second time.

If it does then you need to clear the Google Play Services Cache, which might clear a lot of other stuff, like login to services and credit card informations for Google Play and websites and so on, so make sure you know you informations before hand.

The way to clear the cache is Settings → Apps → See All Apps → Google Play Services → Storage and Cache → Manage Storage → Clear All Cache
Now repeat the syncing of the thread credentials above.

Most likely what is happening is that the credentials that are stored on the companion app is the one for ha-thread-b862. For an Android based Companion App, Android stores the first credentials it was told about and does not allow overwriting with a new set of credentials. It stores the credentials in Google Play. The only way to remove the old Thread credentials is to delete the Google Play storage, which also contains other user data like wallets and such.

1 Like

So… Does Google Play only allow credentials for a single Thread network to be stored?

It’s an important limitation if you access multiple Thread networks in several different places… home, work, your parents’ house…

Is there also no possibility of managing thread credentials from Google Play? (without deleting more data)

The Google Home app does allow you to manage multiple locations, so should it be possible in the same way?

@wmaker Google Play or Google Play Services?

AFAIK, it has been a general problem for a while, and I have not heard of any fixes or ways to manage multiple Thread datasets/credentials in Android.

Here is a link from a user that has actually done this.

1 Like

If it is possible (multiple Thread datasets/credentials) with the “Google Home” app… it should be technically possible… :sleepy:

There may be another option (just thinking to myself)… There is also suppose to be a way to get the Thread dataset from Android into HA, so you could actually go back to using your old Thread dataset in HA instead of trying to delete it out of Google Play services.

Take a look at:

1 Like

I had read it, although I had not paid much interest to the note

The preferred network function isn’t completely implemented yet. In particular, when adding Matter devices through the companion apps, the preferred network of the mobile device is being used

Anyway, in my case there are several locations/servers with a single Thread network in each one.

Likewise, this problem would not be resolved yet in the HA app…

Another solution that I will try is to plug a BT-USB adapter into HAOS itself directly to bind Matter over Thread