You are previewing Digital Waveform Generation.
O'Reilly logo
Digital Waveform Generation

Book Description

This concise overview of digital signal generation will introduce you to powerful, flexible and practical digital waveform generation techniques. These techniques, based on phase-accumulation and phase-amplitude mapping, will enable you to generate sinusoidal and arbitrary real-time digital waveforms to fit your desired waveshape, frequency, phase offset and amplitude, and to design bespoke digital waveform generation systems from scratch. Including a review of key definitions, a brief explanatory introduction to classical analogue waveform generation and its basic conceptual and mathematical foundations, coverage of recursion, DDS, IDFT and dynamic waveshape and spectrum control, a chapter dedicated to detailed examples of hardware design, and accompanied by downloadable Mathcad models created to help you explore 'what if?' design scenarios, this is essential reading for practitioners in the digital signal processing community, and for students who want to understand and apply digital waveform synthesis techniques.

Table of Contents

  1. Coverpage
  2. Digital Waveform Generation
  3. Title page
  4. Copyright page
  5. Contents
  6. Preface
  7. Acknowledgements
  8. Glossary of terms
  9. 1 Introduction to waveform generation
    1. 1.1 Preliminaries
      1. 1.1.1 Outline chapter content
      2. 1.1.2 Digital signal processing
      3. 1.1.3 Periodic and aperiodic waveforms
      4. 1.1.4 Introducing the sine wave – properties and parameters
      5. 1.1.5 Instantaneous phase and frequency
      6. 1.1.6 From phase to amplitude – the waveform function
      7. 1.1.7 Signal definition – waveform or spectrum?
      8. 1.1.8 Signal specification – time or frequency domain?
      9. 1.1.9 A brief history of digital waveform generation
    2. 1.2 A taxonomy of electronic waveform generation
      1. 1.2.1 Background
      2. 1.2.2 Analogue waveform generation
      3. 1.2.3 Hybrid waveform generation
      4. 1.2.4 Digital waveform generation
      5. 1.2.5 Arbitrary waveform generation
    3. 1.3 Analogue waveform generation
      1. 1.3.1 Analogue waveform generation in test instrumentation
      2. 1.3.2 The Wien bridge oscillator
      3. 1.3.3 The state variable oscillator
      4. 1.3.4 The voltage-controlled switched integration oscillator
      5. 1.3.5 The charge-balancing voltage to frequency convertor
      6. 1.3.6 The shortcomings of analogue waveform generation
    4. 1.4 Applications of arbitrary waveform generation
      1. 1.4.1 Test and diagnostic applications
      2. 1.4.2 Signal emulation applications
      3. 1.4.3 Bespoke embedded applications
      4. 1.4.4 RF up-conversion applications
      5. 1.4.5 Unique DDS AWG attributes
      6. 1.4.6 A simple example – testing a PLL
    5. 1.5 Summary
    6. 1.6 References
  10. 2 The foundations of digital waveform generation
    1. 2.1 Mathematical preliminaries
      1. 2.1.1 Continuous- and discrete-time signals
      2. 2.1.2 The phase–frequency relationship of a discrete-time sinusoid
      3. 2.1.3 Analogue reconstruction and alias image rejection
      4. 2.1.4 Quantisation and digital to analogue conversion
    2. 2.2 A fundamental concept – sampling a tabulated signal
      1. 2.2.1 Tabulating a signal – introducing the wavetable
      2. 2.2.2 Regenerating a tabulated signal
      3. 2.2.3 A sample rate conversion view
      4. 2.2.4 Frequency control resolution and wavetable length
    3. 2.3 Tabulating a waveform function
      1. 2.3.1 The wavetable revisited
      2. 2.3.2 Tabulating the sine function
      3. 2.3.3 Time domain arbitrary waveform specification
      4. 2.3.4 Frequency domain arbitrary waveform specification
    4. 2.4 The foundations of direct digital synthesis (DDS)
      1. 2.4.1 Phase accumulation frequency synthesis
      2. 2.4.2 Phase–amplitude mapping
      3. 2.4.3 Phase continuity
      4. 2.4.4 Phase–amplitude mapping and fractional addressing
      5. 2.4.5 The aliasing problem
    5. 2.5 Control parameters and their characteristics
      1. 2.5.1 Desirable control characteristics
      2. 2.5.2 Frequency control
      3. 2.5.3 Phase offset control
      4. 2.5.4 Amplitude control
      5. 2.5.5 Waveshape control
      6. 2.5.6 Spectrum control
    6. 2.6 Performance metrics
      1. 2.6.1 Phase truncation noise
      2. 2.6.2 The amplitude error spectrum
      3. 2.6.3 Waveshape error
      4. 2.6.4 Phase noise
      5. 2.6.5 Arithmetic processing requirements
    7. 2.7 Summary
    8. 2.8 References
  11. 3 Recursive sine wave oscillators
    1. 3.1 Mathematical preliminaries
    2. 3.2 The direct-form
    3. 3.3 The coupled-form
    4. 3.4 The modified coupled-form
    5. 3.5 The waveguide-form
    6. 3.6 Implementation considerations
      1. 3.6.1 Initial conditions
      2. 3.6.2 Arithmetic quantisation effects
      3. 3.6.3 Frequency control
    7. 3.7 Summary
    8. 3.8 References
  12. 4 DDS sine wave generation
    1. 4.1 Phase accumulation, truncation and arithmetic processing
      1. 4.1.1 Ideal sinusoidal DDS
      2. 4.1.2 Optimal phase–amplitude mapping
      3. 4.1.3 Phase truncation and fractional wavetable addressing
      4. 4.1.4 Linear phase interpolation
      5. 4.1.5 Static and dynamic phase offset
      6. 4.1.6 Quadrature sine wave generation
      7. 4.1.7 Introducing phase domain processing
    2. 4.2 Theoretical analysis of DDS phase truncation errors
      1. 4.2.1 The DDS error model
      2. 4.2.2 Phase truncation errors
      3. 4.2.3 Wavetable sample quantisation errors
    3. 4.3 Sinusoidal phase–amplitude mapping
      1. 4.3.1 SNR and oversampling
      2. 4.3.2 Phase truncated wavetable indexing
      3. 4.3.3 Phase dithered wavetable indexing and noise shaping
      4. 4.3.4 Linear phase interpolated wavetable indexing
      5. 4.3.5 Trigonometric identity phase interpolation
      6. 4.3.6 Sinusoidal wavetable compression
      7. 4.3.7 Direct computation phase–amplitude mapping – the CORDIC algorithm
    4. 4.4 Summary
    5. 4.5 References
  13. 5 DDS arbitrary waveform generation
    1. 5.1 From sinusoidal to arbitrary waveforms
      1. 5.1.1 Phase truncation and the need for interpolation
      2. 5.1.2 Introducing Lagrange polynomial interpolation
      3. 5.1.3 The harmonic aliasing problem
      4. 5.1.4 Time domain specification of an arbitrary waveform
      5. 5.1.5 Frequency domain specification of an arbitrary waveform
      6. 5.1.6 Defining DDS AWG simulation parameters
      7. 5.1.7 Optimal phase–amplitude mapping
    2. 5.2 Interpolated phase–amplitude mapping
      1. 5.2.1 Phase truncated wavetable indexing
      2. 5.2.2 Phase dithered wavetable indexing
      3. 5.2.3 Linear phase interpolated wavetable indexing
      4. 5.2.4 Lagrange polynomial phase interpolated wavetable indexing
    3. 5.3 Analogue waveshaping
      1. 5.3.1 The phase accumulator as a digital frequency synthesiser
      2. 5.3.2 Analogue waveshaping principles and some fundamental problems
      3. 5.3.3 Triangle waveform shaping
    4. 5.4 DDS clock generation
      1. 5.4.1 Hard-limited sinusoidal DDS
      2. 5.4.2 Reconstruction filter bandwidth
    5. 5.5 Variable sample frequency AWG
      1. 5.5.1 Basic architecture and implementation limitations
      2. 5.5.2 Harmonic aliasing and reconstruction filter considerations
    6. 5.6 Computer music and audio test applications of DDS AWG
      1. 5.6.1 Harmonics and partials
      2. 5.6.2 Frequency control, musical pitch and tuning
      3. 5.6.3 Audio measurement – harmonic and intermodulation distortion
    7. 5.7 Summary
    8. 5.8 References
  14. 6 Dynamic waveshape and spectrum control
    1. 6.1 Paged wavetable memory – piecewise stepped waveshaping
      1. 6.1.1 Page indexing a group of wavetables
      2. 6.1.2 Specifying a group of wavetables
      3. 6.1.3 Paged wavetable interpolation – piecewise continuous waveshaping
      4. 6.1.4 Frequency domain behaviour
    2. 6.2 Linear combination of multiple wavetables
      1. 6.2.1 Single phase accumulator case – harmonic signal synthesis
      2. 6.2.2 The IDFT as a limiting case
      3. 6.2.3 Multiple phase accumulator case – band-pass signal synthesis
    3. 6.3 Modulation
      1. 6.3.1 Frequency, phase and amplitude modulation
      2. 6.3.2 FSK and PSK modulation
      3. 6.3.3 Frequency sweep and chirp generation
    4. 6.4 Summary
    5. 6.5 References
  15. 7 Phase domain processing – DDS and the IDFT
    1. 7.1 Fundamental concepts
      1. 7.1.1 The inverse discrete Fourier transform (IDFT)
      2. 7.1.2 Weighted phase sequence summation
      3. 7.1.3 Dynamic spectrum control and the metaparameter
      4. 7.1.4 Aliasing control and the mitigation of Gibbs phenomenon
      5. 7.1.5 Time division multiplexing (TDM)
    2. 7.2 Contiguous harmonic phase generation and the IDFT
      1. 7.2.1 Harmonic phase accumulation
      2. 7.2.2 Harmonic phase offset
      3. 7.2.3 Amplitude accumulation
    3. 7.3 Non-contiguous harmonic phase generation
      1. 7.3.1 Phase multiplication
      2. 7.3.2 Modulo integer multiplication
    4. 7.4 Summary
    5. 7.5 References
  16. 8 Hardware implementation architectures
    1. 8.1 Processing techniques and design considerations
      1. 8.1.1 Pipelined and parallel processing
      2. 8.1.2 Sample and block pipelining
      3. 8.1.3 Time division multiplexing
      4. 8.1.4 Arithmetic and modulo accumulation
      5. 8.1.5 High speed binary addition
      6. 8.1.6 Wavetable memory architectures
      7. 8.1.7 Vector memory
    2. 8.2 Partitioned phase accumulation
    3. 8.3 Sinusoidal phase–amplitude mapping
      1. 8.3.1 Linear phase interpolation
      2. 8.3.2 Trigonometric identity phase interpolation
    4. 8.4 Interpolated vector memory
      1. 8.4.1 Linear interpolation architecture
      2. 8.4.2 Cubic interpolation architecture
      3. 8.4.3 Interpolated vector memory design considerations
      4. 8.4.4 A paged wavetable interpolation memory
    5. 8.5 Waveform generation by direct computation
      1. 8.5.1 A contiguous harmonic IDFT waveform synthesiser
      2. 8.5.2 An arbitrary harmonic IDFT waveform synthesiser
      3. 8.5.3 A band-pass spectrum waveform synthesiser
    6. 8.6 Summary
    7. 8.7 References
  17. 9 Digital to analogue conversion
    1. 9.1 Error mechanisms
      1. 9.1.1 Offset error
      2. 9.1.2 Gain error
      3. 9.1.3 Settling time
      4. 9.1.4 Transition or ‘glitch’ errors
      5. 9.1.5 Linearity errors
      6. 9.1.6 DAC quantisation noise
    2. 9.2 DAC dynamic specification considerations
      1. 9.2.1 Harmonic and intermodulation distortion
      2. 9.2.2 Spurious-free dynamic range (SFDR)
      3. 9.2.3 Signal-to-noise ratio (SNR)
    3. 9.3 The reconstruction filter
      1. 9.3.1 Frequency and phase response
      2. 9.3.2 Filter implementation – passive or active?
      3. 9.3.3 Signal distortion pitfalls – maintaining SFDR
      4. 9.3.4 Reconstruction filter design considerations – hints and tips
    4. 9.4 Supplementary analogue design considerations
      1. 9.4.1 The DAC reference voltage and output amplifier
      2. 9.4.2 Switched attenuation and output level control
      3. 9.4.3 DC offset and output dynamic range considerations
      4. 9.4.4 The output drive amplifier
      5. 9.4.5 Square and pulse waveforms
    5. 9.5 Summary
    6. 9.6 References
  18. Index