103 MACAddress receiverAddr = blockAck->getTransmitterAddress();
104 std::set<QoSKey> ackedFrames;
106 if (
auto basicBlockAck = dynamic_cast<Ieee80211BasicBlockAck *>(blockAck)) {
107 int startingSeqNum = basicBlockAck->getStartingSequenceNumber();
108 for (
int seqNum = 0; seqNum < 64; seqNum++) {
109 BitVector bitmap = basicBlockAck->getBlockAckBitmap(seqNum);
110 for (
int fragNum = 0; fragNum < 16; fragNum++) {
111 auto id = std::make_pair(receiverAddr, std::make_pair(basicBlockAck->getTidInfo(), SequenceControlField((startingSeqNum + seqNum) % 4096, fragNum)));
114 bool acked = bitmap.getBit(fragNum) == 1;
115 if (acked) ackedFrames.insert(
id);
122 else if (
auto compressedBlockAck = dynamic_cast<Ieee80211CompressedBlockAck *>(blockAck)) {
123 int startingSeqNum = compressedBlockAck->getStartingSequenceNumber();
124 BitVector bitmap = compressedBlockAck->getBlockAckBitmap();
125 for (
int seqNum = 0; seqNum < 64; seqNum++) {
126 auto id = std::make_pair(receiverAddr, std::make_pair(compressedBlockAck->getTidInfo(), SequenceControlField(startingSeqNum + seqNum, 0)));
129 bool acked = bitmap.getBit(seqNum) == 1;
131 if (acked) ackedFrames.insert(
id);
137 throw cRuntimeError(
"Multi-TID BlockReq is unimplemented");
void printAckStatuses()
Definition: QoSAckHandler.cc:252
Status
Definition: QoSAckHandler.h:34
virtual Status & getQoSDataAckStatus(const QoSKey &id)
Definition: QoSAckHandler.cc:23