SPW  (Signal Processing Worksystem)

Zhibin Wu


Begin SPW

To start SPW in UNIX machine, chance .cshrc. add "setenv SPW_ENVIRONMENT" at the top of the file.
Create a new library in your own home directory. named as libname
Design new system in a BDE, save it as [*.system]. With this extension, it can be simulated with Simulator Manager.

Run Simulation

For example, the simplest system has a source and sink. Add those blocks in the diagram, then change the parameters of data file as libname/in, libname/out.
Use the signal calculator to generator a data source, and save it as libname/in
Run the Simulator, and compare the in and out with signal calculator.

If Simulation Manager is used, we can choose two ways to simulate when is SPB-I, SPB-C. For small number of samples, SPB-I  (Interpreter) is OK. but for large number of samples. the SPB-C will execute a compiled program from C code. It would be faster.

What is Samples and Base rate?

The SPW is a total discrete signal processing system, all the signals are a series of samples. It seems not directly relevant to time seconds. As long as all the blocks in the diagram has a same "Sampling Frequency=1", then all the other frequencies are related to this Fs. For example, we design a low pass filter who has cut-off frequency as 0.25, is related to this sample frequency Fs. Signals normally has a frequency smaller than 1 if the Fs is set to 1. For example. a sine wave has f=0.01 when fs=1 is equivalent to f=100Hz but fs=10,000.  Same sample points are generated for both cases. 2000 samples will have 20 periods of sine waves.  
Further, it seems that in a system the sampling frequency of different blocks could be different. For example, in some blocks in 802.11b system the Fs=11MHz, but in some block, it is till 1. Seems only the number of samples matters. Remember, if the filter has not to deal with the concept of frequency, we only care how many taps it has.
A single-rate simulation only running on one sampling frequency ( Actually, it does not matter what the frequency is). Because, each Signal Processing block will process one-sample in one loop until all the samples are all processed. The multi-rate system, also, does not consider the actual frequencies used in the system; it merely sets up the ratios corresponding to different simulation rates and processes the signal data in the proper sequence.

When a point in the design is selected, base rate can be set as ratio of this point, the default value of this ratio is 1.0. The default base rate of this 802.11b design is the packet rate (which means ???? samples for a packet is regarded as a basic unit).

Simulation 802.11b in a Multi-path indoor environment

In the given block design of 802.11b system, the whole design is based on a baseband system and only Complex Gaussian noise are introduced. The base rate is =1.0. Let's assume 5000 packets and each has a 500 Bytes, then the total number of samples should be 5,000*4000= 20,000,000. There is a tab in which in you can specify how many runs you want to run. And for each run, which parameter needs to be updated with what size of step. The 802.11b design is a Error-Measurement system. Thus, there is  a "write-vector" block within the error-count block. Change the filename and attributes of the block to let the results saved in my home directory or /tmp.
However, when I use 20 million samples and 200B PSDU, it also only has ~5,300 frames simulated. Seems that the above calculation is wrong.

Results are showing in the following table:

Packets   Data_rate  PSDU     Eb/N0   Dec_soft Ch_fade  Fade_fix  T_rms     PER      BER



5377 11 200 0 0 1 1 50 0.979353 0.304004

5377 11 200 2 0 1 1 50 0.914249 0.226239

5377 11 200 4 0 1 1 50 0.794829 0.155605

5377 11 200 6 0 1 1 50 0.654948 0.0988202

5377 11 200 8 0 1 1 50 0.516555 0.0577426

5377 11 200 10 0 1 1 50 0.377232 0.031092

5377 11 200 12 0 1 1 50 0.260417 0.0158067

5377 11 200 14 0 1 1 50 0.169085 0.00746187

5377 11 200 16 0 1 1 50 0.110677 0.00341936

5377 11 200 18 0 1 1 50 0.0697545 0.00165551

5377 11 200 20 0 1 1 50 0.046131 0.000872163

It's found that the "toolrun" directory saved in the lib is quite large, so I prefer to rm -rf *  in that directory.

 

SPW Project in WSID course

The course required Netstumbler to be used to measure SNR. This software is designed based on the Orinoco-chip and drivers. With the most recent version of Net Stumbler, it supports Prism-2 chips with NDIS driver. However, with this driver the noise level is always -100dbm, and never changed. Thus, the SNR ratio is not measured accurately.

With a linksys card and Netstumber software, the AP in WINLAB computer lab ( working in channel 11) has a 10db drop from 5 feet-distance to 30-feet. However, the SNR is so large. (at least 40db)  It will not match with our 0-20db simulation and few packet errors will be seen at this SNR level.

The solution is: 1 reduce the AP power. 2 Measure with other distance, and locations with lower signal level.

Also, Netstumbler is not necessary for this project. We can write a Perl script to record SNR from a cisco or linksys card at the same time when Netperf or dbs is running. The problem is that this SNR report cannot  guarantee that the SNR is only measured for packets coming form AP, maybe all packets in channel 11 in WINLAB will be measured. But it is still doable when we test it in the very morning in WINLAB.


1. A consensus seems to be reached that we don't need to get statistics
from the driver. Instead, if we use UDP traffic with DBS and disable the
MAC retry in the sender ( in Netgear card (hostap)), then we could have a
tracefile which shows the PER.
                                                                               
2. It has been found that the beacon is an management frame sent by the
rate of
1Mbps, which means the SNR measuremnt cannot be applied to real
transmission which is probably 11Mbps. So, we have go back to SPW to get
a calculaton of SNR conversion. the method is: 1. set the rate to 1Mbps,
and set the SNR to the value we measured with net-stumbler, record the
Eb/N0, 2. fixed the Eb/N0, and change the value to 11Mbps, the real SNR
will be same as Eb/N0. thus, we don't need to do simulation again, we can
still use the curve (after interpolation) we get from SPW(but with different values), I guess
this time the laptop with netstumbler does not need to go so far in the
corridor.
                                                                               
One thing is forgotten in yesterday's discussion, the frame size has to be
accurately set before experiments. Sumathi, are you sure about the header
length u said? Or, we need Ethereal to verify it.
                                                                               
It is better to do some experiment tomorrow morning in classroom with
three laptops availabe. if 8-9am is OK for you, could u come?
Pandaurang, could u share the perl script with us?