logo资料库

Software_Defined_Radio_using_MATLAB_Simulink_and_the_RTL-SDR.pdf

第1页 / 共674页
第2页 / 共674页
第3页 / 共674页
第4页 / 共674页
第5页 / 共674页
第6页 / 共674页
第7页 / 共674页
第8页 / 共674页
资料共674页,剩余部分请下载后查看
Book and Support File Information
Software, Simulation Examples and Design Exercises Licence Agreement
Table of Contents
Software Defined Radio Simulation Examples & Design Exercises
Foreword
A Few SDR Thoughts
Preface
Acknowledgements
1 Introduction
1.1 Real Time Desktop Software Defined Radio
1.2 What is the RTL-SDR?
1.3 What Do I Need to Get Started?
1.4 The Aim and Objectives of this Book
1.5 The Evolution of the Software Defined Radio Architecture
1.6 RTL-SDR Hardware
1.7 Interfacing with the RTL-SDR from MATLAB and Simulink
1.8 Practicalities and Some Challenges of (Low Cost) Desktop SDR
1.9 Working with Discrete and Continuous Time Signals and Equations
1.10 The Structure of the Book and Format of the Exercises
2 Open the Box! First SDR with MATLAB and Simulink
2.1 Getting Started: Hardware and Software Checklist
2.2 Getting Started: Installing the RTL-SDR Hardware Support Package
2.3 Getting Started: Book Support Files and the MATLAB Environment
2.4 Running the First Desktop RTL-SDR Receiver Designs
2.5 Summary
3 Radio Frequency Spectrum Viewing
3.1 Different Signals, Different Frequencies
3.2 Spectrum Usage and Allocations Around the Globe
3.3 Working with a Suitable Antenna
3.4 Go Forth and Explore the Spectrum!
3.5 Spectral Viewing — Spectrum Analyser and Waterfall Plots
3.6 Spectral Viewing — RTL-SDR Tuner GUI Controls
3.7 Engineering Requirements — Eyeball Radio Tuning & More
3.8 FM Radio Stations
3.9 Mobile (Cell) Phone Signals—2G, 3G and 4G
3.10 433MHz: Key Fobs and Wireless Sensors
3.11 Digital Video & Audio Signals
3.12 Using Multiple RTL-SDRs
3.13 Sweeping the Spectrum: Receiving from 25MHz to 1.75GHz
3.14 Summary
4 Getting Started with MATLAB and Simulink
4.1 Introducing MATLAB
4.2 MATLAB Functions
4.3 Plotting in MATLAB
4.4 MATLAB Arrays, Matrices, and Structures
4.5 MATLAB System Objects
4.6 Introducing Simulink
4.7 Creating Simulink Models
4.8 Variables and Parameters
4.9 Generating Frequency Domain Plots
4.10 Sampling Rates, Samples and Frames
4.11 Data Types
4.12 Working with Input and Output Files
4.13 Saving and Re-importing RTL-SDR Data
4.14 Summary
5 Complex Signals, Spectra and Quadrature Modulation
5.1 Real and Complex Signals — it’s all Sines and Cosines
5.2 Viewing Real Signals in the Frequency Domain via Complex Spectra
5.3 Standard Amplitude Modulation
5.4 Quadrature Modulation and Demodulation (QAM)
5.5 Quadrature Amplitude Modulation using Complex Notation
5.6 Quadrature Amplitude Demodulation using Complex Notation
5.7 Spectral Representation for Complex Demodulation
5.8 Frequency Offset Error and Correction at the Receiver
5.9 Frequency Correction using a Complex Exponential
5.10 RTL-SDR Quadrature / Complex Architecture
5.11 Summary
6 Amplitude Modulation (AM) Theory and Simulation
6.1 Amplitude Modulation — An Introduction
6.2 AM-DSB-SC: Double Sideband Suppressed Carrier AM
6.3 AM-DSB-TC: Double Sideband Transmitted Carrier AM
6.4 AM-SSB: Single Sideband AM
6.5 AM-VSB: Vestigial Sideband AM
6.6 Theoretical AM Demodulation
6.7 Receiving and Downconverting AM-DSB-TC Signals to Complex Baseband
6.8 Non-Coherent AM Demodulation: The Envelope Detector
6.9 Summary
7 Frequency Tuning and Simple Synchronisation
7.1 Selecting a Frequency Band: Tuning
7.2 The Synchronisation Problem
7.3 Demodulation of AM Signals
7.4 Coherent Demodulation and Carrier Synchrony
7.5 Introduction to Phase Locked Loops
7.6 Discrete Time PLL Model
7.7 PLL Behaviours, Parameters and Characteristics
7.8 PLL Design
7.9 PLL Performance in Noise
7.10 Carrier Synchronisation
7.11 Summary
8 Desktop AM Transmission and Reception
8.1 Transmitting AM Signals with a USRP® Radio
8.2 Implementing Non-Coherent AM Receivers with the RTL-SDR
8.3 Implementing Coherent AM Receivers with the RTL-SDR
8.4 Audio Multiplexing with the USRP® and RTL-SDR Hardware
8.5 Alternative Hardware for Generating Desktop AM Signals
8.6 Summary
9 Frequency Modulation (FM) Theory and Simulation
9.1 The History of the FM Standard
9.2 The Mathematics of FM & the Modulation Index
9.3 FM Signal Bandwidth
9.4 FM Demodulation Using Differentiation
9.5 Receiving and Downconverting FM Signals to Complex Baseband
9.6 Non-Coherent FM Demodulation: The Complex Differentiation Discriminator
9.7 Non-Coherent FM Demodulation: The Complex Delay Line Discriminator
9.8 Coherent FM Demodulation: The Phase Locked Loop
9.9 Demodulating Signals from Commercial FM Radio Stations
9.10 Summary
10 Desktop FM Transmission and Reception
10.1 Transmitting Mono WFM Signals with the USRP® Hardware
10.2 Implementing Mono FM Receivers with RTL-SDR and Simulink
10.3 Transmitting Stereo WFM Signals with the USRP® Hardware
10.4 Implementing Stereo FM Receivers with RTL-SDR and Simulink
10.5 Manipulating the MPX: Transmitting AM Signals with FM Transmitters
10.6 Manipulating the MPX: Audio Multiplexing with FM Transmitters
10.7 Alternative Hardware for Generating Desktop FM Signals
10.8 Summary
11 Digital Communications Theory and Simulation
11.1 Digital Modulation Schemes
11.2 Pulse Shaping
11.3 Digital Up and Downconversion
11.4 Carrier Synchronisation
11.5 Timing Errors and Symbol Recovery
11.6 Symbol Timing Synchronisation
11.7 Digital Receiver Design: Joint Carrier and Timing Synchronisation
11.8 Coarse Frequency Synchronisation
11.9 Phase Ambiguity
11.10 Differential Encoding and Decoding
11.11 Synchronisation with a Unique Word
11.12 Summary
12 Desktop Digital Communications: QPSK Transmission and Reception
12.1 Pulse Shaping with Real Time QPSK Transmitter and Receiver Designs
12.2 Coarse Frequency Synchronisation in a Real-time System
12.3 Carrier and Timing Synchronisation with the RTL-SDR
12.4 Developing a Simple Communications Protocol
12.5 ASCII Encoding and Decoding
12.6 Data and Frame Synchronisation
12.7 ASCII Message Transmission and Reception
12.8 Transmitting Images Across the Desktop
12.9 Transmitting Data Using FM Transmitters
12.10 Summary
Appendices and Postscript
Appendix A: Hardware Setup
A.1 The RTL-SDR Hardware Support Package
A.2 The USRP® Hardware Support Package
A.3 RTL-SDR Frequency Error Correction
Appendix B: Common Equations
Appendix C: Digital Filtering and Multirate
C.1 Filter Classes and Characteristics
C.2 Filter Specification and Design
C.3 FIR Filter Processing Architecture
C.4 Computation and Trade-offs
C.5 Multirate Filtering: The Motivation
C.6 Decimation
C.7 Interpolation
Appendix D: PLL Design
D.1 Digital Type 2 PLL Linear Model and Z-Domain Transfer Function
D.2 Analogue Type 2 PLL Linear Model and S-Domain Transfer Function
D.3 Extraction of Digital PLL Parameters Based on Analogue PLL Equivalence
D.4 Phase Detector Gain
D.5 Oscillator Gain
Appendix E: AM and FM Transmitters
E.1 Upconverting AM Radio Signals with the Ham It Up
E.2 Building an ‘RT4’ 433.9MHz AM Transmitter
E.3 Using the Raspberry Pi as an FM Transmitter
References
List of Acronyms
Index
u s i n g MATLAB & Simulink RTL-SDRand the Bob Stewart Kenneth Barlee Dale Atkinson Louise Crockett desktop SDR .com
Software Defined Radio using MATLAB® & Simulink® and the RTL-SDR
Software Defined Radio using MATLAB® & Simulink® and the RTL-SDR Robert W. Stewart Kenneth W. Barlee Dale S. W. Atkinson Louise H. Crockett Department of Electronic and Electrical Engineering University of Strathclyde Glasgow, Scotland, UK 1st Edition (revised)
First published September 2015 by Strathclyde Academic Media. This revised edition published February 2017. Version 1.17.0208. Copyright © Robert W. Stewart, Kenneth W. Barlee, Dale S. W. Atkinson, and Louise H. Crockett. Book PDF and Paper Materials Licence to Use and Reproduce for Teaching, Learning and Academic Purposes This book is available for free as an electronic book (PDF format). (A printed version is available for purchase from Amazon and other retailers and from www.desktopSDR.com.) Text and diagrams from this book may be reproduced, partially or in their entirety and used in a manner consistent with applicable law. A clear reference to the original source must be made in all documents using text or diagrams from the book. The reference should be of the following form: R. W. Stewart, K. W. Barlee, D. S. W. Atkinson, and L. H. Crockett, Software Defined Radio using MATLAB & Simulink and the RTL-SDR, Published by Strathclyde Academic Media, 2015 (Softback ISBN 9780992978716, Hardback ISBN 9780992978723). Requests to use content from this book for purposes other than non-profit academic use should be directed to: info@desktopSDR.com. This book may not be reproduced in paper, PDF or other readable form and may not be sold or re-sold by any unauthorised third party. Example Files and Software Simulation examples, design exercises and files and associated software MATLAB and Simulink resources that accompany this book are available as a download from the book’s companion website: www.desktopSDR.com or may be variously acquired by other means such as via USB storage, cloud storage, disk or any other electronic or optical or magnetic storage mechanism. These files and associated software may be used subject to the terms of the software license agreement which is reproduced on page ii, and referenced in each MATLAB and Simulink file. For information, the files and associated software may be updated from time to time in order to address bugs, provide updates, or for version compatibility reasons. These updates will be made available from the book’s companion website: www.desktopSDR.com. Music, Vocal, Audio and Modulated Audio Files The music and vocal files used within the Examples files and software within the book were variously written, arranged, performed, recorded and produced by Garrey Rice, Adam Struth, Jamie Struth, Iain Thistlethwaite and also Marshall Craigmyle who collectively, and individually where appropriate, assert and retain all of their copyright, performance and artistic rights. Permission to use and reproduce this music is granted for all purposes associated with MATLAB and Simulink software and the simulation examples and design exercises files that accompany this book. Requests to use the music for any other purpose should be directed to: info@desktopSDR.com. For information on music track names, full credits, and links to the musicians please refer to www.desktopSDR.com/more/audio. Proper Use of the Radio Frequency (RF) Spectrum Some simulation examples and design exercises in this book describe the use of hardware capable of radio frequency (RF) signal trans- mission and reception. Use of the RF spectrum is subject to regulations and restrictions that vary by country and geographical region. In all countries persons may only transmit on bands for which they have the appropriate licence or permission, or bands which are designated for access on an unlicensed or perhaps lightly licensed basis. RF transmissions must also meet all conditions of the use of that frequency band. Please refer to your local Government or other appropriate spectrum regulator for further information on RF reception and transmission in your country. In addition to restrictions on transmission, receiving and /or recording and/or attempting to decode certain types of RF signal may be restricted or illegal in some countries. It is the responsibility of the individual to comply with all spectrum access regulations and information laws that apply in their region or country and every effort should be made to confirm legal transmission and reception in any RF band. Warning and Disclaimer The material included is provided on an ‘as is’ basis in the best of faith, and with the best of educational intentions. Neither the authors nor publishers make any warranty of any kind, expressed or implied, with regard to the documentation or other content contained in this book. The authors and publisher shall not be held liable for any loss or damage resulting directly or indirectly from any information contained herein; neither shall the authors and publisher be held responsible for the non-compliance of any readers with their local RF spectrum access regulations or information laws. Trademarks MATLAB and Simulink are registered trademarks of MathWorks, Inc. in the United States and other countries. Microsoft and Windows are registered trademarks of Microsoft Corporation in the United States and other countries. Apple and OS X are registered trademarks of Apple Inc. in the United States and other countries. Linux is the registered trademark of Linus Torvalds in the United States. and other countries. Raspberry Pi is a trademark of the Raspberry Pi Foundation in the United Kingdom and other countries. USRP, USRP2, UHD, and Ettus Research are trademarks of National Instruments Corp. All other trademarks used in this book are acknowledged as belonging to their respective companies. The use of trademarks in this book does not imply any affiliation with, or endorsement of, this book by trademark owners.
Book and Support File Information i Obtaining a Printed Copy of this Book If you are reading the PDF version of this book and wish to obtain a printed copy, you can buy one from amazon.com. Details about other distributors are provided at: www.desktopSDR.com/print_version desktop SDR .com Support File Download Information A set of files accompany this book. These files provide the Simulink models, MATLAB scripts and data files that you require to work through the examples in this book. They have been compressed into a ZIP folder, which is around 1.5GB in size. It can be downloaded either from the book’s accompanying website or directly from the MathWorks site, along with a PDF of this book. Links for the two are as follows: www.desktopSDR.com www.mathworks.com/SDR You can also sign up to a mailing list on our website to keep up to date with the book and tutorials. Errata Any items of errata arising will be published at: www.desktopSDR.com i
ii Software, Simulation Examples and Design Exercises Licence Agreement This licence agreement refers to the simulation examples, design exercises and files, and associated software MATLAB and Simulink resources that accompany the book: Software Defined Radio using MATLAB & Simulink and the RTL-SDR First published by Strathclyde Academic Media, 2015. This revised edition published 2017 Authored by Robert W. Stewart, Kenneth W. Barlee, Dale S.W. Atkinson, and Louise H. Crockett and made available as a download from, www.desktopSDR.com or variously acquired by other means such as via USB storage, cloud storage, disk or any other electronic or optical or magnetic storage mechanism. These files and associated software may be used subject to the terms of agreement of the conditions below: Copyright © 2015-2017 Robert W. Stewart, Kenneth W. Barlee, Dale S.W. Atkinson, and Louise H. Crockett All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. 2. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. In all cases, the software is, and all modifications and derivatives of the software shall be, licensed to you solely for use in conjunction with The MathWorks, Inc. products and service offerings. 4. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ii
分享到:
收藏