Home

Lab 1 - eBooks

image

Contents

1. 13 Chapter 2 2 7 Bibliography 1 National Instruments LabVIEW Getting Started with LabVIEW Part Number 323427A 01 2003 2 National Instruments LabVIEW User Manual Part Number 320999E 01 2003 3 National Instruments LabVIEW Performance and Memory Management Part Number 342078A 01 2003 4 National Instruments Introduction to LabVIEW Six Hour Course Part Num ber 323669B 01 2003 5 Robert H Bishop Learning With Labview 7 Express Prentice Hall 2003 14 Lab 1 Getting Familiar with LabVIEW Part I The objective of this first lab is to provide an initial hands on experience in building a VI For detailed explanations of the LabVIEW features mentioned here the reader is referred to 1 LabVIEW7 1 can get launched by double clicking on the LabVIEW 7 1 icon The dialog window shown in Figure 2 15 should appear Figure 2 15 Starting LabVIEW L1 1 Building a Simple VI To become familiar with the LabVIEW programming environment it is more effec tive if one goes through a simple example The example presented here consists of calculating the sum and average of two input values This example is described in a step by step fashion below L1 1 1 VI Creation To create a new VI click on the arrow next to New and choose Blank VI from the pull down menu This step can also be done by choosing File New VI from the menu As a result a blank FP and a blank BD window appear as shown in Figure 2 16
2. It should be remembered that an FP and a BD coexist when building a VI 15 Lab 1 gt Untitled 1 Block Diagram Figure 2 16 Blank VI Clearly the number of inputs and outputs to a VI is dependent on its function In this example two inputs and two outputs are needed one output generating the sum and the other the average of two input values The inputs are created by locat ing two Numeric Controls on the FP This is done by right clicking on an open area of the FP to bring up the Controls palette followed by choosing Controls Numeric Controls Numeric Control Each numeric control automatically places a corresponding terminal icon on the BD Double clicking on a numeric control highlights its counterpart on the BD and vice versa Next let us label the two inputs as x and y This is achieved by using the Labeling tool from the Tools palette which can be displayed by choosing Window Show Tools Palette from the menu bar Choose the Labeling tool and click on the default labels Numeric and Numeric 2 in order to edit them Alternatively if the automatic tool selection mode is enabled by clicking Automatic Too Selection in the Tools palette the labels can be edited by simply double clicking on the default labels Editing a label on the FP changes its corresponding terminal icon label on the BD and vice versa Similarly the outputs are created by locating two Numeric Indicators Controls Numeric Indicators Nu
3. Library of Congress Cataloging in Publication Data Application submitted British Library Cataloguing in Publication Data A catalogue record for this book is available from the British Library ISBN 0 7506 7914 X For information on all Newnes publications visit our Web site at www books elsevier com 05 06 07 08 09 10 10987654321 Printed in the United States of America Working together to grow libraries in developing countries www elsevier com www bookaid org www sabre org ELSEVIER BOOKAID Sabre Foundation International Contents POP ACE T PP XA What s on the CD ROM cms EEA E AAEE EEA O d Chapter I Introduction EESEESNESBSEEUESERNSEBESEHSNEBESEBESSBEESNEENBEESNESEEEBSESENEUNDBESNESERSERESBESEER 1 1 1 Digital Signal Processing Hands On Lab Courses 1 2 Organization eres 1 3 Software Installation Tub Updates aoo aeiee aaa ee SEEE esatta iot une anat NS D eds tue 1 5 Bibliography senri titia aua MP b RN Un aed Du eu cnius i Chapter 2 LabVIEW Programming Environment 2 eene enun D 2 1 Virtual Instruments CV Ie ao ebrii REL TOT NENRPORU UR c Coh toe A E RR m 2 2 Graphical Environment NP ESTEEN E EEEN TUR ad 2 3 Building a Front Panel nane VERO ORAE ATU RENTA RO A co RU epe depu cleri 2 4 Building a Block Diagram 5 oneisecther laete eio tee BERSRRE De Pp eeb te pod Lo eaoodao Eanes 10 2 5 Grouping Data A
4. similar to the struc ture data type in text based programming languages Clusters allow one to reduce the number of wires on a BD by bundling different data type elements together and passing them to only one terminal An individual element can be added to or extracted from a cluster by using the cluster functions such as Bundle by Name and Unbundle by Name 2 6 Debugging and Profiling Vis 2 6 1 Probe Tool The Probe tool is used for debugging VIs as they run The value on a wire can be checked while a VI is running Note that the Probe tool can only be accessed in a BD window The Probe tool can be used together with breakpoints and execution highlighting to identify the source of an incorrect or an unexpected outcome A breakpoint is used to pause the execution of a VI at a specific location while execution highlighting helps one to visualize the flow of data during program execution 2 6 2 Profile Tool The Profile tool can be used to gather timing and memory usage information in other words how long a VI takes to run and how much memory it consumes It is necessary to make sure a VI is stopped before setting up a Profile window An effective way to become familiar with LabVIEW programming is by going through examples Thus in the two labs that follow in this chapter most of the key programming features of LabVIEW are presented by building some simple VIs More detailed information on LabVIEW programming can be found in 1 5
5. Lab05 Lab06 LabO7 Lab08 Lab09 Lab10 Lab11 Lab12 Getting familiar with LabVIEW Part I Getting familiar with LabVIEW Part II Sampling Quantization and Reconstruction FIR IIR Filtering System Design Data Type and Scaling Adaptive Filtering Systems FFT STFT and DWT Getting Familiar with Code Composer Studio DSP Integration Examples Building Dual Tone Multi Frequency System in LabVIEW Building 4 QAM Modem System in LabVIEW Building MP3 Player System in LabVIEW To run the lab files the National Instruments LabVIEW 7 1 is required and assumed installed The lab files need to be copied into the folder C Lab VIEW Labs xi What s on the CD ROM LabVIEW Labs e For Lab 8 and Lab 9 the Texas Instruments Code Composer Studio 2 2 CCStudio is required and assumed installed in the folder C ti The subfolders correspond to the following DSP platforms o DSK 6416 o DSK 6713 o Simulator configured as DSK6713 as shown below import Configuration C6713 Device Functional Simulator Big Endian C6713 Device Funchonal Simuator Little Encian C671x XDS510 Emulator C671x XDS560 Emulator CB7xx CPU Cycle Accurate Simulator Big Endian CB7xx CPU Cycle Accurate Simulator Little Endian DM642 Device Cycle Accurate Simulator Big Endian wv ome o ce Fiters Famy Platlorm Endianness al X E X al Configuration Description Simulates the C6713 processor This i
6. Processing Based on the TMS320C6000 Elsevier 2005 2 S Kuo and W S Gan Digital Signal Processors Architectures Implementations and Applications Prentice Hall 2005 3 R Chassaing DSP Applications Using C and the TMS320C6x DSK Wiley Inter Science 2002 CHAPTER LabVIEW Programming Environment LabVIEW constitutes a graphical programming environment that allows one to design and analyze a DSP system in a shorter time as compared to text based pro gramming environments LabVIEW graphical programs are called virtual instruments VIs VIs run based on the concept of data flow programming This means that execution of a block or a graphical component is dependent on the flow of data or more specifically a block executes when data is made available at all of its inputs Output data of the block are then sent to all other connected blocks Data flow pro gramming allows multiple operations to be performed in parallel since its execution is determined by the flow of data and not by sequential lines of code 2 1 Virtual Instruments Vis A VI consists of two major components a front panel FP and a block diagram BD An FP provides the user interface of a program while a BD incorporates its graphical code When a VI is located within the block diagram of another VI it is called a subVI LabVIEW VIs are modular meaning that any VI or subVI can be run by itself 2 1 1 Front Panel and Block Diagram An FP contains the user
7. clicking on its Express VI Basic operations such as addition or subtraction are represented by functions Figure 2 8 shows three examples corresponding to three types of a BD object VI Express VI and function E LL D Simulate Signal Figure 2 8 Block Diagram objects a VI b Express VI and c function Both subVI and Express VI can be displayed as icons or expandable nodes If a subVI is displayed as an expandable node the background appears yellow Icons are used to save space in a BD while expandable nodes are used to provide easier wiring or better readability Expandable nodes can be resized to show their connection nodes more clearly Three appearances of a VI Express VI are shown in Figure 2 9 VI Express VI Icon Expandable node Expandable node ison Expandable node Expandable node Default ES T Resized Default Resized I f r M Vu L S Simulate Signal error in no error E rs error o M Sine Figure 2 9 Icon versus expandable node 10 LabVIEW Programming Environment 2 4 2 Terminal Icons FP objects are displayed as terminal icons in a BD A terminal icon exhibits an input or output as well as its data type Figure 2 10 shows two terminal icon examples consisting of a double precision numerical control and indicator As shown in this figure terminal icons can be displayed as data type terminal icons to conserve space in a BD Control Indicator Data Type Te
8. co aol aga 242 L113 Bibliographiy iipeses chen ees oreet tete oa osa Pe ietevetplsp ex pei i on p en Rosi orina 252 Chapter 12 DSP System Design MP3 Player eo renun LOD 12 1 Synchronization Block eet xem tiadeito vede Deui ise ea i E NEUE 254 12 2 Scale Factor Decoding Block 256 12 3 Huffman Decoder 12 4 Requantizer 12 6 Alias Reduction atakcdamicacsnide ci o NR a DINE D e dug datus HR ANI RO 261 12 7 IMDCT and Windowing T Veiis sanbcodue aie LOL 12 8 Polyphase Filter Banb eo pot h e pr mirata les ies re ti teen 40d 12 9 Bibliography ninenin dae cede sten ud ois e OO Lab 12 Implementation of MP3 Player in LabVIEW 267 L12 1 System Level VI dntdo su LC aA EDO EN URS Fa Ret 267 L12 2 LabVIEW Implementation eene anita ORB TOR DH TROU 268 L12 3 Modifications to Achieve Real Time Decoding us ABI L12 4 Bibliography Index BEENEEHREEEESSESGRSEHEEHSESEBESBRNEREERBEESENRESESESERESENBBNEENESEBHEEHSEEEREENENEESURESESORENEENEUSEESEUBESMENM 28 7 Preface For many years I have been teaching DSP Digital Signal Processing lab courses using various TI Texas Instruments DSP platforms One question I have been get ting from students in a consistent way is Do we have to know C to take DSP lab courses Until last year my response was Yes C is a prerequisi
9. software defined radio and iii MP3 player 1 3 Software Installation LabVIEW 7 1 which is the latest version at the time of this writing is installed by running setup exe on the LabVIEW 7 1 Installation CD Some lab portions use the LabVIEW toolkits Digital Filter Design Advanced Signal Processing and DSP Chapter 1 Test Integration for TI DSP Each of these toolkits can be installed by running setup exe located on the corresponding toolset CD If one desires to run parts of a LabVIEW designed system on a DSP processor then it is necessary to install the Code Composer Studio software tool This is done by run ning setup exe on the CCStudio CD The most updated version of CCStudio at the time of this writing CCStudio 2 2 is used in the DSK related labs The accompanying CD includes all the files necessary for running the labs covered throughout the book 1 4 Updates Considering that any programming environment goes through enhancements and updates it is expected that there will be updates of LabVIEW and its toolkits To accommodate for such updates and to make sure that the labs provided in the book can still be used in DSP lab courses any new version of the labs will be posted at the website http www utdallas edu kehtar LabVIEW for easy access It is recommend ed that this website be periodically checked to download any necessary updates 1 5 Bibliography 1 N Kehtarnavaz Real Time Digital Signal
10. tion scattered in several NI LabVIEW manuals to provide the necessary tools and know how for designing signal processing systems within a one semester structured course This book can also be used as a self study guide to design signal processing systems using LabVIEW In addition for those interested in DSP hardware implementation two chapters in the book are dedicated to executing selected portions of a LabVIEW designed system on an actual DSP processor The DSP processor chosen is TMS320C6000 This processor is manufactured by Texas Instruments TI for computationally intensive signal processing applications The DSP hardware utilized to interface with Introduction LabVIEW is the TI s C6416 or C6713 DSK DSP Starter Kit board It should be mentioned that since the DSP implementation aspect of the labs which includes C programs is independent of the LabVIEW implementation those who are not interested in the DSP implementation may skip these two chapters It is also worth pointing out that once the LabVIEW code generation utility becomes available any portion of a LabVIEW designed system can be executed on this DSP processor with out requiring any C programming 1 2 Organization The book includes twelve chapters and twelve labs After this introduction the LabVIEW programming environment is presented in Chapter 2 Lab 1 and Lab 2 in Chapter 2 provide a tutorial on getting familiar with the LabVIEW programming environment The t
11. Chapter 4 Digital Filtering co eere soos enhn anuo u naa na unu sssnsasssss 73 4 1 Digital Filtering 4 2 LabVIEW Digital Filter Design Toolkit 4 3 Bibliography s asocevieenuro agentis dente tO dnte retis rE EI vae ene ies M usi Qa bI edo EAE Lab 4 FIR IIR Filtering System Desigh o eere o eoru nau nuu uunass 79 L41 FIR Filtering System iiie o Robin rA ra ev a TAEA EE psa eaten 79 13 2 UR Filtering SyStetti ucessererteo tenia Ea NEAR aa Seeds 85 L4 3 Building a Filtering System Using Filter Coefficients dust uidit 90 L4 4 Filter Design Without Using DFD Toolkit EEEN m TERN OL L4 5 Bibliography TN NUR PEETI irit sia ideatiee PESA eee 94 Chapter 5 Fixed Point versus Floating Point e eene enean 95 5 1 Q format Number Representation eee Ud ug oo 5 2 Finite Word Length Effects v histamine 5 3 Floating Point Number Representation 5 4 Overflow and Scaling asse qe e aere teen fe teer Gps bonito 5 5 Data Types in LabVIEW una dicendo Faerdeesie Dee api ipeo neci M RED duque e eire 5 6 Bibliographg cstncn tait Ripe cii i ke i one ina Ea rs nb Von epe RE ipe R ERR Lab 5 Data Type and Scaling 12 42 oer orans annua nu auuasuauussssess 105 L5 L Handling Data types in LabVIEW etit rte roh ar be Ere kd edo ed 105 L5 2 Overflow Handling iiio qoo der roni entere ba uale tak
12. Digital Signal Processing o System Level Design sw Using LabVIEW NASSER KEHTARNAVAZ and NAMJIN KIM Digital Signal Processing System Level Design Using LabVIEW This Page Intentionally Left Blank Digital Signal Processing System Level Design Using LabVIEW by Nasser Kehtarnavaz and Namjin Kim University of Texas at Dallas AMSTERDAM BOSTON e HEIDELBERG e LONDON NEW YORK e OXFORD e PARIS e SAN DIEGO a SAN FRANCISCO e SINGAPORE e SYDNEY e TOKYO ELSEVIER Newnes is an imprint of Elsevier Newnes Newnes is an imprint of Elsevier 30 Corporate Drive Suite 400 Burlington MA 01803 USA Linacre House Jordan Hill Oxford OX2 8DP UK Copyright 2005 Elsevier Inc All rights reserved No part of this publication may be reproduced stored in a retrieval system or transmitted in any form or by any means electronic mechanical photocopying recording or otherwise without the prior written permission of the publisher Permissions may be sought directly from Elsevier s Science amp Technology Rights Department in Oxford UK phone 44 1865 843830 fax 44 1865 853333 e mail permissions elsevier com uk You may also complete your request on line via the Elsevier homepage http elsevier com by selecting Customer Support and then Obtaining Permissions e9 Recognizing the importance of preserving what has been written Elsevier prints its books on acid free paper whenever possible
13. Express Numeric Divide on the BD The divisor in our case 2 needs to be entered in a Numeric Constant Functions Arithmetic amp Comparison Express Numeric gt Numeric Constant and connected to the y terminal of the Divide function using the Wiring tool To have a proper data flow functions structures and terminal icons on a BD need to be wired The Wiring tool is used for this purpose To wire these objects point the Wiring tool at a terminal of a function or a subVI to be wired left click on the termi nal drag the mouse to a destination terminal and left click once again Figure 2 19 illustrates the wires placed between the terminals of the numeric controls and the input terminals of the add function Notice that the label of a terminal is displayed whenever the cursor is moved over it if the automatic tool selection mode is enabled Also note that the Run button 9 on the toolbar remains broken until the wiring process is completed Untitled 1 Block Diagram File Edt Operate Browse Window Help r Tools Figure 2 19 Wiring BD objects For better readability of a BD wires which are hidden behind objects or crossed over other wires can be cleaned up by right clicking on them and choosing Clean Up Wire from the shortcut menu Any broken wires can be cleared by pressing Ctrl B gt or Edit Remove Broken Wires The label of a BD object such as a function can be shown or hidden by right
14. at digital pro cessing allows programmability The same processor hardware can be used for many different applications by simply changing the code residing in memory Another reason is that digital circuits provide a more stable and tolerant output than ana log circuits for instance when subjected to temperature changes In addition the advantage of operating in the digital domain may be intrinsic For example a linear phase filter or a steep cutoff notch filter can easily be realized by using digital signal processing techniques and many adaptive systems are achievable in a practical prod uct only via digital manipulation of signals In essence digital representation zeroes and ones allows voice audio image and video data to be treated the same for error tolerant digital transmission and storage purposes Chapter 1 1 1 Digital Signal Processing Hands On Lab Courses Nearly all electrical engineering curricula include DSP courses DSP lab or design courses are also being offered at many universities concurrently or as follow ups to DSP theory courses These hands on lab courses have played a major role in student understanding of DSP concepts A number of textbooks such as 1 3 have been written to provide the teaching materials for DSP lab courses The programming language used in these textbooks consists of either C MATLAB or Assembly that is text based programming In addition to these programming skills it is becoming imp
15. clicking on the object and checking or unchecking Visible Items Label from the shortcut menu Also a terminal icon corresponding to a numeric control or indicator 18
16. e ipi eate ie ba Me aE 107 1 5 3 Scaling Appraachiueeitatie ose eic Ad essen geisha o URP ae b E Ha mines 111 L5 4 Digital Filtering in Fixed Point Format eene 113 1 5 5 Biblioptapbiy neo deris tete eet oat AQUIS BR ao RN aaa Eaa 127 Chapter 6 Adaptive Filtering eoe e reor eaae aan nauunnaeseses 123 6 1 System Identification 6 2 Noise Cancellation toit e i rar ep E Henne s etes oot te aisi Inr eei idein 6 3 Biblingraphy iieri eieiei ie anime dep Fl UU HE a E EEES S Lab 6 Adaptive Filtering Systems eere eere sean nnannnasuunseesess 127 L6 1 System Identification L6 2 Noise Cancellation Contents E63 Bibliogtapliyasssessttebed o atrii terd emt a edis em ea ea es 138 Chapter 7 Frequency Domain Processing ET 139 7 1 Discrete Fourier Transform DFT and Fast Fourier Transform FFT 139 1 2 Short Time Fourier Transform STFT esee eerte 140 7 3 Discrete Wavelet Transform DWT esee eene enteettee tnn ntennte tnn tetn 142 7 4 Signal Processing Toolset re aerea bee taion aeu Grp anten 144 Tf BibliGPraDhig us ccs oid iio tiae ere pn ran od aon moto e TR 145 Lab 7 FET STFT and DWT ieeeeoseenesozuziezusuruassF zu ssvur vassesaesexssusesza 147 LELEEI versus 5 DE Laden veo e riae T t tee teme t nee 147 DP OW seca sews chase oem eh Meo maa Sa aeons mes 152 1 53 Bibliographie tite tree ER t ep
17. ensi lid atti cd ce puts grouped in the Text Indicators Figure 2 5 Control palettes LabVIEW Programming Environment palette for text outputs and grouped in the Graph Indicators palette for graphical outputs These indicator options are displayed in Figure 2 6 E Numeric Indicators 123 we i Num Ind Progress Bar Grad Bar Progress Bar Grad Bar 1 1w0 2 A HB 1 y w 1 vj o 0 Meter Gauge Tank Thermometer Az LED ca Oo Square LED Round LED i Graph Indicators Y B m E Y Chart Graph XY Graph Figure 2 6 Indicator palettes 2 3 3 Align Distribute and Resize Objects The menu items on the toolbar of an FD see Figure 2 7 provide options to align and distribute objects on the FP in an orderly manner Normally after controls and indicators are placed on an FP one uses these options to tidy up their appearance Align Objects Distribute Objects Resize Objects Reorder Figure 2 7 Menu for align distribute resize and reorder objects Chapter 2 2 4 Building a Block Diagram 2 4 1 Express VI and Function Express VIs denote higher level VIs that have been configured to incorporate lower level VIs or functions These VIs are displayed as expandable nodes with a blue background Placing an Express VI in a BD brings up a configuration dialog window allowing adjustment of its parameters As a result Express VIs demand less wiring A configuration window can be brought up by double
18. es inputs controls and outputs indicators of a VI The number of inputs and outputs can be changed by using different connector pane patterns In Figure 2 1 a VI icon is shown at the top right corner of the BD and its corresponding connector pane having two inputs and one output is shown at the top right corner of the FP LabVIEW Programming Environment 2 2 Graphical Environment 2 2 1 Functions Palette The Functions palette see Figure 2 2 provides various function VIs or blocks for building a system This palette can be displayed by right clicking on an open area of a BD Note that this palette can only be displayed in a BD JA Funct Q search FA gj aw Input Analysis Output User Libraries gt gt gt gt 3 gt a s G Exec Ctrl Arth Compare Sig Manip All Functions Figure 2 2 Functions palette 2 2 2 Controls Palette The Controls palette see Figure 2 3 provides controls and indicators of an FP This palette can be displayed by right clicking on an open area of an FP Note that this palette can only be displayed in an FP FA Controls Q Search ms gt gt T te 4 AL Y si Num Ctris Buttons Text Ctris ser Ctris os P P f gt lt Q g Num Inds EDs Text Inds Graph Inds All Controls Figure 2 3 Controls palette 2 2 3 Tools Palette The Tools palette provides various operation modes of the mouse cursor for build ing or debugging a VI The Tools palette a
19. ing a value from outside of the loop to it The iteration terminal i denotes the number of completed iterations Figure 2 12 For Loop which always starts at zero 2 4 4 2 While Loop A While Loop structure allows repetitions depending on a condition see Figure 2 13 The conditional terminal amp initiates a stop if the condition is true Similar to a For Loop the iteration terminal i provides the number of completed iterations always starting at zero Figure 2 13 While Loop 2 4 4 3 Case Structure A Case structure see Figure 2 14 allows running different sets of operations depending on the value it receives through its selector terminal which is indicated by A In addition to Boolean type the input to a selector terminal can be of integer string or enumerated type This input determines which case to execute The case selector shows the status being Figure 2 14 Case structure executed Cases can be added or deleted as needed 2 5 Grouping Data Array and Cluster An array represents a group of elements having the same data type An array consists of data elements having a dimension up to 2 1 For example if a random number is generated in a loop it makes sense to build the output as an array since the length of the data element is fixed at 1 and the data type is not changed during iterations 12 LabVIEW Programming Environment A cluster consists of a collection of different data type elements
20. interfaces of a VI shown in a BD Inputs to a VI are rep resented by so called controls Knobs pushbuttons and dials are a few examples of controls Outputs from a VI are represented by so called indicators Graphs LEDs light indicators and meters are a few examples of indicators As a VI runs its FP provides a display or user interface of controls inputs and indicators outputs A BD contains terminal icons nodes wires and structures Terminal icons are interfaces through which data are exchanged between an FP and a BD Terminal icons Chapter 2 correspond to controls or indicators that appear on an FP Whenever a control or indi cator is placed on an FP a terminal icon gets added to the corresponding BD A node represents an object which has input and or output connectors and performs a certain function SubVIs and functions are examples of nodes Wires establish the flow of data in a BD Structures such as repetitions or conditional executions are used to control the flow of a program Figure 2 1 shows what an FP and a BD window look like gt Addtxample vi Front Panel 9 Dx File Edit Operate Tools Browse Window Help SIES a aaeeeo f Figure 2 1 LabVIEW windows front panel and block diagram 2 1 2 icon and Connector Pane A VI icon is a graphical representation of a VI It appears in the top right corner of a BD or an FP window When a VI is inserted in a BD as a subVI its icon gets displayed A connector pane defin
21. meric Indicator on the FP Each numeric indicator automatically places a corresponding terminal icon on the BD Edit the labels of the indicators to read Sum and Average For a better visual appearance objects on an FP window can be aligned distributed and resized using the appropriate buttons appearing on the FP toolbar To do this 16 Getting Familiar with LabVIEW Part I select the objects to be aligned or distributed and apply the appropriate option from the toolbar menu Figure 2 17 shows the configuration of the FP just created t gt Untitled 1 Front Panel PIE Figure 2 17 FP configuration Now let us build a graphical program on the BD to perform the summation and averaging operations Note that Ctrl E toggles between an FP and a BD win dow If one finds the objects on a BD are too close to insert other functions or VIs in between a horizontal or vertical space can be inserted by holding down the Ctrl key to create space horizontally and or vertically As an example Figure 2 18 b illustrates a horizontal space inserted between the objects shown in Figure 2 18 a a b Figure 2 18 Inserting horizontal vertical space a creating space while holding down the Ctrl key and b inserted horizontal space 17 Lab 1 Next place an Add function Functions Arithmetic amp Comparison Express Numeric Add and a Divide function Functions Arithmetic amp Comparison
22. nd the frequently used tools are shown in Figure 2 4 Each tool is utilized for a specific task For example the Wiring tool is used to wire objects in a BD If the automatic tool selection mode is enabled by clicking the Automatic Tool Selection button LabVIEW selects the best matching tool based on a current cursor position Chapter 2 Automatic Tool Selection Operating tool Positioning tool A Labeling tool ee Figure 2 4 Tools palette 2 3 Building a Front Panel In general a VI is put together by going back and forth between an FP and a BD placing inputs and outputs on the FP and building blocks on the BD 2 3 1 Controls d ie eh Controls make up the inputs y soe J to a VI Controls grouped in Num Ctrl FilSide Pointer Side F Skde Pointer Slide the Numeric Controls palette aA rH are used for numerical inputs ak da ARGUS grouped in the Buttons amp Switches palette for Boolean inputs 45 Suttons amp Switches and grouped in the Text Controls palette for text and enumeration D 9 inputs These control options are pace BMC eee eee displayed in Figure 2 5 gt 4 c Toggle Switch Toggle Switch Push Button 2 3 2 Indicators rj ES d T f t Indicators make up the outputs TE adi oir M e em e eee of a VI Indicators grouped in the FA Text Control Numeric Indicators palette are used for numerical outputs grouped in oe a the LEDs palette for Boolean out ace 5 3 4 acce SMa d
23. opic of analog to digital signal conversion is presented in Chapter 3 followed by Lab 3 covering signal sampling examples Chapter 4 involves digital filtering Lab 4 in Chapter 4 shows how to use LabVIEW to design FIR and IIR digital filters In Chapter 5 fixed point versus floating point implementation issues are discussed followed by Lab 5 covering data type and fixed point effect examples In Chapter 6 the topic of adaptive filtering is discussed Lab 6 in Chapter 6 covers two adaptive filtering systems consisting of system identification and noise cancella tion Chapter 7 presents frequency domain processing followed by Lab 7 covering the three widely used transforms in signal processing fast Fourier transform FFT short time Fourier transform STFT and discrete wavelet transform DWT Chapter 8 discusses the implementation of a LabVIEW designed system on the TMS320C6000 DSP processor First an overview of the TMS320C6000 architecture is provided Then in Lab 8 a tutorial is presented to show how to use the Code Composer Studio CCStudio software development tool to achieve the DSP implementa tion As a continuation of Chapter 8 Chapter 9 and Lab 9 discuss the issues related to the interfacing of LabVIEW and the DSP processor Chapters 10 through 12 and Labs 10 through 12 respectively discuss the following three DSP systems or project examples that are fully designed via LabVIEW i dual tone multi frequency DTMF signaling ii
24. ortant for students to gain experience in a block based or graphical G pro gramming language or environment for the purpose of designing DSP systems in a relatively short amount of time Thus the main objective of this book is to provide a block based or system level programming approach in DSP lab courses The block based programming environment chosen is LabVIEW LabVIEW Laboratory Virtual Instrumentation Engineering Workbench is a graphi cal programming environment developed by National Instruments NI which allows high level or system level designs It uses a graphical programming language to create so called Virtual Instruments VI blocks in an intuitive flowchart like manner A design is achieved by integrating different components or subsystems within a graphical framework LabVIEW provides data acquisition analysis and visualization features well suited for DSP system level design It is also an open environment accommodating C and MATLAB code as well as various applications such as ActiveX and DLLs Dynamic Link Libraries This book is written primarily for those who are already familiar with signal pro cessing concepts and are interested in designing signal processing systems without needing to be proficient C or MATLAB programmers After familiarizing the reader with LabVIEW the book covers a LabVIEW based approach to generic experiments encountered in a typical DSP lab course It brings together in one place the informa
25. os ctia toI vo tad aaa e e EO OR 156 Chapter 8 DSP Implementation Platform TMS320C6x Architecture and Software Tools METUS m METERA 157 8 1 TMS32006 X DSP a iemisekatetnferiiecote rur egerit ieri md S coli mtus ipo ue ra dg 157 8 2 06x DSK Target BOB oi eh RE odes elected eR teas Deci dede dieti iua 161 8 3 DSP Programming i pete cera boi put epi tecodept e orm 163 8 4 Bibliographgooscese e fetu vehe db t iui dita AEAEE EA 166 Lab 8 Getting Familiar with Code Composer Studio 167 L8 1 Code Composer Studio eco toedie cheeses eO pP ORAN iv e 167 L5 2 Creating PpOjeets nsasaces ee i ni ii bidon ade c tegi maces Du Le e 167 L5 Debugging Fools bi eter p n Wie RU er aE rco Reais 173 L84 BibliGPtaphiyeaunsnsdisoteutitetomideeitec scott epa edt iene y ond ite sme TH ved ius 182 Chapter 9 LabVIEW DSP integration eorr rere reru nenne 183 9 1 Communication with LabVIEW Real Time Data Exchange RTDX 183 9 2 LabVIEW DSP Test Integration Toolkit for TI DSP sss 183 9 3 Combined Implementation Gain Example eee 184 9 4 BIBlIOgFaphiy nsise deett lito tae dise em bec ndr 190 Lab 9 DSP Integration Examples iins vods TOT EIT CCS Automation opio iuri Ce tenete reticere Cali eoi n EA FER 191 L9 2 Digital Filtering due iere ie encteiee ved eten iba ausus ema b ete estende i b EUR 193 L9 3 Fixed Point Implementa
26. rminal Icons ae Figure 2 10 Terminal icon examples displayed in a BD 2 4 3 Wires Wires transfer data from one node to another in a BD Based on the data type of a data source the color and thickness of its connecting wires change Wires for the basic data types used in LabVIEW are shown in Figure 2 11 Other than the data types shown in this figure there are some other specific data types For example the dynamic data type is always used for Express VIs and the waveform data type which corresponds to the output from a waveform generation VI is a special cluster of waveform components incorporating trigger time time interval and data value iii mass Terminal Icons Color Orange Floating point Blue Integer Boolean smo Figure 1 Basic types of wires 2 11 Chapter 2 2 4 4 Structures A structure is represented by a graphical enclosure The graphical code enclosed by a structure is repeated or executed conditionally A loop structure is equivalent to a for loop or a while loop statement encountered in text based programming languages while a case structure is equivalent to an if else statement 2 4 4 1 For Loop A For Loop structure is used to perform repetitions As IN illustrated in Figure 2 12 the displayed border indicates a For Loop structure where the count terminal N represents the number of times the loop is to be repeated It is set by i wir
27. rray and Cluster 2 6 Debugging and Profiling VIs 2 4 Bibliography serret te ere tbt bed ee aetna ete ics A ee AST Lab 1 Getting Familiar with LabVIEW Part l 2 2 1 5 L1 1 Building a Simple VL rrr en ariete irae L1 2 Using Structures and SubVIs L1 3 Create an Array with Indexing L14 Debugging VIs Probe Tool iudi iedseeicse occiso veiein eto eu en ria dep conet eein ehe bsaa io L1 5 Bibliography dE NIRE 30 Lab 2 Getting Familiar with LabVIEW Part ll 2 en 31 L2 1 Building a System VI with Express VlIs eese 31 L2 2 Building a System with Regular VIs eese 37 L2 y Profile VlsisaoQoundroro tA idol RR ad onan eet 41 E2 4 Bibliography uev tapete ebrei oodd dete ee aL eap EE RAS EINER VCe SE 42 Contents Chapter 3 Analog to Digital Signal CONVECrSION 1 ssnssesccnsnssenesesnsssss 43 S IP AIT RT UU 43 3 2 ATL LATOR oce drcum Pro peut Na aec ates pel cos toudens etapa cede us ctu doce dede 49 3 35 Signal Reconstr ctiOn oir edet t iere etn REPRE CUR IR EAR ERE HR RIPE Ul tu e bea teda 51 Lab 3 Sampling Quantization and Reconstruction 55 E 3808 e oor ep bt A es i uta da ted oa era edu L3 2 Fast Fourier Transform 13 3 Quantia Oe opere aasar oc iride Mag etes ats L3 4 Signal Reconstruction E325 BiblioprapBy ood ode ao e m e a e es
28. s are not meant to serve as optimizers when implementing signal processing algorithms on DSP processors or other hardware platforms This point has been addressed Preface in this book by providing two chapters which are dedicated solely to algorithm implementation on the TI family of TMS320C6000 DSP processors It is envisioned that this alternative graphical programming approach to designing digital signal processing systems will allow more students to get exposed to the field of DSP In addition the book is written in such a way that it can be used as a self study guide by DSP engineers who wish to become familiar with LabVIEW and use it to design and analyze DSP systems I would like to express my gratitude to NI National Instruments for their support of this book In particular I wish to thank Jim Cahow Academic Resources Manager at NI and Ravi Marawar Academic Program Manager at NI for their valuable feedback I am pleased to acknowledge Chuck Glaser Senior Acquisition Editor at Elsevier and Cathy Wicks University Program Manager at TI for their promotion of the book Finally I am grateful to my family who put up with my preoccupation on this book writing project Nasser Kehtarnavaz December 2004 What s on the CD ROM The accompanying CD ROM includes all the lab files discussed throughout the book These files are placed in corresponding folders as follows O O O O 9 LabOl Lab02 Lab03 Lab04
29. s faster than the device simulator but does not simulate all the peripherals Supports Functional Timer 2 Interrupt Selector EDMA and QDMA Uses a flat memory system Show this dialog next time Setup is launched Advanced Save and Quit Close Help CHAPTER Introduction The field of digital signal processing DSP has experienced a considerable growth in the last two decades primarily due to the availability and advancements in digital signal processors also called DSPs Nowadays DSP systems such as cell phones and high speed modems have become an integral part of our lives In general sensors generate analog signals in response to various physical phenomena that occur in an analog manner that is in continuous time and amplitude Pro cessing of signals can be done either in the analog or digital domain To perform the processing of an analog signal in the digital domain it is required that a digital signal is formed by sampling and quantizing digitizing the analog signal Hence in con trast to an analog signal a digital signal is discrete in both time and amplitude The digitization process is achieved via an analog to digital A D converter The field of DSP involves the manipulation of digital signals in order to extract useful informa tion from them There are many reasons why one might wish to process an analog signal in a digital fashion by converting it into a digital signal The main reason is th
30. te for taking DSP lab courses However last year for the first time I provided a different response by saying Though preferred it is not required to know C to take DSP lab courses This change in my response came about because I started using LabVIEW to teach students how to design and analyze DSP systems in our DSP courses The widely available graphical programming environments such as LabVIEW have now reached the level of maturity that allow students and engineers to design and analyze DSP systems with ease and in a relatively shorter time as compared to C and MATLAB I have observed that many students taking DSP lab courses in particular at the undergraduate level often struggle and spend a fair amount of their time debugging C and MATLAB code instead f placing their efforts into understanding signal processing system design issues The motivation behind writing this book has thus been to avoid this problem by adopting a graphical programming approach instead of the traditional and commonly used text based programming approach in DSP lab courses As a result this book allows students to put most of their efforts into building DSP systems rather than debugging C code when taking DSP lab courses One important point that needs to be mentioned here is that in order to optimize signal processing algorithms on a DSP processor it is still required to know and use C and or assembly programming The existing graphical programming environment
31. tion s sssssssssesesssssssnsesssscesssasasevesocococacncaceseseseseoees 202 L9 4 Adaptive Filtering Systems eese ettet entente tninena 206 L9 5 Frequency Processing BF E iet tuber tete leicvo dae etede rap ext axes i dun 211 L9 6 BiBliostaplig aes eee tintas re b tas ipi a bel oc OR ada tont metab ous 220 Chapter 10 DSP System Design Dual Tone Multi Frequency DTMF Signaling E sivsovenente 22I 10 1 Bibliography cose e oie eo estia el habebo Lob v ads UB otc use creto 224 Lab 10 Dual Tone Multi Frequency rS 225 L10 1 DTMF Tone Generator System cccsssssesesesesessssscescsssesscsescsssssscscssscssvssssavaes 225 Contents L10 2 DTMF Decoder System ssiessssccsteestasnccsbccsdesounsaes en rant ure van ebeur ione ode tacuit pompe 228 10 3 BibBosiapliy ide Eoo e SE E mee tete nib sen e o i be depu tos 230 Chapter 11 DSP System Design Software Defined Radio 231 ILILOAM Transmitter oer iri qe eri breuis rep espere eea RM ate 231 11 2 QAM R celVet cds ee mut napi e iot sec ditio dt inea PRO POR RE UIME 234 11 3 Bibliography ae ree aco Robur tt rece imas iba tet loeo ratito 238 Lab 1 I Building a 4 QAM Modem EBEESSEBEEHREHEENEBESEBBEBEESNBBESBUERSRSEESESERBESNEEESBEESER 239 L11 1 QAM Transmitter seed e uev HACER e es 239 LEE ZAM RecelVGk ecce cuentexei a iive Deec ese E iE pn ties iei restu ire pe

Download Pdf Manuals

image

Related Search

Related Contents

My Research Applications - User Guide  profeco informa sobre el llamado a revisión de la empresa brp  Altec Lansing VS4121 Speaker System User Manual  H.I.Dバルブセット 組付・取扱説明書  Montagewerkzeuge  MUSTANG DUO  User's Manual  Belkin Play N600  Haier L32F6 User's Manual  SMARTYCAM Manuale Utente  

Copyright © All rights reserved.
Failed to retrieve file