Me 5
Me 5
http://www.ni.com/getting-started/labview-basics/environment
(1)
Front Panel
Block Diagram
Fig. 1. A simple Virtual Instrument which adds two sine waves of different frequencies and
displays the result in a graph
Exercises
a) Implement the VI shown in Fig. 1. Study the different settings (e. g., samples per
second, number of samples) present in “Simulate Signal” VI. Obtain the modulated (i.
e., added) signal in a suitable display in the front panel of the VI.
(2)
(b) Write a VI program to multiply two sine waves (say, qA and qB) of same frequency.
Amplitudes of the sine waves can be assumed to have arbitrary values. Further, obtain the
average value of the multiplied signal using suitable blocks in LabVIEW. Display this value
on a suitable indicator in the front panel. Note this value for different phase differences
between qA and qB.
Assume qA is a voltage signal and qB is current signal across a passive element. Then, which
physical quantity is represented by the quantity displayed in the front panel.
(ii) Learn how to acquire basic signals (sine, triangle) from a function generator to a PC using
LABVIEW and the above DAS kit. Set the frequency of the signals as 100 Hz. Use a DAQ
assistant block (see Fig. 2).
(iii) Also, generate a sine wave of 200 Hz frequency from LABVIEW (i. e., PC) and see the
output signals in an oscilloscope. DAQ assistant block needs to be suitably configured during
these experiments.
(d) Develop a suitable virtual instrument to acquire a sine wave signal of 100 Hz frequency
when a switch pressed. Hint: Use Case structure in LABVIEW, see the figure below
(3)
(e) A passive filter circuit having unknown cut-off frequency (i. e., unknown passive components) is
given to you. The cut-off or centre frequency of the circuit is known to be in the range of
100 Hz - 10 kHz. Write a LabVIEW program to identify the type of filter circuit (Low-
Pass/High-Pass/Band-Pass/Band-Reject). Plot the amplitude response in graph paper.
Estimate the gain, cut-off frequency, and bandwidth of the circuit.
Hint:
1. Give a sinusoidal signal as input to the unknown filter circuit. Acquire the output of the
unknown circuit using the DAQ Assistant VI.
2. Write a code to obtain amplitude of the acquired signal. Change the input signal frequency
from 50 Hz to 20 kHz and note-down/store the signal amplitude (in VI) for different
frequencies. Plot them on semilog graph paper and estimate the required parameters.
(4)