[General]
network = LayeredAPSK
sim-time-limit = 100s
tkenv-plugin-path = ../../../etc/plugins
description = "host1 pinging host0"
cmdenv-express-mode = true
#debug-on-errors = true

**.vector-recording = false

*.numHosts = 2
**.arpType = "GlobalARP"

**.constraintAreaMinX = 0m
**.constraintAreaMinY = 0m
**.constraintAreaMinZ = 0m
**.constraintAreaMaxX = 1000m
**.constraintAreaMaxY = 400m
**.constraintAreaMaxZ = 0m

# mobility
**.host*.mobilityType = "StationaryMobility"
**.host*.mobility.initFromDisplayString = false
**.host[0].mobility.initialX = 100m
**.host[0].mobility.initialY = 200m
**.host[1].mobility.initialY = 200m
**.host[*].mobility.initialZ = 0m

# ping app (host[0] pinged by others)
*.host[0].numPingApps = 0
*.host[*].numPingApps = 1
*.host[*].pingApp[*].destAddr = "host[0]"

**.wlan[*].radio.transmitter.power = 0.1mW
**.wlan[*].radio.receiver.sensitivity = -109dBm
**.wlan[*].radio.receiver.snirThreshold = 1dB

**.wlan[*].typename = "Ieee80211Nic"
**.wlan[*].radioType = "APSKScalarRadio"
**.wlan[*].radio.carrierFrequency = 2.4GHz
**.wlan[*].radio.receiver.energyDetection = -90dBm
**.wlan[*].radio.receiver.channelSpacing = 20MHz
**.wlan[*].radio.bandwidth = 20MHz

## Iteration
#**.host[1].mobility.initialX = 100m + ${distance=240}m
**.host[1].mobility.initialX = 100m + ${distance=110..610 step 5}m
**.wlan[*].radio.**.levelOfDetail = ${detail="packet", "bit", "symbol"}
**.wlan[*].radio.**.modulation = ${modulation="BPSK", "QPSK", "QAM-16", "QAM-64"}
**.wlan[*].radio.**.fecType = ${fecType="", "ConvolutionalCoder"}
**.bitrate = ${bitrate=$fecType == "" ? 36Mbps : 18Mbps} # we want to have the same 36Mbps gross bitrate (applying 1/2 code rate) 

## Transmitter
**.wlan[*].radio.transmitterType = "APSKLayeredTransmitter"
**.wlan[*].radio.transmitter.encoderType = "APSKEncoder"
**.wlan[*].radio.transmitter.modulatorType = "APSKModulator"

# scrambler
#**.wlan[*].radio.transmitter.scramblerType = "TODO"
**.wlan[*].radio.transmitter.scrambler.seed = "1011101"
**.wlan[*].radio.transmitter.scrambler.generatorPolynomial = "0001001"

# FEC
**.wlan[*].radio.transmitter.encoder.fecEncoder.transferFunctionMatrix = "1 3"
**.wlan[*].radio.transmitter.encoder.fecEncoder.constraintLengthVector = "2"
**.wlan[*].radio.transmitter.encoder.fecEncoder.puncturingMatrix = "1; 1"
**.wlan[*].radio.transmitter.encoder.fecEncoder.punctureK = 1
**.wlan[*].radio.transmitter.encoder.fecEncoder.punctureN = 2

# interleaver
# **.wlan[*].radio.transmitter.encoder.interleaverType = "TODO"

## Receiver
**.wlan[*].radio.receiverType = "APSKLayeredReceiver"
**.wlan[*].radio.receiver.errorModelType = "APSKLayeredErrorModel"
**.wlan[*].radio.receiver.decoderType = "APSKDecoder"
**.wlan[*].radio.receiver.demodulatorType = "APSKDemodulator"

# descrambler
#**.wlan[*].radio.receiver.scramblerType = "TODO"
**.wlan[*].radio.receiver.descrambler.seed = "1011101"
**.wlan[*].radio.receiver.descrambler.generatorPolynomial = "0001001"

# FEC
**.wlan[*].radio.receiver.decoder.fecDecoder.transferFunctionMatrix = "1 3"
**.wlan[*].radio.receiver.decoder.fecDecoder.constraintLengthVector = "2"
**.wlan[*].radio.receiver.decoder.fecDecoder.puncturingMatrix = "1; 1"
**.wlan[*].radio.receiver.decoder.fecDecoder.punctureK = 1
**.wlan[*].radio.receiver.decoder.fecDecoder.punctureN = 2

# Deinterleaver
# **.wlan[*].radio.receiver.decoder.deinterleaverType = "TODO"

# MAC
**.wlan[*].mac.controlBitrate = 1Mbps
**.wlan[*].mac.dataBitrate = 54Mbps
**.wlan[*].mac.basicBitrate = 54Mbps
**.wlan[*].mac.multicastBitrate = 24Mbps
