#Changing Zigbee channels

1 messages ยท Page 1 of 1 (latest)

pearl wren
#

@sudden quiver I'm a bit late to the party. But I'm struggling a bit, I run on Home Assistant Core. How to get this python script to work when I'm on HA Core?

pearl wren
sudden quiver
#

@quasi cliff then run it just like you did the energy scan tool: python /config/change_network_channel.py -v --channel 20 /dev/serial/by-id/...

#

None of your battery operated devices will migrate (though some could!) but I just tested it with a small network of a ZNP coordinator and a few bulbs and they all switched channels after ZHA was restarted

#

If you have any battery-powered devices that are practically impossible to rejoin due to location (and aren't Aqara) it's in theory possible to modify the script to migrate them as well, but it'll require a ton more effort

quasi cliff
#

@sudden quiver thanks! I've saved it, I'll let you know how it went

#

and it's great, if this works, It'd save me a lot of effort anyway

sudden quiver
#

Sounds good. There's no way to view the current channel within ZHA so run a network backup afterwards just to triple check

quasi cliff
#

rejoining a few sensors is not that much of a bother in comparison

#

will do!

#

tbh most of my sensors are aqara lol

sudden quiver
#

Yeah you're out of luck with those sensors, they're effectively send-only devices after they join and don't implement this part of the spec to begin with ๐Ÿ˜†

quasi cliff
#

lovely!

sudden quiver
#

But now that they've joined it should be very easy to re-join them, since ZHA knows all it needs to know about the device

quasi cliff
#

just the matter of finding them physically.

sudden quiver
#

One thing to watch out for is that they can get into a state where their battery has just enough juice to send periodic reports, but not enough to actively scan for and join a new network. You may have to change batteries if you've been using them for a few years if they don't seem to reliably re-join.

quasi cliff
#

yes, I did notice weird pairing behaviours depending on battery level...

#

welp, a round of general maintenance with fresh batteries for the network won't hurt

#

thanks again

sudden quiver
#

And Aqara sensors don't have reliable battery reporting to begin with so you just gotta check by feel and how alive the blue LED looks ๐Ÿ˜†

#

No problem, let me know how it turns out

quasi cliff
#

Worked, thank you!

#

2022-06-12 23:30:09 DEBUG (MainThread) [zigpy_znp.nvram] Read NVRAM["LEGACY"][0x0021] = NIB(SequenceNum=139, PassiveAckTimeout=5, MaxBroadcastRetries=2, MaxChildren=51, MaxDepth=15, MaxRouters=51, dummyNeighborTable=0, BroadcastDeliveryTime=30, ReportConstantCost=0, RouteDiscRetries=0, dummyRoutingTable=0, SecureAllFrames=1, SecurityLevel=5, SymLink=1, CapabilityFlags=143, TransactionPersistenceTime=7, nwkProtocolVersion=2, RouteDiscoveryTime=13, RouteExpiryTime=30, nwkDevAddress=0x0000, nwkLogicalChannel=20, nwkCoordAddress=0x0000, nwkCoordExtAddress=00:00:00:00:00:00:00:00, nwkPanId=4620, nwkState=<NwkState.NWK_ROUTER: 8>, channelList=<Channels.CHANNEL_15: 32768>, beaconOrder=15, superFrameOrder=15, scanDuration=4, battLifeExt=0, allocatedRouterAddresses=1, allocatedEndDeviceAddresses=1, nodeDepth=0, extendedPANID=f8:df:0f:0f:e1:f5:64:4d, nwkKeyLoaded=<Bool.true: 1>, spare1=NwkKeyDesc(KeySeqNum=0, Key=00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00), spare2=NwkKeyDesc(KeySeqNum=0, Key=00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00), spare3=0, spare4=0, nwkLinkStatusPeriod=15, nwkRouterAgeLimit=5, nwkUseMultiCast=<Bool.false: 0>, nwkIsConcentrator=<Bool.true: 1>, nwkConcentratorDiscoveryTime=120, nwkConcentratorRadius=10, nwkAllFresh=1, nwkManagerAddr=0x0000, nwkTotalTransmissions=2, nwkUpdateId=1

#

lost all battery operated buttons, aqara opple and ikea, a couple of thermo sensors, and a single bulb, for some reason

#

a tuya battery operated thermostat held out though

#

the only reliable way to get them back for me is to delete the device from the integration and rejoin, but still, not a big deal all in all

#

thanks again ๐Ÿ™‚

sudden quiver
#

Thanks for the feedback!

#

You should be able to just permit joins and reset the device, without having tor remove it

quasi cliff
#

i tried handle_join and misc_reinitialize from the zha toolkit, calling the devices via ieee, but that didn't work

#

ah, i see, there's zha.permit

sudden quiver
#

Just the + Add Device button is fine

quasi cliff
#

yup, worked fine ๐Ÿ™‚