New version page

UMDNJ ECE 521 - Experiments

Upgrade to remove ads
Upgrade to remove ads
Unformatted text preview:

RUTGERS UNIVERSITYThe State University of New JerseySchool of EngineeringDepartment of Electrical and Computer Engineering94 Brett Road, Piscataway, NJ 08854-8058Tel. 732-445-5017, e-mail: [email protected]:348 — Digital Signal Processing LaboratorySpring 2003ADSP-2181 ExperimentsSophocles J. Orfanidissampleprocessingalgorithmrx-bufcodecanalog inputanalog outputAD1847ADSP-2181 DSPtx-bufxyfsCopyright © 1996–2003 by S. J. Orfanidishttp://www.ece.rutgers.edu/~orfanidi/ezkitl/ezkitl.htmlContents1 Introduction 12 Getting Started 12.1 Running DSP Programs........................... 12.2 Decimal to Hex Format Converters..................... 32.3 Wavetable Generator Programs....................... 42.4 Subdirectory Structure............................ 53 Instruction Set Tutorial 53.1 Computational Units.............................63.2 Data Transfers................................ 73.3 DAG Registers and Circular Buffers.................... 93.4 Defining and Initializing a Delay...................... 103.5 Reading and Writing a Delay-Line Buffer.................. 103.6 Updating a Delay............................... 123.7 Multifunction Instructions and FIR Filters................. 123.8 Linear Delay-Line Buffers..........................153.9 Concatenated Circular Buffers....................... 164 Experiments 164.1 Sampling and Quantization ......................... 164.2 Delays..................................... 234.3 FIR Filters................................... 254.4 Comb Filters................................. 324.5 Plain Reverb.................................. 374.6 Allpass Reverb................................ 414.7 Lowpass Reverb................................ 464.8 Schroeder’s Reverb.............................. 484.9 Stereo Reverb................................. 524.10 Reverberating Delay............................. 554.11 Multi-Delay Effects.............................. 574.12 Multitap Delay Effects............................ 594.13 Karplus-Strong String Algorithm...................... 624.14 Wavetable Generators............................ 644.15 Notch Filters................................. 694.16 Flangers and Phasers............................. 804.17 Simulator Examples............................. 855 Macros 975.1 zero...................................... 985.2 tap....................................... 985.3 tapin...................................... 995.4 cdelay..................................... 995.5 dot.......................................1005.6 cfir.......................................101CONTENTS 35.7 ccan......................................1025.8 cdir.......................................1055.9 wavgen.....................................1076 Appendix 1086.1 Decimal-to-Hex Format Converters.....................1086.2 Wavetable Generators............................1106.3 Template and Begin/End Files.......................113References 1151 INTRODUCTION 11. IntroductionThis manual describes a number of hardware experiments illustrating the concreteimplementation of various DSP algorithms on the ADSP-2181 chip.The experiments include quantization and aliasing effects; the circular bufferimplementation of delays, FIR, and IIR filters; the canceling of periodic interferencewith notch filters; wavetable generators; and several audio effects, such as combfilters, flangers and phasers, plain, allpass, and lowpass reverberators, Schroeder’sreverberator, and several multi-tap, multi-delay, and stereo-delay type effects, aswell as the Karplus-Strong string algorithm. All of the experiments are based onthe text [1].Our aim in these experiments is not to necessarily write the most efficient as-sembly code, but rather to show beginning DSP students how straightforward andfun it is to program a DSP chip and hear the algorithms in action. Thus, we have attimes sacrificed efficiency for clarity.To facilitate the programming of these applications, we have written a number ofassembly code macros that closely parallel some of the C routines in the text, suchas cdelay and tap, and allow the manipulation of circular delay-line buffers andthe building up of more complex block diagrams. Our use of circular buffers andpointers is identical to that in the text (e.g., filter coefficients and states are storedin forward order and a delay is implemented by decrementing the buffer pointer.) Anumber of DOS utilities are also included, such as decimal-to-hex format convertersand wavetable generators.All of the included programs are based on the talkthru example program givenin the EZ-KIT Lite Reference Manual [2]. All processor and codec initialization de-tails have been hidden away in two include-files, begin.dsp and end.dsp, simpli-fying the structure of the programs and allowing the students to concentrate onthe translation of their sample processing algorithm to assembly code.Several reference resources are available. Besides the EZ-KIT Reference Manualand Data Sheets included in the kits, the following reference books may be obtained(in PDF format) from the Analog Devices web page www.analog.com:1. ADSP-2100 Family User’s Manual (also included in the newest kits.)2. DSP Applications Using the ADSP-2100 Family, vols. 1 & 2.2. Getting Started2.1. Running DSP ProgramsThe process of running a signal processing algorithm on the ADSP-2181 chip of theEZ-KIT Lite board consists of three stages:1. Creating a text source file containing the assembly code implementation ofthe algorithm. The default filename extension is .dsp. The DOS edit or emacstext editors may be used to edit the source file. They can be invoked by theDOS commands:2 GETTING STARTED 2edit filename.dspemacs filename.dsp2. Compiling and linking the source file using the assembler and linker programsasm21.exe and ld21.exe. These operations have been automated into theDOS batch file ezk.bat, which can be invoked as follows:ezk filenamewhere the source is filename.dsp. The result of these operations is theexecutable file filename.exe. (This is executable on the 2181 chip, not underDOS.)3. Loading the executable file onto the chip via the serial connection using DwightElvey’s public-domain loader program ezld.com found in [3]. The operationhas again been automated by a batch file, ezl.bat, and is invoked from DOSas follows:ezl filenameThis loads filename.exe onto the processor and begins execution immedi-ately. One can also load the program and enter a menu-oriented terminalprogram by the


View Full Document
Download Experiments
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Experiments and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Experiments 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?