Experiment ( Feb.7-12 2004 )

Zhibin Wu

[RSSI.vs. PER.vs. Throughput] [Traffic Throtlle | Report in PDF format]


 data of 2-14 exp:
AP (tx-power -15dbm)(10.0.0.1)
RSSI
dbm
distance
Txpower
Uplink Quality
Node1(10.0.0.2)(in the corner)
60
-58??
12feet
1mW
poor (contention failure)
Node2(10.0.0.3)
82
-54
11feet
1mW
Good
Node3(10.0.0.6)
72
-60??
15feet
1mW
Fair
Node4(10.0.0.7)
78
-57
15feet
1mW
Fair



Througput Chart:

700
800
900
1000K
1100K
1200
1300
1400
1500
Node 1
0.3162
0.3576
0.4825
0.3327
0.3496
0.1508
0.2437
0.1985
0.3283
Node 2
0.7240
0.8230
0.9272
1.0292
1.1272
1.2344
1.3376
1.3444
1.3377
Node 3
0.6014
0.6787
0.7405
0.6889
0.7208
0.5117
0.6040
0.6009
0.9395
Node 4
0.5505
0.6543
0.7013
0.5900
0.6077
0.8876
0.7580
0.5745
0.7310
total
2.1921
2.5136
2.8515
2.6408
2.8053
2.7845
2.9433
2.7183



Throughput with contention index divison algorithm

1000 with tc
1000 tc only node 1
6
5
4
3
2
Node 1
0.2752
0.2064





Node 2
1.0289
1.0290





Node 3
0.9209
0.9556





Node 4
0.8720
1.0078





total









Feb.15 Exp.

AP (tx-power -15dbm)(10.0.0.1)
RSSI
dbm
distance
Txpower
Uplink Quality
Node1(10.0.0.2)(in the corner)
62
-58
12feet
1mW
poor
Node2(10.0.0.3)
82
-54
11feet
1mW
Good
Node3(10.0.0.6)
72
-62
15feet
1mW
fair
Node4(10.0.0.7)
70
-57
15feet
1mW
Fair


offerload 1200K
Mbps





*
Node 1
0.0456
0.2048
0.0030
0.0979
0.2254
0.0864
0.0715
Node 2
1.1784
1.1827
1.2174
1.2168
1.2093
1.2172
1.2377
Node 3
0.1622
0.7682
0.9858
1.0055
0.7311
0.9836
1.1100
Node 4
0.7150
0.7187
0.1035
0.3487
0.2123
0.4479
0.8826
without scheduling
with scheduling








0.0083
0.1098
0.1979
0.0802
0.1002

0.1837

1.2343
1.1980
1.2338
1.2357
1.2353

1.2343

0.5974
1.1792
0.7699
0.8066
1.0003

0.9143

0.9899
1.0478
0.3568
0.8503
0.3229

0.2783

*The last low only scheduled node 1 ,and the measurements are not done in a consecutive manner.

1. 1200K no scheduling:

RSSI .vs. Packet loss ratio (Number of noack/ total transmission): (paclket size = 1024B)
dbm
RSSI (%)
PER
Expected Throughput(Mbps)
>=-45
100
0
4.5
-47
96
0.01
4.4
-50
90
0.06653
4.2
-54
81
0.1078  
3.7(*3.8078)

77
6-9%

-57
76
0.25156 (10-12%)
3.0 (3.0159*)

74
14-23%
2.5
-59
72
0.34917 (33-40%)
2.2655*
-60
70
0.48045?
1.8
-62
67
0.55
1.1
-62
66
0.6
1
-65
60
0.75556
0.4 (0.3409*)
-71
49
0.92994
0.1
* actual througphut measured




PER .vs. Througphut Expectation:
T =  Tmax * (1-PER); this is not good!!!



RSSI .vs. Throughput Expectation: (with interpolation) and loss ratio
----------------------------------------------------------------------------------------------RPT FILE --------------------------------------------------------------
100 4500 101
99 4500 101
98 4450 101
97 4425 101
96 4400 101
95 4355 101
94 4325 200
93 4300 200
92 4300 200
91 4250 300
90 4200 300
89 4150 400
88 4100 500
87 4050 500
86 4000 600
85 3950 600
84 3900 700
83 3830 800
82 3760 900
81 3700 1000
80 3600 1100
79 3400 1200
78 3200 1300
77 3100 1400
76 3000 1500
75 2800 1600
74 2650 1800
73 2500 2000
72 2250 2200
71 2050 2500
70 1800 3000
69 1500 3300
68 1300 3700
67 1100 4000
66 1000 4400
65 900 4800
64 800 5300
63 700 5700
62 600 6200
61 500 6800
60 400 7500
59 370 7800
58 320 7900
57 270 8100
56 230 8400
55 200 8700
54 180 8900
53 150 9000
52 130 9100
51 120 9200
50 110 9200
49 100 9300
48 100 9300
47 100 9400
46 100 9400
45 100 9400
44 100 9400
43 100 9400
42 100 9400
41 100 9400
40 100 9400
39 100 9400
38 100 9400
37 100 9500
36 100 9500
35 100 9500
34 100 9500
33 100 9500
32 100 9500
31 100 9500
30 100 9500
29 100 9600
28 100 9600
27 100 9600
26 100 9600
25 100 9600
24 100 9700
23 100 9700
22 100 9700
21 100 9800
20 100 9800
19 100 9900
18 100 9900
17 100 9900
16 100 9900
15 100 9900
14 100 9900
13 100 9900
12 100 9900
11 100 9900
10 100 9900
9 100 9900
8 100 9900
7 100 9900
6 100 9900
5 100 9900
4 100 9900
3 100 9900
2 100 9900
1 100 9900
0 100 9900


Script for RSSI_PER scheme
#para 1: test time
#para 2 : enable traffic control or not, 1-enalbe, 0-disable
#para 3:   file to save rssi value



if [ $# -lt 3 ]
then
echo "$0 : You must give/supply 3 parameters"
exit 1
fi


((time_tick=$1*3))
#1 second = 90 mini-tick = 1.1~1.5s
total_rssi=0
total_retry=0
total_ack=0
prev_retry=`cat /proc/driver/aironet/eth1/Stats |grep RetryLong |awk '{print $2}'`
prev_ack=`cat /proc/driver/aironet/eth1/Stats |grep RxAck |awk '{print $2}'`

prev_pl=0

for (( i=0; i<$time_tick ; i++))
do

   per_rssi=0

   for ((j=0;j<30;j++))
   do
   rssi_cur=`cat /proc/driver/aironet/eth1/Status |grep Strength |awk '{print $3}'`
   per_rssi=`expr $per_rssi + $rssi_cur`
#    sleep 0.01s
   done
    ((total_rssi=$total_rssi+$per_rssi))
    ((per_rssi=$per_rssi/30))

   cur_retry=`cat /proc/driver/aironet/eth1/Stats |grep RetryLong |awk '{print $2}'`
   per_retry=`expr $cur_retry - $prev_retry`
   prev_retry=$cur_retry

   cur_ack=`cat /proc/driver/aironet/eth1/Stats |grep RxAck |awk '{print $2}'`
   per_ack=`expr $cur_ack - $prev_ack`
   prev_ack=$cur_ack

   total_retry=`expr $total_retry + $per_retry`
   ((total_ack=$total_ack+$per_ack))


   if [ $per_ack -eq 0 ]
   then
     pl_value=$prev_pl  #cannot use 100 percent loss, use previous value
   else
     ((pl_value=100*$per_retry/($per_ack+$per_retry)))
   fi

prev_pl=$pl_value
rs_index=`grep -w $per_rssi rtp | awk '{print $2}'`

#new discrimination rule
if [ $pl_value -gt 50 ]
then
   c=10
  # ((c=$rs_index*(100-$pl_value)*(100-$pl_value)/10000))
else
   ((c=$rs_index*(100-$pl_value)/100))
fi

b=kbit
c_rate=$c$b


if [ $2 -eq 1 ]
   then

   tc qdisc del dev eth1 root
   echo "$per_rssi $pl_value $c_rate" >> $3
   tc qdisc add dev eth1 root handle 1: cbq avpkt 1024 bandwidth 11mbit
   tc class add dev eth1 parent 1: classid 1:1 cbq rate $c_rate \
          allot 1500 prio 1 bounded isolated

   tc filter add dev eth1 parent 1: protocol ip prio 16 u32 \
          match ip dst 10.0.0.1 flowid 1:1
fi

done
((avg_rssi=$total_rssi/$time_tick/30))
echo "average rssi is $avg_rssi"
echo "average retry_count is `expr $total_retry / $time_tick`"
echo "average ack_count is `expr $total_ack / $time_tick`"
echo "average PER is F: $total_retry and S: $total_ack"
if [ $2 -eq 1 ]
   then
   tc qdisc del dev eth1 root
fi


Script for RSSI-PER-Contention Index Scheme:

#para 1: test time
#para 2 : enable traffic control or not, 1-enalbe, 0-disable
#para 3:  weight of RSSI-based throughput ,1 to 9
#para 4:  weight of PER-based throughout, 9 to 1
#para 5:   file to save rssi value
#para 6:   file to save static rssi and Packet loss ratio

# metric about PER correlated throughput
# PER<0.5  100k
#     0.5-0.6 200k
#     0.6-0.7 400K
#     0.7-0.8 800K
#     0.8-0.9 1600K



if [ $# -lt 6 ]
then
echo "$0 : You must give/supply 6 parameters"
exit 1
fi


time_tick=$1  #1 timetick = 100 mini-tick = 1.2~1.7s
total_rssi=0
total_retry=0
total_ack=0
prev_retry=`cat /proc/driver/aironet/eth1/Stats |grep RetryLong |awk '{print $2}'`
prev_ack=`cat /proc/driver/aironet/eth1/Stats |grep RxAck |awk '{print $2}'`

cont_index=100

#contention index from 100-1000 (1-10). this value is derived from  both PER deviation and RSSI, the minimum contention index is 100, the rate is set to rs_index*100/cont_index

for (( i=0; i<$time_tick ; i++))
do
   #long term statisctics of RSSI
   long_rssi=0

   #first loop for long-term measurement
   for ((k=0;k<10;k++))
   do
       per_rssi=0
   #second loop for short-term measurement and instanteneous adjust
   for ((j=0;j<10;j++))
   do
   rssi_cur=`cat /proc/driver/aironet/eth1/Status |grep Strength |awk '{print $3}'`
    per_rssi=`expr $per_rssi + $rssi_cur`
#    sleep 0.01s
   done
    ((total_rssi=$total_rssi+$per_rssi))
    ((per_rssi=$per_rssi/10))
    ((long_rssi=$long_rssi+$per_rssi))


rs_index=`grep -w $per_rssi rtp | awk '{print $2}'`
pl_index=`grep -w $long_rssi rtp | awk '{print $3}'`

#new discrimination rule
((rs_index=$rs_index*(10000-pl_index)/100))

#echo "$per_rssi $rs_index"
((c=$rs_index*100/$cont_index))

b=kbit
c_rate=$c$b


if [ $2 -eq 1 ]
   then
   #if [ $i -gt 0 ]
   #then
      tc qdisc del dev eth1 root
   #fi
   echo "$per_rssi $cont_index $c_rate" >> $6
   tc qdisc add dev eth1 root handle 1: cbq avpkt 1024 bandwidth 11mbit
   tc class add dev eth1 parent 1: classid 1:1 cbq rate $c_rate \
          allot 1500 prio 1 bounded isolated

   tc filter add dev eth1 parent 1: protocol ip prio 16 u32 \
          match ip dst 10.0.0.1 flowid 1:1
fi
#here, Rate throttle is set and we are going to back for next 10 mini-ticks for a newRSSI upadte and new rate set-up
done
#here, we have to calculate PER of last 100 mini-tick (1.2~1.5 seconds),
   ((long_rssi=$long_rssi/10))

   cur_retry=`cat /proc/driver/aironet/eth1/Stats |grep RetryLong |awk '{print $2}'`
   per_retry=`expr $cur_retry - $prev_retry`
   prev_retry=$cur_retry

   cur_ack=`cat /proc/driver/aironet/eth1/Stats |grep RxAck |awk '{print $2}'`
   per_ack=`expr $cur_ack - $prev_ack`
   prev_ack=$cur_ack

   total_retry=`expr $total_retry + $per_retry`
   ((total_ack=$total_ack+$per_ack))

#packet loss index from the table
pl_index=`grep -w $long_rssi rtp | awk '{print $3}'`

if [ $per_ack -eq 0 ]
then
    pl_value=100
else
   ((pl_value=100*$per_retry/($per_ack+$per_retry)))
fi

#!new change----------------------
((diffe=$pl_value-$pl_index/100))
#-------------------------------
if [ $diffe -le 0 ]
then
    diffe=0
else
    diffe=$diffe*10  #basic contention index, 100 means 10 deviation of pl percent
fi

#rssi-based adjust (0-100)

if [ $long_rssi -le 50 ]
then
    ad_ratio=2000
else
    ((ad_ratio=2000/($long_rssi-50)))
fi

((diffe=$diffe*$ad_ratio/100))
((cont_index=$diffe+100))


echo "$long_rssi $pl_index $pl_value" >> $5

done
((avg_rssi=$total_rssi/$time_tick/100))
echo "average rssi is $avg_rssi"
echo "average retry_count is `expr $total_retry / $time_tick`"
echo "average ack_count is `expr $total_ack / $time_tick`"
echo "average PER is F: $total_retry and S: $total_ack"
if [ $2 -eq 1 ]
   then
   tc qdisc del dev eth1 root
fi