SINRwithMIMO - getPhyMode(..., ..., lqm)
Hello dear developers,
i've implemented a 4x4 MIMO scenario (AP-->STA) using SINRwithMIMO-Rate adaptation. Binary Search for saturation point has been used.
http://
The number of used spatialstreams and the MCS should be modified inside the getPhyMode
00055 SINRwithMIMO:
The debug-informations after adding some control-messages just led me to the conclusion, that only the second getPhyMode from line 126 has been used through the whole simalution-time.
00126 SINRwithMIMO:
The matter is, I'd like to stored the SINR-values of previous transmissions and then use this informations to modify the function getPhyMode from line 55, so that, i could be able to use the previous SINR values before setting a MCS.
As far i can see, the storage of previous values can be managed by the SINRInformation
~/myOpenWNS/
One of the control-information inside SINRwithMode:
MESSAGE_
Below some lines of the debug-Informations. It's quite the same control-information all through the debug-output (./open-dbg)
at a scenario
-------
( 1.0209582) [WiFiM] AP1.L2.
( 1.0209582) [WiFiM] AP1.L2.1.TXOP accepting First compound
( 1.0209582) [WiFiM] AP1.L2.
( 1.0209582) [WiFiM] AP1.L2.
( 1.0209582) [WiFiM] AP1.L2.
( 1.0209582) [WiFiM] VCIB.VCIB Query for node 2, key numAntennas --> 4
( 1.0209582) [WiFiM] AP1.L2.
( 1.0209582) [WiFiM] AP1.L2.1.TXOP accepting First compound
-------
It seems like the RateAdaptation.cpp at line 105 calls the SINRwithMode:
In fact, i couldn't find a function like the main, that defines which function at which time will be called. The main-function(
Thanks for helping me out
Kharny
Question information
- Language:
- English Edit question
- Status:
- Solved
- Assignee:
- No assignee Edit question
- Solved by:
- kharny
- Solved:
- Last query:
- Last reply:
Revision history for this message
![]() |
#1 |
Dear Kharny,
All what you said is correct :-)
> The matter is, I'd like to stored the SINR-values of previous
> transmissions and then use this informations to modify the function
> getPhyMode from line 55, so that, i could be able to use the previous
> SINR values before setting a MCS.
No :-)
What you really would like to do is
1. measure the SINR-values of previous transmissions at the STA
2. send these measurements to the AP
3. which then can use this information to set the phy mode
In the current implementation, there is no SINR-feedback from the STA to
the AP. Hence, the AP cannot fill its SINRInformationBase with peer
measurements, and thus the rate adaptation has to use the getPhyMode
without the lqm:
http://
> As far i can see, the storage of
> previous values can be managed by the SINRInformation
> located in ~/myOpenWNS/
> (slidingWindowMap measuredSINRHol
Correct.
> It seems like the RateAdaptation.cpp at line 105 calls the SINRwithMode:
Correct, see above.
> In fact, i couldn't find a function like the main, that defines which
> function at which time will be called.
Essentially, the RateAdaptation uses the factory (aka strategy) pattern
to determine the specific type of rate adaptation (here, SINRwithMIMO,
as configured in the PyConfig). But, the function which is called is
determined then by the availability of SINR information - which is not
the case in your scenario.
I think that there are three possibilities for you:
1. Implement the link feedback and link adaptation as given in 802.11n
2. Use MPs instead of STAs: Here, the link feedback (averaged SINR only)
is done using the beacons.
3. Wait until we implement 1. - which is currently ongoing and will be
published when ready.
BR,
Sebastian
Revision history for this message
![]() |
#2 |
Hello Sebastian,
thanks for your message.
I had the wrong assumption, that the SINR-values would be measured inside the simulator, even thought, the different factors inside the simulator are known.
>I think that there are three possibilities for you:
>2. Use MPs instead of STAs: Here, the link feedback (averaged SINR only)
>is done using the beacons.
I'm about the use the MPs instead of STAs, but somehow i've got the following error-message while executing ./openwns-dbg in a scenario:
-------
openWNS: Caught wns::Assure:
In 'wns::container
failed assertion (index < v.size()).
Reason: out of range: index 2 >= 2
-------
Somehow, I think that the reason might be in wifimac.
-------
wifimac.
wifimac.
-------
By the way, how can we get the imformation, when something new is published? Or is there a particular link to be checked?
Thanks
Regards
Kharny
Revision history for this message
![]() |
#3 |
Dear Kharny,
> I had the wrong assumption, that the SINR-values would be measured
> inside the simulator, even thought, the different factors inside the
> simulator are known.
Of course the SINR is known in the simulator - but not processed for the
rate adaptation (especially the feedback to the transmitter does not
exists besides in the beacons).
> I'm about the use the MPs instead of STAs, but somehow i've got the
> following error-message while executing ./openwns-dbg in a scenario:
[...]
Most likely you have to adapt the number of nodes in the createVPS
statment in your config.py. Somewhere you should find:
# create (magic) service nodes for ARP, DNS, Pathselection, Capability
Information
...
WNS.simulationM
...
Try to set XYZ to some higher value. This should solve the problem.
> By the way, how can we get the imformation, when something new is
> published? Or is there a particular link to be checked?
You should be subscribed to the openwns-developer mailing list.
@Maciej, I cannot find any link (neither on launchpad nor on
openwns.org) for this. Can you change this??
BR & happy holidays,
Sebastian
Revision history for this message
![]() |
#4 |
Thanks Sebastian,
i've changed the virtual pathselection (VPS) and could solve that problem. Unfortunately i got another one coming from the Registry.hpp (/home/
-------
( 0.0000000) [CONST] Constanze onNodeCreated(): initializing 0 generators, 0 listeners.
( 0.0000000) [ IP] VARP.theOnlyZone MAC address 2 has 192.168.1.2
( 0.0000000) [ IP] VDNS.ip.
( 0.0000000) [ IP] MP2.IP.Forwarding Adding 192.168.1.2 to listening addresses
( 0.0000000) [ IP] MP2.IP.Routing Destination Gateway Genmask Iface
( 0.0000000) [WiFiM] AP1.L2.APUpperConv AP1: APUpperConv registered dataHandler
( 0.0000000) [ DLL] RANG.L2 Added AP1 with MAC Adr.: 1 to RANG!
( 0.0000000) [ IP] VARP.theOnlyZone MAC address -1 has 192.168.255.254
...
...
...
No ip::VirtualARP* with this key registered.
Key:
Elements with the following keys are registered:
- theOnlyZone
-------
I don't know exactly, what went wrong. I've configured a MP with
mpConfig.
and most of the time, just replaced "sta" by "mp", also in the ipListenerBinding; even thought, it didn't make a change with or without this ipListenerBinding for DL (if(dlIsActive)).
Thanks in advance
regards
Kharny
Revision history for this message
![]() |
#5 |
Hello Kharny,
Maybe you forgot to add/adjust the route from RANG to the MP after creating it?
rang.nl.
Regards,
Harry
Revision history for this message
![]() |
#6 |
Hi Harry,
thanks a lot for your message. That's was the last information i needed.
I've made some changes about the route RANG-MP in the NodeCreator.py (~/myFirstCampa
Thanks once more
BR
Kharny
Revision history for this message
![]() |
#7 |
Hi everybody,
there might be a problem in the implementation of my config.py-File.
I'd like to know, if there is a helpfull link to a tutorial , that gives informations about how to implement a MP for a scenario AP->MP ? I've got the following throughput (aggregated) results with almost the same configuration:
-------
-------
AP --> STA
AP --> MP
187 500 ... 193 750 Bit/s
-------
-------
Thanks
Regards
Kharny
Revision history for this message
![]() |
#8 |
hm...since I don't know your config file I can just guess...
did you run the simulation in debug mode? if not try that please to see if some assure statement failed, there errors that won't cause the opt run to crash but the debug version....
one hint: make sure that the beacon delays of AP and MP differ since after the succesive failure to receive beacons, a link is closed.... this won't cause the opt version of the simulator to crash but the debug version should exit with an appropriate error message
hoe that helps
Harry
Revision history for this message
![]() |
#9 |
Dear Harald,
thanks for your mail. The debug version work till the end with "wns::simulator
In fact, i've just used the same configuration as in experiment 7
http://
and just adapt some parameters like number of antennas (4) and distance AP-STA (20m).
Then if just try to adapt this configuration to the other scenario (AP->MP).
That's why, i've guessed, that i must have made something wriong at the second scenario.
Regards
Kharny
Revision history for this message
![]() |
#10 |
I am sorry, but I still can't imagine how the config might look like....if you use experiment7, I guess you removed the STA part and kept the MP configuration (for a single MP), adjustet the traffic configuration (listener / binder) to the MP and also added the correct routes?
(sorry for being that vague but it is really hard to guess what the problem might be without a line of code)
Regards,
Harry
Revision history for this message
![]() |
#11 |
Here is a copy of my code. I've add a wall in the middle, just for the see how the attenuation will affect the transmission results: so AP-->(Wall)-->MP.
The throughput results i mentioned are results by walllength = 0.
Thanks for helping me out
Kharny
-------
-------
-------
# begin example "wifimac.
import random
random.seed(22)
import openwns
from openwns import dB, dBm, fromdB, fromdBm
from openwns.interval import Interval
import constanze.traffic
import constanze.node
import wifimac.support
import wifimac.
import wifimac.
from wifimac.
import rise.Scenario
# end example
import ofdmaphy.Station # will be used here for phy of MP
# begin example "wifimac.
#######
# Simulation parameters
#
from SimConfig import params
simTime = params.simTime
settlingTime = 2.0
commonLoggerLevel = 2
dllLoggerLevel = 2
# mesh scenario parameter
numHops = params.numHops
distance = params.distance # Int-parameter
wallLength = params.wallLength
# load
packetSize = params.packetSize
offeredDL = (1.0-params.
offeredUL = params.ulRatio * params.
ulIsActive = (params.ulRatio > 0.0)
dlIsActive = (params.ulRatio < 1.0)
startDelayUL = 1.01
startDelayDL = 1.02
# Frequencies
networkFrequency = 2400 #5500
# End simulation parameters
#######
# end example
# begin example "wifimac.
#######
# Node configuration
# configuration class for AP and MP BSS transceivers
class MyMeshTransceiv
def __init__(self, beaconDelay):
# Transmission power
# set the inital start delay of the beacon so that beacons from multiple APs do not collide
# Use IEEE 802.11 DraftN enhancements
# Block-ACKs are longer than (default) normal ACKs
# settings for frame aggregation and block acknowledgement
# number of antennas for MIMO transmissions
# rate adaptation uses MIMO transmissions if possible
# For frames above this threshold (in bit) RTS/CTS will be used
# end example
# begin example "wifimac.
# configuration class for STAs
class MySTATransceive
def __init__(self, position):
# Transmission power
# Use IEEE 802.11 DraftN enhancements
# Block-ACKs are longer than (default) normal ACKs
# settings for frame aggregation and block acknowledgement
# number of antennas for MIMO transmissions
# rate adaptation strategy: STAs do not have link quality
# feedback, hence no SINR-based rate adaptation
# For frames above this threshold (in bit) RTS/CTS will be used
# End node configuration
#######
##end example
# begin example "wifimac.
# create an instance of the WNS configuration
# The variable must be called WNS!!!!
WNS = openwns.
WNS.outputStrategy = openwns.
WNS.maxSimTime = simTime
WNS.statusWrite
WNS.probesWrite
# end example
# begin example "wifimac.
#################
# Create scenario
#sizeX = distance
sizeX = (numHops)*distance
sizeY = 10 + wallLength#10
scenario = rise.Scenario.
riseConfig = WNS.modules.rise
riseConfig.
riseConfig.
riseConfig.
ofdmaPhyConfig = WNS.modules.
managerPool = wifimac.
# end example
# begin example "wifimac.
# single wall from (0,5) to (wallLength,5)
objs = []
objs.append(
print "Created Wall from (",distance/2,",0.0 ,0.0) till (",distance/
#makeABreak #######
# end example
# End create scenario
#######
# end example
# begin example "wifimac.
#######
# Radio channel propagation parameters
myPathloss = rise.scenario.
validFreque
validDistances = Interval(2, 5000), #[m]
offset = dB(-27.552219),
freqFactor = 20,
distFactor = 35,
distanceUnit = "m", # only for the formula, not for validDistances
minPathloss = dB(42), # pathloss at 2m distance
outOfMinRange = rise.scenario.
outOfMaxRange = rise.scenario.
scenarioWrap = False,
sizeX = sizeX,
sizeY = sizeY)
#myShadowing = rise.scenario.
myShadowing = rise.scenario.
myFastFading = rise.scenario.
propagationConfig = rise.scenario.
pathloss = myPathloss,
shadowing = myShadowing,
fastFading = myFastFading)
# End radio channel propagation parameters
#######
#end example
# begin example "wifimac.
#######
#Create nodes using the NodeCreator
nc = wifimac.
# one RANG
rang = nc.createRANG(
WNS.simulationM
# create (magic) service nodes for ARP, DNS, Pathselection, Capability Information
WNS.simulationM
WNS.simulationM
WNS.simulationM
WNS.simulationM
# end example
# begin example "wifimac.
# Single instance of id-generator for all nodes with ids
idGen = wifimac.
# save IDs for probes
apIDs = []
mpIDs = []
staIDs = []
apAdrs = []
mpAdrs = []
# end example
# begin example "wifimac.
# Create AP
apConfig = wifimac.
apConfig.
ap = nc.createAP(idGen, managerPool, apConfig)
ap.logger.level = commonLoggerLevel
ap.dll.logger.level = dllLoggerLevel
WNS.simulationM
apIDs.append(ap.id)
apAdrs.
rang.dll.addAP(ap)
print "Created AP at (0,10,0) with id ", ap.id, " and addresses ", ap.dll.addresses
# end example
#makeABreak #######
# begin example "wifimac.
mpConfig = wifimac.
mpConfig.
mp = nc.createMP(idGen, managerPool, mpConfig)
mp.logger.level = commonLoggerLevel
mp.dll.logger.level = dllLoggerLevel
rang.nl.
# end example
# begin example "wifimac.
if(dlIsActive):
# DL load RANG->STA
cbrDL = constanze.
ipBinding = constanze.
rang.
# Listener at STA for DL
ipListenerB
listener = constanze.
mp.
if(ulIsActive):
# UL load STA->RANG
cbrUL = constanze.
ipBinding = constanze.
mp.
# begin example "wifimac.
# Add STA
#WNS.simulation
#staIDs.
#print "Created STA at (",distance, ",10,0) with id ", sta.id
WNS.simulationM
mpIDs.append(mp.id)
mpAdrs.
print "Created MP at (", distance, ",10,0)",
print "with id ", mp.id, " and addresses ", mp.dll.addresses
#makeABreak #######
# End create nodes
##################
# end example
# begin example "wifimac.
#########
# Probing
# wifimac probes
wifimac.
wifimac.
# end example
openwns.
-------
-------
-------
campaignConfigu
import sys
import os
def searchPathToSDK
rootSign = ".thisIsTheRoot
while rootSign not in os.listdir(path):
if path == os.sep:
# arrived in root dir
return None
path, tail = os.path.split(path)
return os.path.
pathToSDK = searchPathToSDK
if pathToSDK == None:
print "Error! You are note within an openWNS-SDK. Giving up"
exit(1)
# begin example "wifimac.
from wrowser.
import wrowser.
import wrowser.
import subprocess
# end example
# begin example "wifimac.
class Set(AutoSimulat
# scenario parameters
simTime = Float(parameter
numHops = Int(parameterRange = [1])
wallLength = Float(parameter
distance = Int(parameterRange = [20]) #[20])#[30])#[50])
ulRatio = Float(parameter
packetSize = Int(parameterRange = [1480*8])
# input parameter
offeredTraffic = Int(default = 100000)
# end example
# begin example "wifimac.
def getTotalThrough
myQuery = " \
SELECT idResults.
FROM moments VAL, (SELECT scenario_id, " + inputName + " FROM parameter_sets \
WHERE VAL.scenario_id = idResults.
ORDER BY idResults." + inputName + ";"
cursor.
resultsIn = cursor.fetchall()
myQuery = " \
SELECT idResults.
FROM moments VAL, (SELECT scenario_id, " + inputName + " FROM parameter_sets \
WHERE VAL.scenario_id = idResults.
ORDER BY idResults." + inputName + ";"
cursor.
resultsAgg = cursor.fetchall()
results = []
for i in zip(resultsAgg, resultsIn):
agg = i[0]
inc = i[1]
return results
# end example
# begin example "wifimac.
conf = config.
conf.read(
db.Database.
cursor = db.Database.
# end example
# begin example "wifimac.
params = Set('offeredTra
[status, results] = params.
# end example
Revision history for this message
![]() |
#12 |
hm...how old is your openWNS version? e.g. you subclass your mesh transceiver from support.
However, after getting your config to run, the result is quite normal (50 Mb/s with 1 antenna, > 100 Mb/s with 4)
I know this will cost you some time, but I suggest to update openWNS and modify e,g, the current experiment7 files
Regards,
Harry
Revision history for this message
![]() |
#13 |
Hello Harald,
it works now. The size of an array, that i used to stored some SINR-values, was not big enough. I guess, this lead to the weird behavior of the compiler. Probably i've already made some changes in the src-code at the time i changed the scenario AP-->STA to AP-->MP and that might be the reason, why...
I've installed my Version of openWNS for about 5 mounths ;-)
Thanks to all of you once more, this solve my problem
Regards
Kharny