Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Introduction to LabVIEW, Lab Reports of Analog Communication

This lab introduces LabVIEW software. Familiarise the students with the following concepts: Basic Introduction to LabVIEW • Front Panel • Block Diagram • Construct a VI • Programming Structures (If/Else, For Loop)

Typology: Lab Reports

2021/2022

Uploaded on 12/17/2022

rana-ahmed-3
rana-ahmed-3 🇵🇰

3 documents

1 / 10

Toggle sidebar

Related documents


Partial preview of the text

Download Introduction to LabVIEW and more Lab Reports Analog Communication in PDF only on Docsity! LAB# 05 Introduction to LAbView EEE351-Principles of Communication Systems Lab Report # 03 Name RANA MUHAMMAD AHMED Registration Number FA19-BEE-180/ISB Class/Section BEE-5D Instructor’s Name SIR KHAN ASFAR Lab Assessment Pre Lab /1 /10 In Lab /5 Critical Analysis /4 LAB# 05 Introduction to LabVIEW Objectives This lab introduces LabVIEW software. Familiarise the students with the following concepts: Basic Introduction to LabVIEW • Front Panel • Block Diagram • Construct a VI • Programming Structures (If/Else, For Loop) 1. LabVIEW Overview: 1.1. What is LabVIEW: ➢ LabVIEW(Laboratory Virtual Instrument Engineering Workbench), is a graphical programming language that uses icons instead of lines of text to create applications. ➢ LabVIEW programs/codes are called Virtual Instruments, or VIs for short. ➢ LabVIEW is used for Data acquisition, signal Processing (Analysis), and hardware control–a typical instrument configuration based on Labview. 2. Schematic diagram of an instrument system based on LabVIEW Figure 1.1 3. Virtual Instruments (VI) A VI consists of 3.1. Front Panel: Top-level (user) interface User interface to the code (as shown in figure 1.2) ➢ Controls (Input): Boolean controls, Numerical controls, etc. ➢ Indicators (Output): Graphs, Charts, Numerical indicators, etc. 6. Functions Palette The Functions Palette consists of many sub-palette that contain almost all available objects that can be used to create the block diagram. It contains functions as well as many VIs or Sub-VIs that ship with LabVIEW. Function Palette is available at View menu in the Block Diagram Window. 7. Programming Structures 7.1. If/else LabVIEW (like C or Matlab) supports the following structures: ➢ If / Else ➢ For loop ➢ While loop These can be found in ‘Structures’ in the Programming Palette, by right clicking on the Block Diagram. LabVIEW is graphical, so code of the form below is written graphically if{condition = true} {Program for true condition} else (if{condition = false}) {Program for false condition} Basic Steps ➢ Use a comparison to produce a true or false, then wire that result to the Case Structure ➢ Place code in both the True and False parts of the case structure selected at the top of the structure ➢ When the code runs, a true boolean value will run the True case, while a false will run the False case 7.2. For Loop ‘For loop’ in LabVIEW is the same as in other languages ➢ Each for loop has a ‘Loop Count’ input to the loop and a ‘Loop Iteration’ output inside the loop ➢ Simply wire up the number of loops you require to Loop Count and put appropriate code inside loop Task 01: Construct a VI to add two numbers. a=x+y Procedure: 1. Start >> LabVIEW >> Blank VI (from ‘Getting Started’ screen 2. On the Front Panel, add two ‘Numeric Controls’ (inputs) and one ‘Numeric Indicator’ (output) 3. Name them ‘x’, ‘y’ and ‘x+y’ 4. Switch to the Block Diagram – note the inputs and outputs (same names as Front Panel) 5. Right-click on the Block Diagram and choose ‘Add’ under Numeric Palette – drag and drop on the Block Diagram 6. Connect the inputs and outputs using the mouse for wiring 7. Save the VI as Add2_Nos.vi 8. Modify the icon (top right corner) by right clicking on the icon and choosing ‘Edit icon’ 9. After editing the icon, right click on the icon again and choose ‘Show connector’ and connect the inputs and output appropriately. 10. The final VI should look like this 11. To run the VI ➢ enter x and y values in the Front Panel ➢ Click the icon in the top left corner of the Front Panel Task 02: Input a numerical data from the Front Panel (numerical control) and display the result b (Numerical Indicator) after multiplication: b = constant ⋅a. Procedure: 1. Find and drag the Numerical Control and Numerical Indicator respectively, to the from Panel: View –Controls Palette –Modern –Numeric –Numerical Control /Numerical Indicator 2. Find and drag Multiply an Numerical Constant, respectively, into the Background Diagram: View –Functions Palette –Programming -Numeric – Multiply/Numerical Constant
Docsity logo



Copyright © 2024 Ladybird Srl - Via Leonardo da Vinci 16, 10126, Torino, Italy - VAT 10816460017 - All rights reserved