Zigpy packet capture interface #54
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Implementation of zigpy/bellows#664 + zigpy/zigpy#1537.
The main improvement over
bellows dumpis that we use theLINKTYPE_IEEE802_15_4_TAPlink type, which includes RSSI, LQI, and channel metadata:Sample usage:
zigpy radio \ --baudrate 57600 \ ezsp /dev/cu.GoControl_zigbee* \ packet-capture \ --channels 11,15,20,25 \ --channel-hop-period 1.0 \ --channel-hop-randomly \ -o - | wireshark -k -S -i -The channel hopping options can be ignored if a single channel is provided.
To facilitate whole-spectrum sniffing (if you have enough adapters 😄), I've added an
--interleavecommand and a second command to combine them:( zigpy radio ezsp /dev/cu.SLAB_USBtoUART packet-capture -c 11 --interleave -o - & zigpy radio ezsp /dev/cu.SLAB_USBtoUART8 packet-capture -c 15 --interleave -o - & zigpy radio ezsp /dev/cu.SLAB_USBtoUART10 packet-capture -c 20 --interleave -o - & zigpy radio ezsp /dev/cu.SLAB_USBtoUART13 packet-capture -c 25 --interleave -o - & zigpy radio ezsp /dev/cu.SLAB_USBtoUART14 packet-capture -c 12,13,14,26 --interleave --channel-hop-period 1 -o - & zigpy radio ezsp /dev/cu.SLAB_USBtoUART17 packet-capture -c 16,17,18,19 --interleave --channel-hop-period 1 -o - & zigpy radio ezsp /dev/cu.SLAB_USBtoUART18 packet-capture -c 21,22,23,24 --interleave --channel-hop-period 1 -o - & wait ) | zigpy pcap interleave-combine -o - | wireshark -k -S -i -This allows you to scan all of the ZLL channels at once and show the results in Wireshark: