• BME 210
• # Lab 8: Signal Acquisition

## 1. Objectives

By the end of this laboratory session students will be able to:

• Acquire an analog signal without aliasing
• Determine the Nyquist frequency required for a simple analog signal

## 2. Background

Analog signal processing uses fixed electronic components such as resistors and capacitors to process analog signals. An example would be RC low-pass filter to filter signals. Analog signal processing may be the quickest and most economical way to perform simple filtering of signals, but it is less flexible and less accurate than digital signal processing (DSP) for performing more complex signal processing.

Digital acquisition devices (DAQs) are used for analog-to-digital conversion (A/D or A-to-D) and digital-to-analog conversion (D/A or D-to-A). Analog signals must be sampled and converted into a digital (discrete) representation before they can be processed by a computer. Sampling works by periodically reading the value of an analog signal. The sampling rate determines how often the analog signal is read. Once digitized, computers can perform filtering, waveform analysis, etc., on the signals. The digital signals can then be converted back into analog signals.

A fundamental concept in signal acquisition is the Nyquist frequency, which is twice the highest frequency contained in the signal one wishes to sample. Signals must be sampled at or above the Nyquist frequency to avoid corrupting the digitized signal. An analog signal can be low-pass filtered to establish a known Nyquist frequency prior to sampling.

Resolution is the number of bits that are used to represent the amplitude of an acquired signal. Modern DAQ boards have resolutions of 12 or 14 bits, which means they can handle $$2^{12}$$ and $$2^{14}$$ amplitude values, respectively.

## 3. Laboratory Equipment

1. NI USB 6009 DAQ
2. Computer with Labview
3. Function generator
4. Cable: BNC to clip-leads
5. Hook-up wire
6. Wire strippers
7. Small flat-blade screwdriver

## 4. Procedure

1. Connect the NI 6009 DAQ to the computer with the USB Cable. Use the USB ports on the PC. The ports built into the monitor can’t keep up.
2. Connect the function generator to the DAQ using a BNC to Clip-Lead cable.

a. Red Function generator lead to DAQ analog input 0 (AI0+)

b. Black Function generator lead to DAQ GND.

3. Turn the function generator on and set it to generate a 25 Hz sine wave with an amplitude of 1 $$\mathrm{V_{pp}}$$.

4. Set Function generator output to high impedance: Press UtilityOutput SetupHigh ZDone. This makes the function generator assume it is delivering a signal into an infinite resistance load.

5. If not already on the dektop, download the LabView file BME_210_Acquisiton_Lab.VI. Double-click on the file to launch LabView.

6. On the Signal Acquisition front panel:

a. Set the sample period to 0.5 sec and the sample rate to 1000 Hz.

b. Under Physical Channel, pull down the menu and select DevX/ai0, where X may be 1,2,3,4, depending on your station.

c. Click the Run button (next to the Run Continuously button).

d. Make sure the 60 Hz noise button is Off.

7. Sketch the signal in the time domain.

8. On the Signal Acquisition front panel:

a. Set the sample period to 0.5 sec and the sample rate to 25 Hz.

b. Click the Run button (next to the Run Continuously button).

c. Make sure the 60 Hz noise button is Off.

9. Sketch the signal in the time domain.

10. On the Signal Acquisition front panel:

a. Change the sampling rate to 50 Hz, click Run, and sketch the time domain signal.

b. Change the sampling rate to 400 Hz, click Run, and sketch the time domain signal.

11. On the Signal Acquisition front panel observe the power spectrum (i.e., the frequency domain of the signal) at a sampling rate of 400 Hz.

12. Sketch and label the axes of the power spectrum.

13. Change the sampling rate to 75 Hz.

14. On the Function Generator:

a. Change the sine wave frequency to 10 Hz, click Run on LabView, and record the location of the peak in the power spectrum.

b. Change the sine wave frequency to 50 Hz, click Run on LabView, and record the location of the peak on the power spectrum.

15. Change the sampling rate to 400 Hz.

16. On the Function Generator:

a. Change the waveform to a square wave with a frequency of 10 Hz and click Run. Sketch and label the axes of the power spectrum.

b. Change the waveform to a ramp wave with a frequency of 10 Hz and click Run. Sketch and label the axes of the power spectrum.

17. Use Labview to introduce 60 Hz noise.

a. On the Function Generator change the waveform to a 5 Hz sine wave.

b. On the the Signal Acquisition front panel enter a 60 Hz noise amplitude of 0.25. Turn the 60 Hz noise On. Click Run.

18. Sketch the time domain signal and the power spectrum.

19. Change the 60 Hz noise amplitude to 1 Vpp and click Run.

20. Sketch the time domain signal and the power spectrum.

21. Take a couple of minutes to look at the block diagram for the Labview program. From the Labview Toolbar:

a. WindowShow Block Diagram. This shows the ‘wiring’ of the LabView program.

b. HelpShow Context Help. This opens a context-sensitive window – move the pointer over an object to learn about it.

c. WindowShow Front Panel. This will take you back to the front panel.

22. When done, turn the equipment off and close LabView.

23. Check the results section below to make sure you have everything needed for a complete lab report.

## 5. Results

1. From 14a: Record the location of the peak in the power spectrum at 10 Hz
2. From 14b: Record the location of the peak in the power spectrum. At 50 Hz. Is this what you expected? Why or Why not?
3. From 16 a & b: Qualitatively describe how the frequency domain correlates to the time domain representation.
4. From 16 a & b: Which waveform has the most frequency components: sine, square, or ramp?
5. From 17: What happens to the time domain signal and the power spectrum?
6. Include all of your sketches. Remember to label axes and give each sketch a title.
7. Search for the NI USB 6009 DAQ datasheet on the internet. The National Instruments website may also have an accessible copy. Record the analog input voltage range, input resolution, and maximum sampling rate in kilosamples/sec.

## 6. Boring admin stuff

You may need to download Arithmetic.llb and CG_Common.llb. Save both to desktop and the signal acquisition VI load fine.

Last updated:
January 5, 2018