Wireless Communications with GNU SDR - PowerPoint PPT Presentation

About This Presentation
Title:

Wireless Communications with GNU SDR

Description:

... Communications with GNU SDR. Writing a signal processing ... As mentioned earlier, the signal processing is carried out by the signal processing blocks. ... – PowerPoint PPT presentation

Number of Views:51
Avg rating:3.0/5.0
Slides: 20
Provided by: zhen6
Learn more at: http://www.cs.fsu.edu
Category:

less

Transcript and Presenter's Notes

Title: Wireless Communications with GNU SDR


1
Wireless Communications with GNU SDR
2
Writing a signal processing block
  • http//www.nd.edu/jnl/sdr/docs/tutorials/10.html
  • As mentioned earlier, the signal processing is
    carried out by the signal processing blocks.
  • The signal processing blocks are written in C.
  • Each block has input ports and output ports.
  • A block is fed with input data and will spit out
    output data.
  • Multiple blocks are connected by the flow graph.
    Each block runs in parallel supported by
    threads.
  • So keep in mind that you are writing a parallel
    program!
  • There is a central scheduler which sets up
    buffers between the blocks and determines how
    much data each block should consume. Each block
    should also tell the scheduler how much data it
    has produced. It is the central schedulers job
    to keep the flow running without stalling. But
    you need to tell the scheduler the correct
    information.

3
SPB
  • Any block is directly or indirectly derived from
    the gr_block class.
  • To specify the input/output ports
  • gr_io_signature_sptr    d_input_signature     
  • gr_io_signature_sptr    d_output_signature
  • Smart pointer is used to make sure that ojbect it
    points to is automatically deleted
  • gr_io_signature_sptr

4
SPB
  • The core of a block
  • Does the real work -- The central scheduler calls
    it every once a while, tell it the maximum number
    of output items it can produce in noutput_items,
    tell it how many items are available at each
    input ports in array ninput_items, provides
    pointers to the arrays of input items in
    input_items which the function can read, and
    provides pointers to arrays of output items which
    it can write to.
  • The returned value is the actual number of items
    produced to the output ports. Must be the same
    for each output port. Can be less than
    noutput_items.
  • At the end of the function, tell the central
    scheduler how many items consumed from each input
    port. Can be different.

5
Compile and Install
  • http//www.nd.edu/jnl/sdr/docs/tutorials/11.html
  • After writing the SPB, you need to compile it and
    install it and make it callable from Python.
  • Here are the rules.
  • First, you need to organize your directory as
    (just copy everything from an existing block and
    modify!)

6
SPB
  • Then, you need to write a .i file to tell SWIG,
    the Simplified Wrapper and Interface Generator to
    generate the interface callable by Python.
  • The .i file is very small and normally you dont
    have to do a lot with it except change the class
    names to the one you are currently using (the
    details in the online tutorial.)
  • Then you need to modify Makefile.am, also just to
    update some names (the details in the online
    tutorial)
  • Then you need to modify configure.ac at the top
    directory, only two lines (the details in the
    online tutorial)

7
SPB
  • Then, run these commands. If your code is right
    everything should be fine.

8
Linear System
  • In signal processing, for most of the times, we
    deal with linear systems.

h(t)
x(t)
y(t)
  • A linear system is a system such that Tax_1(t)
    bx_2(t) aTx_1(t) bTx_2(t).
  • Suppose Tx(t)y(t). A linear system is time
    invariant if Tx(t-\tau) y(t-\tau).

9
Digital Signal Processing
  • In fact, most of the signal processing is done
    digitally.
  • For example, the sender reads the bits, process
    the bits into digital waveforms, and send it out.

10
Impulse Response
  • A digital linear time invariant system can be
    FULLY described by its impulse response.
  • It is usually written as hn, which is the
    output of the system when the input is \deltan,
    which is 1 when n0 and 0 for all other values of
    n.

11
Impulse Response
  • The reason is, all signals can be represented as
    linear combinations of \deltan
  • xn\sum_k-\infty\infty x_k \deltak,
    where x_k is a number equal to xk.
  • We really didnt do anything here
  • But, recall the definition of a linear time
    invariant (LTI) system, we can write the output
    as
  • yn \sum_ k-\infty\infty x_k hn-k
  • This is the KEY expression called convolution.
    You need to understand this to understand lots of
    other things.

12
Example
  • The digital low pass filter.
  • Consider the simplest one (the one we discussed
    in the last lecture) average recent samples.
  • ynxnxn-1/2
  • Intuitively, it should average out some sudden
    changes.
  • h0h11/2.

13
The Simple Low Pass Filter
  • The simple low pass filter, what does it do in
    the frequency domain?
  • To do this, we consider DFT (Digital Fourier
    Transformation) defined as
  • H(j) \sum_n0N-1 hn e-j n 2\pi/ N,
    where N is the number of non-zero points of hn.
  • Its basically the same as the continuous FT.
    \sum_n0N-1 hn e-j n 2 \pi/ N is just
    to take a sample on a certain frequency from the
    time domain signal, cause all other frequency
    components are going to be 0.
  • If the sample time is T, H(j) represents the
    signal strength at frequency j/NT. (e-j n 2
    \pi/ N repeats every N/j samples. So, in
    continuous time, it repeats every NT/j seconds.)

14
DFT
  • So, the DFT of the simple low pass filter can be
    calculated.
  • DFT_h(j) 1/21e-2j \pi / N.

15
Convolution and Frequency
16
The RRC Filter
  • The LPF we used is called the root raised
    cosine filter.
  • Check http//www.dsplog.com/2008/04/22/raised-cosi
    ne-filter-for-transmit-pulse-shaping/

17
Why use RC
  • The problem is that the baseband waveform is
    generated but you have to take samples at the
    receiver side to determine the bits.
  • If using some arbitrary LPF, the signal shape is
    arbitrary and the samples you take for yn will
    have interferences from yn-1, yn-2, ,
    yn1, yn2
  • So you want to use LPF such that all other
    non-relevant samples have 0 influence on the
    current sample.
  • The Raised Cosine Filter satisfies this
    constraint
  • Root means that the sender and receiver will each
    do half of it.

18
Carrier Phase Tracking
19
Sample Time
Write a Comment
User Comments (0)
About PowerShow.com