Dcaf

Package: inet.linklayer.ieee80211.mac.channelaccess

compound module Dcaf

Implements the DCAF (Distributed Channel Access Function) for IEEE 802.11.

Usage diagram

Inheritance diagram

Used in compound modules

Name

Type

Description

Dcf

compound module

Implements the DCF (Distributed Coordination Function) for IEEE 802.11.

Extends

Name

Type

Description

Module

compound module

Base module for all INET compound modules.

Parameters

Name

Type

Default value

Description

displayStringTextFormat

string

“{contentionState}”

Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information

difsn

int

-1

cwMin

int

-1

cwMax

int

-1

rxModule

string

Properties

Name

Value

Description

class

Dcaf

display

i=block/star

Signals

Name

Type

Unit

Description

channelOwnershipChanged

bool

Statistics

Name

Title

Source

Record

Unit

Interpolation Mode

Description

channelOwnershipChanged

channel ownership

count,vector?

sample-hold

Unassigned submodule parameters

Name

Type

Default value

Description

pendingQueue.displayStringTextFormat

string

“contains %p pk (%l) pushed %u\npulled %o removed %r dropped %d”

Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information

pendingQueue.packetCapacity

int

100

Maximum number of packets in the queue, no limit by default

pendingQueue.dataCapacity

int

-1b

Maximum total length of packets in the queue, no limit by default

pendingQueue.dropperClass

string

“inet::queueing::PacketAtCollectionEndDropper”

Determines which packets are dropped when the queue is overloaded, packets are not dropped by default; the parameter must be the name of a C++ class which implements the IPacketDropperFunction C++ interface and is registered via Register_Class

pendingQueue.comparatorClass

string

“inet::ieee80211::MgmtOverDataComparator”

Determines the order of packets in the queue, insertion order by default; the parameter must be the name of a C++ class which implements the IPacketComparatorFunction C++ interface and is registered via Register_Class

pendingQueue.bufferModule

string

“”

Relative module path to the IPacketBuffer module used by this queue, implicit buffer by default

inProgressFrames.displayStringTextFormat

string

“{numInProgress} packets”

Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information

inProgressFrames.pendingQueueModule

string

“^.pendingQueue”

inProgressFrames.originatorMacDataServiceModule

string

“^.^.originatorMacDataService”

inProgressFrames.ackHandlerModule

string

“^.^.ackHandler”

contention.displayStringTextFormat

string

“{fsmState}”

Determines the text that is written on top of the submodule, supports displaying pars, watches, and module-specific information

contention.initialChannelBusy

bool

true

Assume that the channel was busy before the simulation started

contention.backoffOptimization

bool

true

We can pretend the frame has arrived into the queue a little bit earlier, and maybe able to start transmitting immediately

Source code

//
// Implements the DCAF (Distributed Channel Access Function) for IEEE 802.11.
//
module Dcaf extends Module
{
    parameters:
        int difsn = default(-1);
        int cwMin = default(-1);
        int cwMax = default(-1);
        string rxModule;
        @class(Dcaf);
        displayStringTextFormat = default("{contentionState}");
        @display("i=block/star");
        @signal[channelOwnershipChanged](type=bool);
        @statistic[channelOwnershipChanged](title="channel ownership"; record=count,vector?; interpolationmode=sample-hold);
    submodules:
        pendingQueue: <default("PendingQueue")> like IPacketQueue {
            parameters:
                @display("p=100,100");
        }
        inProgressFrames: InProgressFrames {
            parameters:
                pendingQueueModule = default("^.pendingQueue");
                originatorMacDataServiceModule = default("^.^.originatorMacDataService");
                ackHandlerModule = default("^.^.ackHandler");
                @display("p=100,200");
        }
        contention: <default("Contention")> like IContention {
            parameters:
                @display("p=100,300");
        }
}

File: src/inet/linklayer/ieee80211/mac/channelaccess/Dcaf.ned