Help with zha and aqara switches

Hi.

I had zha working really well until I changed one of my physical light switches and since then I have been unable to pair the switch.
I know it works as it pairs fine if I move it downstairs and wire it up…it’s found immediately…when I move it back upstairs it stops working and says unavailable. It was perfectly fine before the change of light switch.

This then happened to a second device on the same floor but there are 2 devices within 2m of these that are working fine.

Help…!

This is the log when trying to pair the…

‘’’
Sent ‘mgmt_permit_joining_req’ to 00:15:8d:00:05:8d:dd:f9: [<Status.NWK_INVALID_REQUEST: 194>]
[0x2a7a:1:0x000a] ZCL deserialize: <ZCLHeader frame_control= manufacturer=None tsn=202 command_id=Command.Read_Attributes>
[0x2a7a:1:0x000a] ZCL request 0x0000: [[0]]
[0x9bc4:1:0x000a] ZCL deserialize: <ZCLHeader frame_control= manufacturer=None tsn=142 command_id=Command.Read_Attributes>
[0x9bc4:1:0x000a] ZCL request 0x0000: [[0]]
[0xeb52:1:0x000a] ZCL deserialize: <ZCLHeader frame_control= manufacturer=None tsn=87 command_id=Command.Read_Attributes>
[0xeb52:1:0x000a] ZCL request 0x0000: [[0]]
[0x0c60:1:0x0000] ZCL deserialize: <ZCLHeader frame_control= manufacturer=None tsn=164 command_id=Command.Report_Attributes>
[0x0c60:1:0x0000] ZCL request 0x000a: [[Attribute(attrid=65281, value=<TypeValue type=LVBytes, value=b’\x01!\xbd\x0b\x04!\xa8C\x05!\t\x00\x06$\x01\x00\x00\x00\x00d)\x82\ne!g\x12f+L\x85\x01\x00\n!/u’>)]]
[0x0c60:1:0x0000] Attribute report received: 65281=b’\x01!\xbd\x0b\x04!\xa8C\x05!\t\x00\x06$\x01\x00\x00\x00\x00d)\x82\ne!g\x12f+L\x85\x01\x00\n!/u’
[0x0c60:1:0x0001] Voltage mV: [Min]:2820 < [RAW]:3005 < [Max]:3100, Battery Percent: 66.0
Error handling ‘_save_attribute’ event with (00:15:8d:00:06:f4:64:3c, 1, 1026, 0, 2690) params: UNIQUE constraint failed: attributes_cache_v6.ieee, attributes_cache_v6.endpoint_id, attributes_cache_v6.cluster, attributes_cache_v6.attrid
Error handling ‘_save_attribute’ event with (00:15:8d:00:06:f4:64:3c, 1, 1029, 0, 4711) params: UNIQUE constraint failed: attributes_cache_v6.ieee, attributes_cache_v6.endpoint_id, attributes_cache_v6.cluster, attributes_cache_v6.attrid
Error handling ‘_save_attribute’ event with (00:15:8d:00:06:f4:64:3c, 1, 1027, 0, 996.6) params: UNIQUE constraint failed: attributes_cache_v6.ieee, attributes_cache_v6.endpoint_id, attributes_cache_v6.cluster, attributes_cache_v6.attrid
[0xe440:1:0x000a] ZCL deserialize: <ZCLHeader frame_control= manufacturer=None tsn=55 command_id=Command.Read_Attributes>
[0xe440:1:0x000a] ZCL request 0x0000: [[0]]
[0x2a7a:1:0x000a] ZCL deserialize: <ZCLHeader frame_control= manufacturer=None tsn=203 command_id=Command.Read_Attributes>
[0x2a7a:1:0x000a] ZCL request 0x0000: [[0]]
[0x9bc4:1:0x000a] ZCL deserialize: <ZCLHeader frame_control= manufacturer=None tsn=143 command_id=Command.Read_Attributes>
[0x9bc4:1:0x000a] ZCL request 0x0000: [[0]]
[0xeb52:1:0x000a] ZCL deserialize: <ZCLHeader frame_control= manufacturer=None tsn=88 command_id=Command.Read_Attributes>
[0xeb52:1:0x000a] ZCL request 0x0000: [[0]]
‘’’

I suspect a zigbee router device disappeared form your setup, limiting the mesh network range…

Thanks for that…but how do I fix it?
There is a hard wired switch within 2m that’s still working.

As it is I’ve decided to start from scratch…not looking forward to this …