def __init__(self, numSNBits=16): """Initialize the packet format. By default use 16 bits for seq.nums. Arguments: numSNBits:Integer -- number of bits for the sequence numbers in the packet format. """ PointToPointDL.__init__(self) self._newFrame = None # We need the window size before creating PDUs. self._sendBuffer = {} # Dictionary: SN --> Bitstream self._retransmissionTimer = {} # Dictionary: SN --> Timer self._transmitQueue = [] # List of frames to transmit self._SN_MODULO = 2**numSNBits if (2 * numSNBits) % 8 != 0: padLen = 8 - (2 * numSNBits) % 8 self._newFrame = formatFactory( [ ('SN', 'BitField', numSNBits, 0), # Sequence number ('RN', 'BitField', numSNBits, 0), # Acknowledged SN ('pad', 'BitField', padLen, 0), # Padding to align to octets ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None) ], # Checksum: CRC32. self) else: self._newFrame = formatFactory( [ ('SN', 'BitField', numSNBits, 0), # Sequence number ('RN', 'BitField', numSNBits, 0), # Acknowledged SN ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None) ], # Checksum: CRC32. self)
def __init__(self, numSNBits=16): GoBackNDL.__init__(self, numSNBits) self._receiveBuffer = {} # Dictionary: SN --> Bitstream self._SN_MODULO = 2**numSNBits if (2 * numSNBits) % 8 != 0: padLen = 8 - (2 * numSNBits) % 8 self._newFrame = formatFactory( [ ('SN', 'BitField', numSNBits, 0), # Sequence number ('RN', 'BitField', numSNBits, 0), # Acknowledged SN ('SREJ', 'Int', 8, 0), # 1 byte to signal SREJ ('pad', 'BitField', padLen, 0), # Padding to align to octets ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None) ], # Checksum: CRC32. self) else: self._newFrame = formatFactory( [ ('SN', 'BitField', numSNBits, 0), # Sequence number ('RN', 'BitField', numSNBits, 0), # Acknowledged SN ('SREJ', 'Int', 8, 0), # 1 byte to signal SREJ ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None) ], # Checksum: CRC32. self)
def __init__(self,numSNBits=16): """Initialize the packet format. By default use 16 bits for seq.nums. Arguments: numSNBits:Integer -- number of bits for the sequence numbers in the packet format. """ PointToPointDL.__init__(self) self._newFrame = None # We need the window size before creating PDUs. self._sendBuffer = {} # Dictionary: SN --> Bitstream self._retransmissionTimer = {} # Dictionary: SN --> Timer self._transmitQueue = [] # List of frames to transmit self._SN_MODULO = 2**numSNBits if (2*numSNBits) % 8 != 0: padLen = 8 - (2*numSNBits)%8 self._newFrame = formatFactory( [('SN', 'BitField', numSNBits, 0), # Sequence number ('RN', 'BitField', numSNBits, 0), # Acknowledged SN ('pad', 'BitField', padLen, 0), # Padding to align to octets ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None)], # Checksum: CRC32. self) else: self._newFrame = formatFactory( [('SN', 'BitField', numSNBits, 0), # Sequence number ('RN', 'BitField', numSNBits, 0), # Acknowledged SN ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None)], # Checksum: CRC32. self)
def __init__(self): PointToPointDL.__init__(self) self._newFrame = formatFactory( [('SN', 'BitField', 1, 0), # Sequence number: 1 bit, defaul: 0 ('RN', 'BitField', 1, 0), # Acknowledged SN: 1 bit, default: 0 ('pad', 'BitField', 6, 0), # Padding to align to octet boundaries ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None)], # Checksum: CRC32. self)
def __init__(self): PointToPointDL.__init__(self) self._newFrame = formatFactory( [ ('SN', 'BitField', 1, 0), # Sequence number: 1 bit, defaul: 0 ('RN', 'BitField', 1, 0), # Acknowledged SN: 1 bit, default: 0 ('pad', 'BitField', 6, 0), # Padding to align to octet boundaries ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None) ], # Checksum: CRC32. self)
def __init__(self,numSNBits=16): GoBackNDL.__init__(self,numSNBits) self._receiveBuffer = {} # Dictionary: SN --> Bitstream self._SN_MODULO = 2**numSNBits if (2*numSNBits) % 8 != 0: padLen = 8 - (2*numSNBits)%8 self._newFrame = formatFactory( [('SN', 'BitField', numSNBits, 0), # Sequence number ('RN', 'BitField', numSNBits, 0), # Acknowledged SN ('SREJ', 'Int', 8, 0), # 1 byte to signal SREJ ('pad', 'BitField', padLen, 0), # Padding to align to octets ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None)], # Checksum: CRC32. self) else: self._newFrame = formatFactory( [('SN', 'BitField', numSNBits, 0), # Sequence number ('RN', 'BitField', numSNBits, 0), # Acknowledged SN ('SREJ', 'Int', 8, 0), # 1 byte to signal SREJ ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None)], # Checksum: CRC32. self)
def __init__(self): PointToPointDL.__init__(self) self._newFrame = formatFactory( [('DstAddr', 'Int', 8, 0), # Destination address ('SrcAddr', 'Int', 8, 0), # Source address ('SN', 'BitField', 1, 0), # Sequence number: 1 bit, defaul: 0 ('RN', 'BitField', 1, 0), # Acknowledged SN: 1 bit, default: 0 ('pad', 'BitField', 6, 0), # Padding to align to octet boundaries ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None)], # Checksum: CRC32. self) self._transmitQueue = [] # List of frames to transmit self._computeBackoff = self._fixedBackoff self._VR = {} self._VS = {}
def __init__(self): PointToPointDL.__init__(self) self._newFrame = formatFactory( [ ('DstAddr', 'Int', 8, 0), # Destination address ('SrcAddr', 'Int', 8, 0), # Source address ('SN', 'BitField', 1, 0), # Sequence number: 1 bit, defaul: 0 ('RN', 'BitField', 1, 0), # Acknowledged SN: 1 bit, default: 0 ('pad', 'BitField', 6, 0), # Padding to align to octet boundaries ('data', 'ByteField', None, None), # Payload ('FCS', 'Int', 32, None) ], # Checksum: CRC32. self) self._transmitQueue = [] # List of frames to transmit self._computeBackoff = self._fixedBackoff self._VR = {} self._VS = {}
def install(self, niu, protocolName): """Install the protocol entity on a NIU. This method is called by the node or the NIU to inform the protocol that is has been installed. It registers the NIU for later access and chooses a random MAC address that can later by changed using the MAC.setAddress method. It also creates a new PDU class 802.3 for its MAC frames. The format is described in the standard, Section 3.1.1. Arguments: niu:NIU -- NIU on which self is installed protocoleName:String -- Must be 'mac'. Return value: None. """ if isinstance(niu, NIU): self._niu = niu else: raise TypeError("Ethernet MAC entity must be installed on a NIU") if protocolName != "mac": raise NameError("Ethernet MAC entity must be installed under the " "name 'mac'") self._protocolName = "mac" self.fullName = niu.fullName + ".mac" ints = [int(random()*256) for i in range(6)] if ints[0]%2 == 1: ints[0] -= 1 self.address = "%02X:%02X:%02X:%02X:%02X:%02X"%tuple(ints) self._PDU = formatFactory( #@@@ Bit order of preamble, SFD, and FCS is not correct. # See 3.3 and 3.2.8 [('preamble', 'ByteField', 56, chr(int('10101010', 2))*7), ('SFD', 'ByteField', 8, chr(int('10101011',2))), ('destAddr', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('srcAddr', 'MACAddr', 48, self.address), ('typeOrLength', 'Int', 16, 0x0800), ('data', 'ByteField', None, None), ('FCS', 'Int', 32, None)], self) # Start accepting frames self._niu.XOFF = False
def install(self, niu, protocolName): """Install the protocol entity on a NIU. This method is called by the node or the NIU to inform the protocol that is has been installed. It registers the NIU for later access and chooses a random MAC address that can later by changed using the MAC.setAddress method. It also creates a new PDU class 802.3 for its MAC frames. The format is described in the standard, Section 3.1.1. Arguments: niu:NIU -- NIU on which self is installed protocoleName:String -- Must be 'mac'. Return value: None. """ if isinstance(niu, NIU): self._niu = niu else: raise TypeError("Ethernet MAC entity must be installed on a NIU") if protocolName != "mac": raise NameError("Ethernet MAC entity must be installed under the " "name 'mac'") self._protocolName = "mac" self.fullName = niu.fullName + ".mac" ints = [int(random() * 256) for i in range(6)] if ints[0] % 2 == 1: ints[0] -= 1 self.address = "%02X:%02X:%02X:%02X:%02X:%02X" % tuple(ints) self._PDU = formatFactory( #@@@ Bit order of preamble, SFD, and FCS is not correct. # See 3.3 and 3.2.8 [('preamble', 'ByteField', 56, chr(int('10101010', 2)) * 7), ('SFD', 'ByteField', 8, chr(int('10101011', 2))), ('destAddr', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('srcAddr', 'MACAddr', 48, self.address), ('typeOrLength', 'Int', 16, 0x0800), ('data', 'ByteField', None, None), ('FCS', 'Int', 32, None)], self) # Start accepting frames self._niu.XOFF = False
def __init__(self): #Structure of the default data frame (7.2.2) #With QoS Control field self.MPDUQos = formatFactory( [('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('address1', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('address2', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('address3', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('sequenceControl', 'ByteField', 16, None), ('address4', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('qosControl', 'ByteField', 16, None), #QoS capabilities ('data', 'ByteField', None, None), ('FCS', 'Int', 32, None) ], self) #Without QoS Control field self.MPDU = formatFactory( [('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('address1', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('address2', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('address3', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('sequenceControl', 'ByteField', 16, None), ('address4', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('data', 'ByteField', None, None), ('FCS', 'Int', 32, None) ], self) #QoS Control field (7.1.3.5) self.QosControl = formatFactory( [('tid', 'BitField', 4, 0), ('eosp', 'BitField', 1, 0), ('ackPolicy', 'BitField', 2, 0), ('reserved', 'BitField', 1, 0), ('txopOrQueue', 'Int', 8, None) ], self) #Frame Control field (7.1.3.1) self.FrameControl = formatFactory( [('protocolVersion', 'BitField', 2, 0), ('type', 'BitField', 2, None), ('subType', 'BitField', 4, None), ('toDS', 'BitField', 1, 0), ('fromDS', 'BitField', 1, 1), ('moreFrag', 'BitField', 1, 0), ('retry', 'BitField', 1, 0), ('pwrMgt', 'BitField', 1, 0), ('moreData', 'BitField', 1, 0), ('wep', 'BitField', 1, 0), ('order', 'BitField', 1, None) ], self) #Sequence Address field (7.1.3.4) self.SequenceControl = formatFactory( [('fragmentNb', 'BitField', 4, None), ('sequenceNb', 'BitField', 12, None) ], self) #Structure of the ACK frame (7.2.1.3) self.ACK = formatFactory( [('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('receiverAddress', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('FCS', 'Int', 32, None) ], self) #Structure of the CF-END frame (7.2.1.3) self.CF_END = formatFactory( [('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('receiverAddress', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('BSSID', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('FCS', 'Int', 32, None) ], self) #Structure of the default Management frame (7.2.3) self.Management = formatFactory( [('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('DA', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('SA', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('BSSID', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('sequenceControl', 'ByteField', 16, None), ('data', 'ByteField', None, None), ('FCS', 'Int', 32, None) ], self) #Structure of data field for a Beacon frame (7.2.3.1) #With QoS self.BeaconDataQos = formatFactory( [('timeStamp', 'ByteField', 48, None), ('beaconInterval', 'Int', 16, None), ('capabilityInfo', 'ByteField', 16, None), ('SSID', 'ByteField', 16, None), #Variable size: 16-272 (min is employed) ('supportedRates', 'ByteField', 24, None), #Variable size: 24-80 (min is employed) #('FHParameterSet','ByteField', 56, None), #Optional (for FHSS modulation) #('DSParameterSet','ByteField', 16, None), #Optional (for DSSS modulation) #('CFParameterSet','ByteField', 64, None), #Optional (for PCF) #('IBSSParameterSet','ByteField', 32, None), #Optional (for independant BSS structure) ('TIM','ByteField', None, None), ('QBSSLoad', 'ByteField', 56, None), #QoS capabilities ('EDCAParameterSet', 'ByteField', 160, None), #QoS capabilities ('QosCapability', 'ByteField', 24, None) #QoS capabilities ], self) #Without QoS self.BeaconData = formatFactory( [('timeStamp', 'ByteField', 48, None), ('beaconInterval', 'Int', 16, None), ('capabilityInfo', 'ByteField', 16, None), ('SSID', 'ByteField', 16, None), #Variable size: 16-272 (min is employed) ('supportedRates', 'ByteField', 24, None), #Variable size: 24-80 (min is employed) ('TIM','ByteField', None, None), ], self) #Structure of the Capability Info field (7.3.1.4) self.CapabilityInfo = formatFactory( [('ESS', 'BitField', 1, None), ('IBSS', 'BitField', 1, None), ('CFPollable', 'BitField', 1, None), ('CFPollRequest', 'BitField', 1, None), ('privacy', 'BitField', 1, None), ('shortPreamble', 'BitField', 1, None), ('PBCC', 'BitField', 1, None), ('channelAgility', 'BitField', 1, None), ('spectrumManagement', 'BitField', 1, None), ('Qos', 'BitField', 1, None), #QoS capabilities ('shortSlotTime', 'BitField', 1, None), ('APSD', 'BitField', 1, None), #QoS capabilities ('reserved', 'BitField', 1, None), ('DSSS_OFDM', 'BitField', 1, None), ('delayedBlockAck', 'BitField', 1, None), #QoS capabilities ('immediateBlockAck', 'BitField', 1, None) #QoS capabilities ], self) #Element model field (7.3.2) self.Element = formatFactory( [('elementID', 'Int', 8, None), ('length', 'Int', 8, None), ('information', 'ByteField', None, None) ], self) #EDCA Parameter Set (Element) (7.3.2.14) self.EDCAParameterSet = formatFactory( [('QosInfo', 'ByteField', 8, None), ('reserved', 'ByteField', 8, None), ('AC_BEParameterRecord', 'ByteField', 32, None), ('AC_BKParameterRecord', 'ByteField', 32, None), ('AC_VIParameterRecord', 'ByteField', 32, None), ('AC_VOParameterRecord', 'ByteField', 32, None), ], self) #QoS Information subfield (from AP) (7.3.1.17) self.QosInformationAP = formatFactory( [('EDCAParamSetUpdateCount', 'BitField', 4, None), ('Q_Ack', 'BitField', 1, None), ('queueRequest', 'BitField', 1, None), ('TXOPRequest', 'BitField', 1, None), ('reserved', 'BitField', 1, None), ], self) #QoS Information subfield (from STA) (7.3.1.17) self.QosInformationSTA = formatFactory( [('AC_VOFlag', 'BitField', 1, None), ('AC_VIFlag', 'BitField', 1, None), ('AC_BKFlag', 'BitField', 1, None), ('AC_BEFlag', 'BitField', 1, None), ('Q_Ack', 'BitField', 1, None), ('maxSPLength', 'BitField', 2, None), ('moreDataAck', 'BitField', 1, None), ], self) #AC Parameter Record subfield (from STA) (7.3.2.14) self.ACParameterRecord = formatFactory( [('AIFSN', 'BitField', 4, None), ('ACM', 'BitField', 1, None), ('ACI', 'BitField', 2, None), ('reserved', 'BitField', 1, None), ('ECWmin', 'BitField', 4, None), ('ECWmax', 'BitField', 4, None), ('TXOPLimit', 'BitField', 16, None), ], self)
def __init__(self): #Structure of the default data frame (7.2.2) #With QoS Control field self.MPDUQos = formatFactory( [ ('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('address1', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('address2', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('address3', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('sequenceControl', 'ByteField', 16, None), ('address4', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('qosControl', 'ByteField', 16, None), #QoS capabilities ('data', 'ByteField', None, None), ('FCS', 'Int', 32, None) ], self) #Without QoS Control field self.MPDU = formatFactory( [('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('address1', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('address2', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('address3', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('sequenceControl', 'ByteField', 16, None), ('address4', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('data', 'ByteField', None, None), ('FCS', 'Int', 32, None)], self) #QoS Control field (7.1.3.5) self.QosControl = formatFactory([('tid', 'BitField', 4, 0), ('eosp', 'BitField', 1, 0), ('ackPolicy', 'BitField', 2, 0), ('reserved', 'BitField', 1, 0), ('txopOrQueue', 'Int', 8, None)], self) #Frame Control field (7.1.3.1) self.FrameControl = formatFactory( [('protocolVersion', 'BitField', 2, 0), ('type', 'BitField', 2, None), ('subType', 'BitField', 4, None), ('toDS', 'BitField', 1, 0), ('fromDS', 'BitField', 1, 1), ('moreFrag', 'BitField', 1, 0), ('retry', 'BitField', 1, 0), ('pwrMgt', 'BitField', 1, 0), ('moreData', 'BitField', 1, 0), ('wep', 'BitField', 1, 0), ('order', 'BitField', 1, None)], self) #Sequence Address field (7.1.3.4) self.SequenceControl = formatFactory( [('fragmentNb', 'BitField', 4, None), ('sequenceNb', 'BitField', 12, None)], self) #Structure of the ACK frame (7.2.1.3) self.ACK = formatFactory( [('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('receiverAddress', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('FCS', 'Int', 32, None)], self) #Structure of the CF-END frame (7.2.1.3) self.CF_END = formatFactory( [('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('receiverAddress', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('BSSID', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('FCS', 'Int', 32, None)], self) #Structure of the default Management frame (7.2.3) self.Management = formatFactory( [('frameControl', 'ByteField', 16, None), ('durationID', 'Int', 16, 0), ('DA', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('SA', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('BSSID', 'MACAddr', 48, 'FF:FF:FF:FF:FF:FF'), ('sequenceControl', 'ByteField', 16, None), ('data', 'ByteField', None, None), ('FCS', 'Int', 32, None)], self) #Structure of data field for a Beacon frame (7.2.3.1) #With QoS self.BeaconDataQos = formatFactory( [ ('timeStamp', 'ByteField', 48, None), ('beaconInterval', 'Int', 16, None), ('capabilityInfo', 'ByteField', 16, None), ('SSID', 'ByteField', 16, None), #Variable size: 16-272 (min is employed) ('supportedRates', 'ByteField', 24, None), #Variable size: 24-80 (min is employed) #('FHParameterSet','ByteField', 56, None), #Optional (for FHSS modulation) #('DSParameterSet','ByteField', 16, None), #Optional (for DSSS modulation) #('CFParameterSet','ByteField', 64, None), #Optional (for PCF) #('IBSSParameterSet','ByteField', 32, None), #Optional (for independant BSS structure) ('TIM', 'ByteField', None, None), ('QBSSLoad', 'ByteField', 56, None), #QoS capabilities ('EDCAParameterSet', 'ByteField', 160, None), #QoS capabilities ('QosCapability', 'ByteField', 24, None) #QoS capabilities ], self) #Without QoS self.BeaconData = formatFactory( [ ('timeStamp', 'ByteField', 48, None), ('beaconInterval', 'Int', 16, None), ('capabilityInfo', 'ByteField', 16, None), ('SSID', 'ByteField', 16, None), #Variable size: 16-272 (min is employed) ('supportedRates', 'ByteField', 24, None), #Variable size: 24-80 (min is employed) ('TIM', 'ByteField', None, None), ], self) #Structure of the Capability Info field (7.3.1.4) self.CapabilityInfo = formatFactory( [ ('ESS', 'BitField', 1, None), ('IBSS', 'BitField', 1, None), ('CFPollable', 'BitField', 1, None), ('CFPollRequest', 'BitField', 1, None), ('privacy', 'BitField', 1, None), ('shortPreamble', 'BitField', 1, None), ('PBCC', 'BitField', 1, None), ('channelAgility', 'BitField', 1, None), ('spectrumManagement', 'BitField', 1, None), ('Qos', 'BitField', 1, None), #QoS capabilities ('shortSlotTime', 'BitField', 1, None), ('APSD', 'BitField', 1, None), #QoS capabilities ('reserved', 'BitField', 1, None), ('DSSS_OFDM', 'BitField', 1, None), ('delayedBlockAck', 'BitField', 1, None), #QoS capabilities ('immediateBlockAck', 'BitField', 1, None ) #QoS capabilities ], self) #Element model field (7.3.2) self.Element = formatFactory( [('elementID', 'Int', 8, None), ('length', 'Int', 8, None), ('information', 'ByteField', None, None)], self) #EDCA Parameter Set (Element) (7.3.2.14) self.EDCAParameterSet = formatFactory([ ('QosInfo', 'ByteField', 8, None), ('reserved', 'ByteField', 8, None), ('AC_BEParameterRecord', 'ByteField', 32, None), ('AC_BKParameterRecord', 'ByteField', 32, None), ('AC_VIParameterRecord', 'ByteField', 32, None), ('AC_VOParameterRecord', 'ByteField', 32, None), ], self) #QoS Information subfield (from AP) (7.3.1.17) self.QosInformationAP = formatFactory([ ('EDCAParamSetUpdateCount', 'BitField', 4, None), ('Q_Ack', 'BitField', 1, None), ('queueRequest', 'BitField', 1, None), ('TXOPRequest', 'BitField', 1, None), ('reserved', 'BitField', 1, None), ], self) #QoS Information subfield (from STA) (7.3.1.17) self.QosInformationSTA = formatFactory([ ('AC_VOFlag', 'BitField', 1, None), ('AC_VIFlag', 'BitField', 1, None), ('AC_BKFlag', 'BitField', 1, None), ('AC_BEFlag', 'BitField', 1, None), ('Q_Ack', 'BitField', 1, None), ('maxSPLength', 'BitField', 2, None), ('moreDataAck', 'BitField', 1, None), ], self) #AC Parameter Record subfield (from STA) (7.3.2.14) self.ACParameterRecord = formatFactory([ ('AIFSN', 'BitField', 4, None), ('ACM', 'BitField', 1, None), ('ACI', 'BitField', 2, None), ('reserved', 'BitField', 1, None), ('ECWmin', 'BitField', 4, None), ('ECWmax', 'BitField', 4, None), ('TXOPLimit', 'BitField', 16, None), ], self)