ciotlosm / zig-a-zig-ah-firmware

Zzh! Home Assistant add-on for firmware updates
Apache License 2.0
0 stars 0 forks source link

Add ability to show less busy channels (Energy Scan) #5

Open ciotlosm opened 3 years ago

ciotlosm commented 3 years ago

Make use of Energy Scan to allow the user to find a better channel before setting up z2m add-on.

This could potentially be added to z2m add-on to choose a good channel on 1st boot.

Hedda commented 3 years ago

FYI, zigpy-znp can do Zigbee channels energy scans https://github.com/zha-ng/zigpy-znp

https://github.com/zha-ng/zigpy-znp/blob/dev/README.md

Energy scan

Perform an energy scan to find a quiet Zigbee channel:

$ python -m zigpy_znp.tools.energy_scan /dev/cu.usbmodem14101
Channel energy (mean of 1 / 5):
------------------------------------------------
 + Lower energy is better
 + Active Zigbee networks on a channel may still cause congestion
 + Using 26 in the USA may have lower TX power due to FCC regulations
 + Zigbee channels 15, 20, 25 fall between WiFi channels 1, 6, 11
 + Some Zigbee devices only join networks on channels 11, 13, 15, 20, or 25
------------------------------------------------
 - 11    61.57%  #############################################################
 - 12    60.78%  ############################################################
 - 13    12.16%  ############
 - 14    58.43%  ##########################################################
 - 15    57.65%  #########################################################
 - 16    29.80%  #############################
 - 17    38.82%  ######################################
 - 18    47.06%  ###############################################
 - 19    36.86%  ####################################
 - 20    10.98%  ##########
 - 21    16.47%  ################
 - 22    33.73%  #################################
 - 23    30.59%  ##############################
 - 24    20.39%  ####################
 - 25     5.88%  #####
 - 26*   20.39%  ####################