Digital Oscilloscope Application

I have created a simple digital oscilloscope application using the component software, in order to test some electronic equipment I am currently building. This application duplicates many of the useful features of my Tektronix oscilloscope on the computer. Two channels of data can be continuously acquired and plotted in 1 and 2d. A new module provides triggering on either of the channels, and computes various statistics about the signals, including the magnitude and frequency of each channel, the relative magnitude (gain) and phase of channel 2 with respect to channel 1, and the delay in milliseconds:

(Click for bigger image)

This application can be used to test the frequency response (gain and phase) of external electronics by comparing two channels: one directly from a signal generator, and the other having passed through the elctronics to be tested. By manually adjusting the frequency of the input sine wave (i.e. by turning the frequency knob of the signal generator very slowly), the gain and phase difference between the channels can be accumulated and plotted (in "etch-a-sketch" fashion) for a continuous range of frequencies:

(Click for bigger image)

The previous image shows the frequency response of an instrument amplifier (#2) with a 4th-order active lowpass filter at about 100 Hz. The next image shows the frequency response of an instrument amplifier (#3) with 2 2nd-order active notch filters at about 60 Hz, plus a 4th-order active lowpass filter at about 100 Hz:

(Click for bigger image)

The next step in this application will be to fit a 1d function to each response curve, so that the magnitude and phase of a real input signal can be adjusted at each frequency component, so as to remove the distortion caused by the response of the electronics.

However, one feature of both amplifiers is immediately obvious by looking at the response curves above: Although I am interested only in frequencies from 1-100 Hz, and have used a 4th-order lowpass filter at about 100 Hz, the gain of the response does not fall off sufficiently to avoid significant aliasing until about 300 Hz. Thus, the signal must be sampled at about 600 Hz in order to avoid aliasing, even though a maximum frequency of only 100 Hz is desired. After the signal has been discretized at 600 Hz, it may be digitally filtered so as to eliminate frequencies above 100 Hz, and also to reduce the number of samples required down to about 200/sec.

©Copyright Sky Coyote, 2000-2002.