1 / 38

Data Representation

Data Representation. Computers use base 2,. instead of base 10:. Internally, information is represented by binary digits; “switches” that are either on or off. Digital information must be converted to analog signals: DAC: Digital to Analog Converter. Computer. Computer. Data Converters.

tammy
Download Presentation

Data Representation

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Data Representation • Computers use base 2, instead of base 10: Internally, information is represented by binary digits; “switches” that are either on or off. 111 BSC Data Acquisition and Control

  2. Digital information must be converted to analog signals: • DAC: Digital to Analog Converter. Computer Computer Data Converters • Signals must be converted to their digital representation: • ADC: Analog to Digital Converter. • ADCs and DAQs are imperfect. Important parameters include: • Sample rate. • Resolution. • Linearity. 111 BSC Data Acquisition and Control

  3. Conversion: Sampling 111 BSC Data Acquisition and Control

  4. Conversion: Sample Rate • High Sample Rates can better represent high frequency waveforms. 111 BSC Data Acquisition and Control

  5. Conversion: Nyquist Theorem • What is the lowest sample rate that can represent a signal? • The Nyquist Theorem states that a wave can be correctly represented when sampled at a rate equal to twice the highest frequency of the wave. 111 BSC Data Acquisition and Control

  6. Conversion: Aliasing • Sampling below the Nyquist frequency leads to aliasing: 111 BSC Data Acquisition and Control

  7. Conversion: What rate? • Preferably, one should operate far above the Nyquist limit. • Sampling 10 to 100 times higher than the signal frequency generally works very well. 111 BSC Data Acquisition and Control

  8. Conversion: What rate? • Unfortunately, it is often impossible to sample this fast. • The employed device may not be capable of sampling at the desired rate. • The desired rate may be technologically impossible. • Even if it is possible, you may not be able to afford the required device. • ADC’s • 250kS/s --- $375 for a computer card. • 10MS/s --- $4000. • 200MS/s --- $6000. • 1GS/s ---$10,000. • DAC’s • Static --- 8 Channels for $700. • 1MS/s --- 4 Channels for $800. • 200M/s --- 1 Channel for $6000. 111 BSC Data Acquisition and Control

  9. Conversion: What rate? • Unfortunately, it is often impossible to sample this fast. • The employed device may not be capable of sampling at the desired rate. • The desired rate may be technologically impossible. • Even if it is possible, you may not be able to afford the required device. • Fast sampling may produce or require too much data. • Limited buffer sizes • Limited computational speeds. 111 BSC Data Acquisition and Control

  10. “Flat” Interpolation “Ramp” Interpolation Comb Interpolation No Interpolation Theoretically optimal Commonly used by DACs Option on expensive DACs Conversion: Near Nyquist Sampling Using the “Sampling Simulator,” explore the effects of various sampling rates on different waveforms with interpolation off. Real world signals are continuous. Sampling is discontinuous. Interpolation is used to turn the discontinuous samples into a continuous signal. Using interpolation, explore the effects of various sampling rates on different waveforms. Note: that well above the Nyquist frequency, ramp interpolation represents the signal better than flat interpolation. 111 BSC Data Acquisition and Control

  11. Conversion: Near Nyquist Sampling Below the Nyquist Frequency, aliasing can produce deceptively pretty waveforms. Be careful. • Just above the Nyquist Frequency, the sampled waveforms look nothing like the original waveform. Is the Nyquist Theorem wrong? 111 BSC Data Acquisition and Control

  12. Conversion: Near Nyquist Sampling • The sampled spectrum has two peaks; • One at the original signal frequency. • One above the Nyquist frequency. • We observe an apparent beat between these frequencies. 111 BSC Data Acquisition and Control

  13. Conversion: Near Nyquist Sampling • The sampled spectrum has two peaks; • One at the original signal frequency. • One above the Nyquist frequency. • We observe an apparent beat between these frequencies. • The higher frequency can be filtered away to recover the original signal from the sampled signal. • Filtering must be done carefully. 111 BSC Data Acquisition and Control

  14. Conversion: Near Nyquist Sampling Two Tone Signal 111 BSC Data Acquisition and Control

  15. Conversion: Near Nyquist Sampling AM Modulated Signal 111 BSC Data Acquisition and Control

  16. First Order RC filters are not sharp enough. Conversion: RC Filtering • We need to kill frequencies higher than the Nyquist Frequency. • Could use an RC filter: 111 BSC Data Acquisition and Control

  17. Conversion: RC Filtering • Try a 2nd order filter: 111 BSC Data Acquisition and Control

  18. Conversion: RC Filtering • We need even higher order. • A 6th order RC filter kills the amplitude by a factor of 100 one octave above its cutoff. 111 BSC Data Acquisition and Control

  19. Conversion: RC Filtering • But the signal is significantly reduced in the passband as well! 111 BSC Data Acquisition and Control

  20. Conversion: Sharper Filters • Filter designs using inductors (or gyrator synthesized inductors) are much sharper. • Using, as a figure of merit, a reduction by a factor of 100 one octave above the cutoff: • Chebyshev has the best frequency response. 111 BSC Data Acquisition and Control

  21. Conversion: Temporal Response • Unfortunately, good frequency response generally yields poor temporal response. • Bessel filters have the best temporal response. 111 BSC Data Acquisition and Control

  22. Conversion: When is Filtering Required? • Both DACs and ADC usually require filters. • DACs: • Filtering turns the discontinuous output from your DAC into a continuous signal. • Occasionally, the device being driven by the DAC is insensitive to the high frequency components in the unfiltered DAC output. If so, filtering is unnecessary. 111 BSC Data Acquisition and Control

  23. Conversion: When is Filtering Required? • Both DACs and ADC usually require filters. • ADCs: • Filtering prevents aliasing. • Input signals are often noisy, and this noise may extend above the Nyquist frequency. 111 BSC Data Acquisition and Control

  24. Conversion: When is Filtering Required? • Both DACs and ADC usually require filters. • ADCs: • Filtering prevents aliasing. • Input signals are often noisy, and this noise may extend above the Nyquist frequency. On sampling: • Frequencies above the Nyquist Frequency mirror: 111 BSC Data Acquisition and Control

  25. Conversion: When is Filtering Required? • Both DACs and ADC usually require filters. • ADCs: • Filtering prevents aliasing. • Aliasing artifacts confuse the spectrum and distort the waveforms. • Unless the spectrum is very quiet above the Nyquist frequency, the signal must be filtered before it is converted by the ADC. • But filtering itself introduces artifacts: • Spectral amplitude errors in the passband. • Distortions to the temporal waveform. 111 BSC Data Acquisition and Control

  26. Conversion: When is Filtering Required? • Both DACs and ADC usually require filters. • ADCs: • Filtering prevents aliasing. • Very occasionally aliased signals can still be used. • Spectrum is predictable, but reversed. • The DAC’s analog bandwidth may make 111 BSC Data Acquisition and Control

  27. Conversion: When is Filtering Required? • Both DACs and ADC usually require filters. • ADCs: • Filtering prevents aliasing. • Filtering turns the discontinuous measurements from your ADC into a continuous signal. • “Ideal” filters for static signal reconstruction can be developed using Fourier Transforms. • Filtering is unnecessary if you are only interested in the spectral content of your signal. 111 BSC Data Acquisition and Control

  28. Conversion: Resolution • Resolution specified in number of bits. • n-bit converter can represent 2n levels. 111 BSC Data Acquisition and Control

  29. BSC Data Acquisition Card *Though not spec’d to do this the card will digitize faster than 1.6MS/s when acquiring a single channel. 111 BSC Data Acquisition and Control

  30. DAC Circuits: Scaled Resistor bn is either 0 (off) or 1 (on.) Then: 111 BSC Data Acquisition and Control

  31. Focus on a low and high order bit: Instead of changing the output from 4095 to 4096, it would change to 4055 or 4137. DAC Circuits: Scaled Resistor DAC Errors • What happens if the high order bit resistor is off by 1%? Say: or: 111 BSC Data Acquisition and Control

  32. DAC Circuits: Scaled Resistor DAC Errors • A 16bit DAC requires resistors accurate to 0.002% over a 1:65536 resistance range. • Such accurate resistors cannot be fabricated. • Accurate resistors can be fabricated over a narrow resistance range. • Laser trimming. 111 BSC Data Acquisition and Control

  33. Virtual Ground DAC Circuits: R-2R 111 BSC Data Acquisition and Control

  34. DAC Circuits: R-2R Ladder 111 BSC Data Acquisition and Control

  35. DAC Circuits: R-2R Ladder 111 BSC Data Acquisition and Control

  36. DAC Circuits: R-2R Ladder 111 BSC Data Acquisition and Control

  37. ADC Circuits: Flash (Parallel) Converters Very fast. Low Resolution Expensive 111 BSC Data Acquisition and Control

  38. ADC Circuits: Successive Approximation • Make a guess. • Convert the guess to a voltage with a DAC. • Compare the guess voltage to the actual voltage. • Refine the guess.... • Stop when satisfied with the accuracy of theanswer. 111 BSC Data Acquisition and Control

More Related