The 29 th Annual ARRL and TAPR Digital Communications Conference. DSP Short Course Session 4: Tricks of the DSP trade. Rick Muething, KN6KB/AAA9WK

Similar documents
The 29 th Annual ARRL and TAPR Digital Communications Conference. DSP Short Course Session 3: How to use DSP. Rick Muething, KN6KB/AAA9WK

The 29 th Annual ARRL and TAPR Digital Communications Conference. DSP Short Course Session 1: DSP Intro and Basics. Rick Muething, KN6KB/AAA9WK

Understanding Digital Signal Processing

Digital Signal Processing

B.Tech III Year II Semester (R13) Regular & Supplementary Examinations May/June 2017 DIGITAL SIGNAL PROCESSING (Common to ECE and EIE)

Chapter 5 Window Functions. periodic with a period of N (number of samples). This is observed in table (3.1).

GUJARAT TECHNOLOGICAL UNIVERSITY

Measurement of RMS values of non-coherently sampled signals. Martin Novotny 1, Milos Sedlacek 2

Using the DFT as a Filter: Correcting a Misconception by Richard G. Lyons

EECS 452 Midterm Closed book part Winter 2013

6 Sampling. Sampling. The principles of sampling, especially the benefits of coherent sampling

Frequency Domain Representation of Signals

(i) Understanding of the characteristics of linear-phase finite impulse response (FIR) filters

(i) Understanding of the characteristics of linear-phase finite impulse response (FIR) filters

Discrete Fourier Transform (DFT)

Signal Processing Toolbox


Outline. Communications Engineering 1

Lecture 3 Review of Signals and Systems: Part 2. EE4900/EE6720 Digital Communications

Design of Frequency Demodulator Using Goertzel Algorithm

Design of Bandpass Delta-Sigma Modulators: Avoiding Common Mistakes

Time Series/Data Processing and Analysis (MATH 587/GEOP 505)

Analysis of Complex Modulated Carriers Using Statistical Methods

The Polyphase Filter Bank Technique

Part One. Efficient Digital Filters COPYRIGHTED MATERIAL

Team proposals are due tomorrow at 6PM Homework 4 is due next thur. Proposal presentations are next mon in 1311EECS.

VLSI Implementation of Digital Down Converter (DDC)

Chapter 9. Chapter 9 275

Recap of Last 2 Classes

Digital Filters IIR (& Their Corresponding Analog Filters) Week Date Lecture Title

UNIT-2 Angle Modulation System

Multirate Digital Signal Processing

Module 9: Multirate Digital Signal Processing Prof. Eliathamby Ambikairajah Dr. Tharmarajah Thiruvaran School of Electrical Engineering &

EECS 452 Midterm Exam Winter 2012

Agilent Vector Signal Analysis Basics. Application Note

Laboratory Assignment 5 Amplitude Modulation

Appendix B. Design Implementation Description For The Digital Frequency Demodulator

Signal Processing Techniques for Software Radio

ADSP ADSP ADSP ADSP. Advanced Digital Signal Processing (18-792) Spring Fall Semester, Department of Electrical and Computer Engineering

Lecture 6. Angle Modulation and Demodulation

Norfolk Amateur Radio Club

ELEC3242 Communications Engineering Laboratory Amplitude Modulation (AM)

Channelization and Frequency Tuning using FPGA for UMTS Baseband Application

Waveshaping Synthesis. Indexing. Waveshaper. CMPT 468: Waveshaping Synthesis

Equalizers. Contents: IIR or FIR for audio filtering? Shelving equalizers Peak equalizers

Part I - Amplitude Modulation

Digital Signal Processing

Discrete Fourier Transform, DFT Input: N time samples

Spectrum. Additive Synthesis. Additive Synthesis Caveat. Music 270a: Modulation

Digital Filtering: Realization

cosω t Y AD 532 Analog Multiplier Board EE18.xx Fig. 1 Amplitude modulation of a sine wave message signal

RF/IF Terminology and Specs

ECE 6560 Multirate Signal Processing Chapter 13

ece 429/529 digital signal processing robin n. strickland ece dept, university of arizona ECE 429/529 RNS

Concordia University. Discrete-Time Signal Processing. Lab Manual (ELEC442) Dr. Wei-Ping Zhu

ECE 5655/4655 Laboratory Problems

SAMPLING THEORY. Representing continuous signals with discrete numbers

ME scope Application Note 01 The FFT, Leakage, and Windowing

CS3291: Digital Signal Processing

4- Single Side Band (SSB)

EEM478-WEEK8 Finite Impulse Response (FIR) Filters

CHAPTER 2 FIR ARCHITECTURE FOR THE FILTER BANK OF SPEECH PROCESSOR

Easy SDR Experimentation with GNU Radio

Spectrum Analysis - Elektronikpraktikum

DIGITAL FILTERS. !! Finite Impulse Response (FIR) !! Infinite Impulse Response (IIR) !! Background. !! Matlab functions AGC DSP AGC DSP

EE 470 Signals and Systems

The Fast Fourier Transform

List and Description of MATLAB Script Files. add_2(n1,n2,b), n1 and n2 are data samples to be added with b bits of precision.

Music 270a: Modulation

DISCRETE FOURIER TRANSFORM AND FILTER DESIGN

EECS 452 Midterm Exam (solns) Fall 2012

Linear Frequency Modulation (FM) Chirp Signal. Chirp Signal cont. CMPT 468: Lecture 7 Frequency Modulation (FM) Synthesis

Initial ARGUS Measurement Results

THE CITADEL THE MILITARY COLLEGE OF SOUTH CAROLINA. Department of Electrical and Computer Engineering. ELEC 423 Digital Signal Processing

Charan Langton, Editor

CMPT 468: Frequency Modulation (FM) Synthesis

Filter Banks I. Prof. Dr. Gerald Schuller. Fraunhofer IDMT & Ilmenau University of Technology Ilmenau, Germany. Fraunhofer IDMT

ECEn 487 Digital Signal Processing Laboratory. Lab 3 FFT-based Spectrum Analyzer

Software Defined Radio! Primer + Project! Gordie Neff, N9FF! Columbia Amateur Radio Club! March 2016!

SOFTWARE DEFINED RADIO IMPLEMENTATION IN 3GPP SYSTEMS

EE123 Digital Signal Processing

Enhanced Learning Combining MATLAB Simulation with Telecommunication Instructional Modeling (TIMS ) in a Senior Level Communication Systems Course

EECS 307: Lab Handout 2 (FALL 2012)

The Fundamentals of Mixed Signal Testing

Sampling, interpolation and decimation issues

CHAPTER 13 TRANSMITTERS AND RECEIVERS

F I R Filter (Finite Impulse Response)

Chapter 6 Passband Data Transmission

SIGMA-DELTA CONVERTER

Master Degree in Electronic Engineering

ELT Receiver Architectures and Signal Processing Fall Mandatory homework exercises

PROBLEM SET 6. Note: This version is preliminary in that it does not yet have instructions for uploading the MATLAB problems.

Phase Correction System Using Delay, Phase Invert and an All-pass Filter

Signal segmentation and waveform characterization. Biosignal processing, S Autumn 2012

Lab 3 FFT based Spectrum Analyzer

PLC2 FPGA Days Software Defined Radio

Signal processing preliminaries

Interpolated Lowpass FIR Filters

Validation & Analysis of Complex Serial Bus Link Models

Discrete-Time Signal Processing (DTSP) v14

Transcription:

The 29 th Annual ARRL and TAPR Digital Communications Conference DSP Short Course Session 4: Tricks of the DSP trade Rick Muething, KN6KB/AAA9WK

Recap We ve surveyed the roots of DSP and some of the tools we ll need to work with DSP. Some of the more useful DSP components have been defined. We ve looked at some examples of combining these in a DSP processing diagram to do something useful! This final session with cover a few of the finer points of DSP and some of the DSP tricks of the trade that make solutions practical.

Session 4 Overview DFT leakage and Windowing Bin interpolation for better Frequency Resolution I Q sampling and how to obtain it Hilbert Transform Single Tone Detection/Single bin DFT Sample Rate Conversion Decimation and Interpolation Envelope approximation Sliding DFT FM Detection Your next Steps in DSP!

DFT Leakage and Windowing When the frequency components of the input signal don t Lie exactly on the center of the DFT frequency bin we get An approximation of the true spectra because of a mechanism we call bin leakage DFT Magnitude DFT Magnitude Resulting DFT when Input Frequency = the center of a frequency bin Freq bin Freq bin Resulting DFT when Input Frequency is NOT in the center of a frequency bin

DFT Leakage and Windowing We can t eliminate leakage but we can minimize the effects of leakage Using a technique called windowing We window (scale) the input sequence with a function that reduces the magnitude of the samples near the beginning and end of the sample sequence. e.g. Hamming Window =.54 -.46(Cos(2*Pi*n/(N-1))) DFT Magnitude DFT Magnitude Without Windowing Freq bin With Windowing Freq bin

DFT Leakage and Windowing But windowing is a tradeoff (remember the NFL theorem?). Windowing will reduce the magnitude of the side lobe leakage but it also spreads the main lobe (worsens frequency resolution) Depending on how the DFT output is used may require different window functions or no windowing at all. One of the best ways to get a feel for DFT Windowing is to use the Scope DSP utility, apply different window functions to the same waveform and observe the resulting spectrum. http://en.wikipedia.org/wiki/spectral_leakage

Bin interpolation for better Frequency Resolution What if we need better frequency resolution than the DFT Frequency bins? We know the DFT bins are spaced at 1/(total sample time) e.g. Sample rate of 8000, 1024Point DFT yields bin spacing of 7.8125 Hz Our Max bin = 6 so we estimate our frequency As 6 x 7.8125 or 46.87 Hz 10 8 6 4 2 But if we interpolate with the two adjacent bins: Bin Interp = 5*6 + 6*10 + 7*8 /(6 + 10 + 8) = 6.08 or 47.53 Hz Some interpolation algorithms yield good Accuracy of.1 bin or better! 2 3 4 5 6 7 8 9 10 Freq bin Bin interpolation is a very effective tool when we can t increase the sample time

I Q Sampling the Holy Grail of DSP We ve touched on it but what is I Q sampling? I stands for In Phase and Q stands for Quadrature We augment the common real samples with samples 90 degrees delayed ( imaginary samples ). This allows computing many useful functions in DSP. (balanced mixers, envelope detectors etc) Q Each sample Is an I, Q pair All samples are real numbers Q=3 I I=5 Real samples only I and Q samples (real, imaginary)

How do we get I Q Samples? Here are two common methods Direct IQ sampling using sample points 90degrees out of phase. (Might be a good fit for stereo sound cards) Generation from real only samples using a Hilbert Transform. Implemented like a FIR filter but with specific Hilbert Transform coefficients. http://en.wikipedia.org/wiki/hilbert_transform Isamples Here again is our Familiar FIR filter Structure Qsamples (delayed)

Single Tone detection, Single bin DFT The Goertzel algorithm can implement a single bin DFT or single bin Tone detector using a 2 nd order IIR structure. http://en.wikipedia.org/wiki/goertzel_algorithm more computationally efficient than the DFT if the number of bins (tones) is limited. N does NOT have to be a power of two! can calculate fractional bin # s (e.g. bin 31.22) Can be computed as received (no large arrays) E.g. Actual execution time: DFT/Goertzel = 3.3 Log 2 (N) This was the trick used in the RTTY decoder: N= 1055 (allowed fitting symbol size with sample rate) allows placing bins for optimal orthogonal detection

Sample Rate Conversion Needed when streams of different sample rates must be combined or processed (e.g. As in Virtual Audio Cables) Can reduce processing demands To decrease the rate use Decimation F new = F old /D To Increase the rate use Interpolation F new = F old * M Can use combination to translate to any M/D value Often the rate conversion must use a FIR low pass or Cascaded Integrator-Comb IIR filters http://en.wikipedia.org/wiki/sample_rate_conversion

Envelope Approximation We often need the envelope of the waveform. (Recall our example of the DSP Crystal Radio) The envelope of a sample waveform is : Env(i) = Sqrt( I(i)^2 + Q(i)^2) This can be a heavy computational load at times. There are a number of approximations that come close to the above Envelope at much lower computational loads. Often these are adequate For envelope detection: E.g. (simple absolute value approximation uses no multiplies or square root) I(i) Q(i) Absolute Value Absolute Value + IIR Low Pass Filter ~Env(i) Isn t this similar to what our cat s whisker diode and cap did in our Crystal Radio?

The Sliding DFT The Sliding DFT is useful when we require a new DFT output spectrum every sample or few samples. Computationally lower cost than the DFT or the Goertzel Uses an IIR structure so we must insure it is long term stable! (R must be close to but < 1 e.g..9999) x(n) + Z -N + Re j2pim/n Z -1 X m (n) Out -R N COMB section One or more complex resonator sections (One for each output bin)

FM Detection FM detection involves getting the instantaneous frequency. We note that Frequency is rate of change (derivative) of Phase I(n) Arc Tangent Tan -1 (q(n)/i(n)) O(n) Differentiator FM Detection Out Q(n) Mathematically straightforward but computationally demanding - (After some calculus identities and simplification) Simplified process without Arc Tangent I(n) Q(n) Z -1 Z -1 Z -1 Z -1 - + + - + + Q (n) I (n) + - + FM Detection Out

DFT Short Course Summary We ve packed a lot into a 4 session introduction! Session 1 covered the basics of DSP and the important pioneers and basic algorithms Session 2 looked at tools and the most common types of filter building blocks Session 3 introduced other DSP components and how we tie them together to perform some useful task Session 4 looked in more depth at the concepts of bin leakage and I Q sampling and some of the more common tricks of the DSP trade The next step is yours to practice and build some basic applications to improve your understanding and skills.

What s YOUR next step on the DSP Road? Some Suggestions: Get a good DSP reference (Lyons gets my vote!) Write some simple programs to generate Simple waveforms. Use the Scope DSP utility to view the waveforms in time, Frequency and phase. Use Scope DSP to window your waveform and observe the affects of the various windows. Design a simple IIR or FIR filter using the Scope filter tools Try and implement some simple but useful sound card application

DSP Short Course Thank you for your interest and attention Dig into more of the details of DSP on your own Follow the words in the very first book on DSP Genesis 1:28