Package killerbee :: Module zigbeedecode :: Class ZigBeeAPSPacketParser
[hide private]
[frames] | no frames]

Class ZigBeeAPSPacketParser

source code

Instance Methods [hide private]
 
__init__(self)
Instantiates the ZigBeeAPSPacketParser class.
source code
list
pktchop(self, packet)
Chops up the specified packet contents into a list of fields.
source code
Int
hdrlen(self, packet)
Returns the length of the ZigBee NWK header.
source code
Int
payloadlen(self, packet)
Returns the length of the APS payload.
source code
Method Details [hide private]

pktchop(self, packet)

source code 

Chops up the specified packet contents into a list of fields. Does not attempt to re-order the field values for parsing. ''.join(X) will reassemble original packet string. Fields which may or may not be present (such as the destination endpoint) are empty if they are not present, keeping the list elements consistent, as follows: Frame Control | Dst Endpoint | Group Address | Cluster Identifier | Profile Identifier | Source Endpoint | APS Counter | Payload

An exception is raised if the packet contents are too short to decode.

Parameters:
  • packet (String) - Packet contents.
Returns: list
Chopped contents of the ZigBee APS packet into list elements.

hdrlen(self, packet)

source code 

Returns the length of the ZigBee NWK header.

Parameters:
  • packet (String) - Packet contents to evaluate for header length.
Returns: Int
Length of the ZigBEE NWK header.

payloadlen(self, packet)

source code 

Returns the length of the APS payload.

Parameters:
  • packet (String) - Packet contents to evaluate for header length.
Returns: Int
Length of the APS payload.