[go: up one dir, main page]

0% found this document useful (0 votes)
18 views32 pages

Manual - Programming Through LabView Eeee

Programming through labview manual

Uploaded by

saimadhuemandi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
18 views32 pages

Manual - Programming Through LabView Eeee

Programming through labview manual

Uploaded by

saimadhuemandi
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 32

PROGRAMMING THROUGH LABVIEW

(Skill Oriented Course -I)


Course code-20EE11S1

B.Tech III sem, EEE

LAB MANUALS
Version History
Version 1.0
Version 2.0

Faculty:
Dr.K.Srikanth, Mrs.K.Harija Rani, Mrs.K.Hemalalitha
Dr. O V S R Varaprasad, Mrs. A Susmitha, Mrs. V Chandrika
Asst. Professor(s), Dept. of EEE
List of Experiments:
1. Add, multiply, subtract and divide two numeric inputs.

2. Build a front panel/ block diagram for temperature conversion from Celsius to Fahrenheit

3. Perform Boolean operations

4. Create a VI to compute full adder logic using half adder logic as subVI.

5. Create a VI to find the decimal equivalent of a binary number using subVI.

6. Create a VI to evaluate a given circuit for values of current, voltage.

7. Create a VI to animate a bird flying. Use the Picture Ring control to insert and display
pictures to be animated.

8. Create a global VI with a waveform chart and a stop button. Update the waveform chart
using a random number generator

9. Build a VI that displays sine and cosine plots on a waveform chart in sweep update mode.

10. Create a VI to calculate ncr and npr of a given number using a For Loop.

11. Build a VI to find the sum and product of array elements.

12. Create a VI to acquire voltage and current data of DC Machine/ simple electrical network
using DAQ 6341 module

13. Create a VI to format the date and time in the required format using Format Date/Time
String Function. Get the date and time input from Time Stamp Control.

14. Build a VI which finds the number of occurrences of a particular string in an array of
strings.
15.Build a VI to plot a circle in the XY graph using a For Loop.
16. Find the maximum and minimum values of the given sine waveform and the time at
which the waveform is maximum and minimum.
Experiment 1 : Add, multiply, subtract and divide two numeric inputs
1.1 Aim: To perform basic arithmetic operations like addition, subtraction, multiplication and
division using LabVIEW software from National Instruments (NI)

1.2 Software required:

PC installed with NI LabVIEW 2015

1.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

I. Addition of two variables:

1. Functions>>Programming>>Numeric Palette>>Add

2. Place an " Add function " from Numeric palette on block diagram panel by following the
above procedure.

3. Create one constant by Right click at an input terminal>>Create>>Constant.

4. Create another constant by placing one from Numeric Palette

5.Create an indicator at the output terminal of "Add function" by right click at Output
terminal >> Create >>Indicator.

6. Runthe simulation.

Fig 1.1: Block Diagram & Front panel view of two variables addition in LabVIEW
environment
Fig 1.2: Block Diagram & Front panel view of two variables addition with control
inputs in LabVIEW environment

Note: Create control by right click at input terminals of “Add function” >> create >> control

II. Subtraction of two variables:

1. Functions>>Programming>>Numeric Palette>>Subtract.
2. Follow the same steps as detailed in sec I.

Fig 1.3: Block Diagram & Front panel view of two variables subtraction in LabVIEW
environment

Fig 1.4: Block Diagram & Front panel view of two variables subtractionwith control
variables in LabVIEW environment

III. Multiplication of two variables

1. Functions>>Programming>>Numeric Palette>>Multiply
2. Follow the same steps as detailed in sec I.
Fig 1.5:Block Diagram & Front panel view of two variables multiplication in
LabVIEW environment

Fig 1.6:Block Diagram & Front panel view of two variables multiplication with
control inputs in LabVIEW environment

IV. Division of two variables

1. Functions>>Programming>>Numeric Palette>>Divide
2. Follow the same steps as detailed in sec I

Fig 1.7:Block Diagram & Front panel view of two variables Division in
LabVIEW environment

Fig 1.8:Block Diagram & Front panel view of two variables Division with control
inputs in LabVIEW environment

1.4 Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

1.5 Conclusions:

Basic arithmetic operations like addition, subtraction, multiplication and division has been
performed using LabVIEW for both constant and control inputs.

1.6 Viva Questions:

1. Define LabVIEW ?
2. What are the advantages of LabVIEW ?
3. What are the two panels used in LabVIEW programming ?
4. What are the features of LabVIEW ?
5. What is the difference between control and indicators used in LabVIEW
programming ?
6. How LabVIEW is different from other softwares like MATLAB, PSCAD etc.?

1.7 Exercise:

1. Design a G-Code for the given equation and test the result for inputs x = 7, y=3, z= 2

2. Design a G-programming Code to Divide two numbers and find the remainder and
quotient
3. Design a G-programming code to find whether the given number is odd or even.
4. Design a G-programming Code to convert a given number in degree to radians
Experiment 2. Build a front panel/ block diagram for temperature
conversion from Celsius to Fahrenheit
2.1 Aim: To build a front panel/ block diagram for temperature conversion from Celsius to
Fahrenheit

2.2 Software required:

PC installed with NI LabVIEW 2015

2.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

VI design procedure for temperature conversion from oC to oF:

1. Relation between oC and oF is F= 1.8C+32

2. To build VI , take a multiply function from Numeric Palette and place it on block diagram
panel.

3. Create one constant (value is 1.8) by Right click at an input


terminal>>Create>>Constant

4. Create control at other terminal (to input temperature in oC) by Right click at input
terminal>>Create>>Indicator

5. Place add function from Numeric Palette

6.Wire output of multiply function to one input terminal of add function

7.Create constant (value is 32) at other input terminal of add function.

8. Place an indicator to display converted temperature in oF at output terminal of add


function.
Fig 2.1: Block Diagram & Front panel view of temperature conversion from oC to oF

2.4 Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.
2.5 Conclusions:
VI Design for temperature conversion oC to oF has been completed and verified results
theoretically.

2.6 VIVA Questions:

1. What are the differences between waveform chart and waveform graph ?

2. What are the various types of data representataions used in LabVIEW?

3. Explain the features in the front panel toolbar used in programming ?

2.7 Exercise:

1. Design a Block Diagram to convert input in degrees to radians?

2. Design a VI to see the random numbers in the form of wave form graph for 100 no.of
samples ?

3. Design a G-Code to add and multiply more than two numeric inputs ?
Experiment 3: Perform Boolean operations
3.1: Aim: To perform logical operations like AND, OR, NOT, NAND and NOR using
LabVIEW software from National Instruments (NI)

3.2 Software required:

PC installed with NI LabVIEW 2015

3.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

Description on Boolean function palette:

The Boolean palette use the Boolean functions to perform logical operations on single
Boolean values or arrays of Boolean values. In Boolean logic, there are only two values, true
and false, represented by the numbers 1 and 0, respectively. Boolean logic is applied to
digital circuitry through the use of simple logic gates. There are seven of these gates: the
NOT, AND, OR, NAND, NOR, XOR, and XNOR gates.

I. AND operation

1. Functions>>Programming>>Boolean Palette>>And

2. Place an " And function " from Boolean palette on block diagram panel by following the
above procedure.
Fig 3.1: Image to show the location of Boolean palette

3.Create one constant by Right click at an input terminal>>Create>>Constant.

4. Create another constant by placing one from Boolean Palette

5. Create an indicator at the output terminal of "And function" by right click at Output
terminal >> Create >>Indicator.

6. Run the simulation.

Fig 3.1: Block Diagram & Front panel view of AND operation in LabVIEW
environment

Fig 3.2: Block Diagram & Front panel view of AND operation with controlled inputs in
LabVIEW environment
II. OR operation:

1. Functions>>Programming>>Boolean Palette>>Or

2. Follow the same steps as detailed in sec I.

Fig 3.3: Block Diagram & Front panel view of OR operation in LabVIEW environment

Fig 3.4:Block Diagram & Front panel view of OR operation with control inputs in
LabVIEW environment

III. NOT operation:

1. Functions>>Programming>>Boolean Palette>>Not

2. Follow the same steps as detailed in sec I.

Fig 3.5: Block Diagram & Front panel view of Not operation in LabVIEW environment
Fig 3.6:Block Diagram & Front panel view of Not operation with control input in
LabVIEW environment

IV. NAND (Not And) Operation:

1. Functions>>Programming>>Boolean Palette>>Not And

2. Follow the same steps as detailed in sec I.

Fig 3.7: Block Diagram & Front panel view of NAND operation in LabVIEW
environment

Fig 3.8: Block Diagram & Front panel view of NAND operation with control inputs in
LabVIEW environment

VI. NOR opeartion:

1. Functions>>Programming>>Boolean Palette>>Not Or: Follow the same steps as


detailed in sec I.

Fig 3.9: Block Diagram & Front panel view of NOR operation in LabVIEW
environment
Fig 3.10: Block Diagram & Front panel view of NOR operation with control inputs in
LabVIEW environment

3.4 : Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

3.5 : Conclusions:

Boolean operations like AND, OR, NOT, NAND and NOR have been performed using
LabVIEW for both constant and control inputs.

3.6: Viva Questions:

1. What is the role of Compound arithmetic function used in boolean palette ?

2. What are the 3 palettes used in LabVIEW programming?

3. What are the 3 types of switch and latch behaviours used under boolean control palette ?

4. What are the truth tables of AND, OR, NAND and NOR gates?

3.7: Exercise Problems:

1. Compute the expressions Y= (A *B*C) + (D *E) and Y=mx+C

2. Convert a binary number to a decimal number

3. Perform boolean operations XOR and XNOR

4. Design a G-Code for AND, OR, NAND, NOR and NOT operations with two control
inputs?
Experiment 4: Create a VI to compute full adder logic using half adder
logic as subVI.
4.1 Aim: To design a full adder logic using half adder as subVI

4.2 Software required:

PC installed with NI LabVIEW 2015

4.3 Theory:

A combinational circuit that performs the addition of bits is called an Adder. Each computer
has an adder located in its CPU(ALU) that is responsible for the process of addition. There
are two types of Adder. They are also used in other parts of the processor, where they are
used to calculate addresses, table indices, increment and decrement operators, and similar
operations.

• Half Adder
• Full Adder
4.4 Procedure: Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 2015

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

VI design procedure for Half Adder:

1. Functions>>Programming>>Boolean Palette>> Exclusive Or

2. Functions>>Programming>>Boolean Palette>> And

3. Create control inputs x,y and place two indicators at output terminals of Exclusive Or ,
And functions for sum, carry outputs respectively.

4. Run VI and verify result with help of truth table


Fig 4.1: Block Diagram & Front panel view of Half adder

Procedure to create subVI:

1. Select the designed VI on block diagram panel of Half adder

2. Go to Edit >> Create subVI

VI to compute full adder logic using half adder logic as subVI:

1. Place half adder subVI on Block Diagram panel

2. Make connections as shown in Fig 4.2

3. Run VI and test results with truth table.

Fig 4.2: Block Diagram & Front panel view of Full adder with Half adder as subVI

4.5 : Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

4.6 : Conclusions:

Design of Full adder logic with half adder as subVI have been performed using LabVIEW.
4.7 : VIVA Questions:

1. Explain the truth table of Half adder logic?

2. What are the applications of Half adder and full adder?

3. Explain the difference between Half adder and Full adder?

4. Draw the truth table of Full adder?

5. Define subVI in LabVIEW

4.8: Exercise:

1. Design a VI to find the roots of a quadratic equation?

2. Create a VI to find the average of two numbers and convert a section of VI into subVI?

3. Build a subVI to convert radians to degrees?


Experiment 5: Create a VI to find the decimal equivalent of a binary
number using subVI.
5.1 Aim: Create a VI to find the decimal equivalent of a binary number using subVI.

5.2 Software required:

PC installed with NI LabVIEW 2015

5.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

5.4 Implementation:
To find the decimal equivalent of a binary number, first create the front panel and the
block diagram as given in Figures (a) and (b).
Then create the subVI called “Binary to decimal” and use it in the main VI as shown in
Figures (c) and (d).
5.5 : Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

5.5 : Result: The VI to find the decimal equivalent of a binary number using subVI as per the
requirements has been developed.

References:
• Jerome, Jovitha. Virtual Instrumentation Using LabVIEW . PHI Learning. Kindle
Edition.
Experiment 6: Create a VI to evaluate a given circuit for values of current,
voltage.
6.1 Aim: Create a VI to evaluate a given circuit for values of current, voltage

6.2 Software required: PC installed with NI LabVIEW 2015

6.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

6.4 Implementation:
To create a VI to evaluate a given circuit for values of current, voltage, first create the
front panel and the block diagram as given in Figures (a) and (b).

Fig. (a) Front panel vi Fig. (b) Block Diagram vi

6.5 : Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

6.6 : Result: The VI to evaluate a given circuit for values of current, voltage as per the
requirements has been developed.
Experiment 7: Create a VI to animate a bird flying. Use the Picture Ring
control to insert and display pictures to be animated.
7.1 Aim: Create a VI to animate a bird flying using the Picture Ring control to insert and
display pictures to be animated.
7.2 Software required:
PC installed with NI LabVIEW 2015
7.3 Procedure:
Procedure to open new VI in LabVIEW:
1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**
2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.
3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.
4. Collect the bird flying sequence pictures to animate.
5. In the front panel, Controls >> Ring & Enum >> Pict Ring. Import the collected bird flying
sequence pictures one by one to the clip board from edit section. Import the pictures one by
one from clip board to the Pict Ring.
6. Open the Pict Ring in block diagram and place it inside the while loop and create a stop
control for the while loop.
7. In the block diagram select, Function >> Programming >> Numeric >> Quotient &
Remainder. Place the Quotient & Remainder inside the while loop and connect the iteration
“i” of the while loop to input 1 and insert the constant “No of bird flying sequence pictures”.
8. Connect the output of the Quotient & Remainder to the Pict Ring in the block diagram.
9. In the block diagram select, Function >> Programming >> Timing >> wait (ms). Connect a
control knob to wait (ms) in the front panel and set the wait from 100 to 200 ms.
10. Run the VI and check the animation of a bird flying using the Picture Ring control.
7.4 Implementation:

Create a VI to animate a bird flying using the Picture Ring control to insert and display
pictures to be animated, first create the front panel and the block diagram as given in Figures
12 (a) and (b).
Fig. (a) Front panel vi Fig. (b) Block Diagram vi
7.5 : Precautions:
1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.
7.6 : Result: The VI to animate a bird flying using the Picture Ring control to insert and
display pictures to be animated has been developed.
Experiment-8: Create a global VI with a waveform chart and a stop
button. Update the waveform chart using a random number generator
8.1 Aim: Create a global VI with a waveform chart and a stop button. Update the waveform
chart using a random number generator

8.2 Software required: PC installed with NI LabVIEW 2015

8.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

8.4 Implementation:
To create a global VI with a waveform chart and a stop button and to update the waveform
chart using a random number generator, first create the front panel and the block diagram as
given in Figures (a) and (b).

Fig. (a) Front panel vi Fig. (b) Block Diagram vi

8.5 : Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

8.6 : Result: The global VI with a waveform chart and a stop button as per the requirements
has been developed.
Experiment 11: Build a VI to find the sum and product of array elements
11.1 Aim: Build a VI to find the sum and product of array elements.

11.2 Software required:

PC installed with NI LabVIEW 2015

11.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

11.4 Implementation:

To find the sum and product of array elements, first create the front panel and the
block diagram as given in Figures (a) and (b).

Fig. (a) Front panel vi Fig. (b) Block Diagram vi

11.5 : Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

11.6 : Result: The VI to find the sum and product of array elements as per the requirements
has been developed.

References:
• Jerome, Jovitha. Virtual Instrumentation Using LabVIEW . PHI Learning. Kindle
Edition.
Experiment 12: Create a VI to acquire voltage and current data of DC
Machine/ simple electrical network using DAQ 6341 module
12.1 Aim: Create a VI to acquire voltage, current and power data in a 1-phase AC source
feeding resistive load using DAQ 6341 module

12.2 Procedure wrt test bench

1. Make connections on test bench for a circuit of a 1-phase AC source feeding resistive
load, such that the load voltage, load current, input power are measured using the
transducers on the test bench.
2. Connect the BNC terminals corresponding to all the transducers to BNC analog input
terminals of DAQ. (use any terminals among analog inputs: 1-13).
3. After building the VI in LabVIEW (Refer ‘Procedure wrt DAQ’ below), give 3-
phase supply to the test bench being worked on.
4. Make sure that autotransformer is not in bypass mode and that the variac is at a
position corresponding to minimum voltage.
5. Verify that the load switch is at position ‘0’.
6. Switch on the AC breaker, followed by closing the 415 V “AC isolator”.
7. Increase the input supply voltage gradually by varying the variac position of the
autotransformer.
8. Change the position of “load switch” from position ‘0’ to position ‘1’.
9. Run the VI corresponding to the experiment in the PC and observe the waveforms of
voltages, currents and power.
10. Verify the readings shown on the front panel with those of the digital meters of test
bench.
11. Tabulate the readings as shown the Table below.

12.3 Procedure wrt DAQ

1. Switch on the power supply to DAQ.


2. Open a new VI in LabVIEW and place a DAQ Assistant on the block diagram. DAQ
6341 gets detected, after which select the analog input terminals which are connected
on the test bench.
3. Configure the analog input terminals connection (as RSE mode), acquisition mode (as
continuous mode) and enter sampling details.
4. Split the signals acquired from DAQ and multiply each one of them with suitable
multiplication factors (M.F.s) (M.F.s for voltage, current, power (1-phase) are 80,
1.5, 120 respectively)
5. Place graphical indicators at the outputs of multipliers wherever waveforms are to be
viewed.
6. To calculate RMS values of required voltage and currents, connect the outputs of
multipliers to input of ‘Amplitude and Level Measurement’ block (from ‘Signal
Processing’ palette) and place numeric indicators at the output terminal named ‘RMS’
of the ‘Amplitude and Level Measurement’ block.
7. Save the VI.
8. A sample VI built for this experiment is shown in Figure.

Fig. (a) Sample VI for measurement of a voltage, current, power : Block Diagram
Fig. (b) Sample VI for measurement of a voltage, current, power: Front Panel

Table
S.No. Load Input Power (kW) Load Voltage (V) Load Current
Position
Digital DAQ Digital DAQ Digital DAQ
Meter Reading Meter Reading Meter Reading
Reading Reading Reading

12.4 Conclusions
Digital measurement of Voltage, current, power in a 1-phase AC source feeding
resistive load have been measured using PC-NI DAQ 6341 hardware and LabVIEW
software
Experiment-13: Create a VI to format the date and time in the required
format using Format Date/Time String Function. Get the date and time
input from Time Stamp Control.

13.1 Aim: Create a VI to format the date and time in the required format using Format
Date/Time String Function. Get the date and time input from Time Stamp Control.

13.2 Software required:

PC installed with NI LabVIEW 2015

13.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

4. Programming >> Timing >> Format Date/Time string function.

5. Add the input controls for Time format string, Time stamp and add indicator to the output
of Format Date/Time string function block.

6. In the Time stamp on the front panel, give the present date and time.

7. Give the required format for date and time in time format string on the front panel.

The default format is: %m / %d / %Y %H: %M: %S. To include the milliseconds,
append %3u to the end of the string: %m / %d / %Y %H: %M: %S %3u.

8. Run the VI and check the result of date and time in the required format in the indicator.

13.4 Implementation:

To create a VI to format the date and time in the required format using Format Date/Time
String Function, first create the front panel and the block diagram as given in Figures (a)
and (b).
Fig. (a) Front panel vi Fig. (b) Block Diagram vi

13.5: Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

13.6: Result:

The VI to format the date and time in the required format using Format Date/Time String
Function as per the requirements has been developed.

References:
• Jerome, Jovitha. Virtual Instrumentation Using LabVIEW . PHI Learning. Kindle
Edition.
Experiment- 15: Build a VI to plot a circle in the XY graph using a For
Loop.
15.1 Aim: Build a VI to plot a circle in the XY graph using a For Loop.

15.2 Software required:

PC installed with NI LabVIEW 2015

15.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

15.4 Implementation:

To Build a VI to plot a circle in the XY graph using a For Loop, first create the front panel
and the block diagram as given in Figures (a) and (b).

Fig. (a) Front panel vi Fig. (b) Block Diagram vi


15.5 : Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

15.6 : Result: The VI to plot a circle in the XY graph using a for loop as per the requirements
has been developed.

References:
• Jerome, Jovitha. Virtual Instrumentation Using LabVIEW . PHI Learning. Kindle
Edition.
Experiment-16: Find the maximum and minimum values of the given sine
waveform and the time at which the waveform is maximum and minimum.
16.1 Aim: Create a VI to find the maximum and minimum values of the given sine waveform
and the time at which the waveform is maximum and minimum.

16.2 Software required:

PC installed with NI LabVIEW 2015

16.3 Procedure:

Procedure to open new VI in LabVIEW:

1. Navigate to Start» All Programs » National Instruments » LabVIEW 20**

2. After launching LabVIEW, go to file (under menu bar) then select New VI or use shortcut
key ctrl+N.

3. Front panel and block diagram panels will pop up. Save the VI at preferred location in the
PC.

4. Programming >> Waveform >> Analog Waveform >> Waveform Generation >> Sine
Waveform.

5. Right click on the Sine waveform Block and disable the ‘View as Icon’ so that all the input
and output terminals of the Sine block will be visible.

6. Next insert the Min & Max block in the similar way as before and connect to the Signal
output terminal of Sine waveform Block.

7. Then add the required Controls to Sine waveform Block, required Indicators to Min &
Max block and a Waveform Graph as shown in the block diagram.

8. Run the VI and observe the sine waveform for different phase and frequency values. Also
observe the Maximum and minimum amplitude values of generated sine waveform and
corresponding time at which these maximum and minimum values occur.

16.4 Implementation:

To create a VI to find the maximum and minimum values of the given sine waveform and
the time at which the waveform is maximum and minimum, first create the front panel and
the block diagram as given in Figures (a) and (b).
Fig. (a) Front panel vi Fig. (b) Block Diagram vi

16.5 : Precautions:

1. Ensure that all the functions used in block diagram panel are wired properly.
2. Save the design with proper name in prefered location of PC.

16.6 : Result: The VI to find the maximum and minimum values of the given sine waveform
and the time at which the waveform is maximum and minimum as per the requirements has
been developed.

You might also like