25

LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

Embed Size (px)

Citation preview

Page 1: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View
Page 2: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

LabVIEW – 2 WindowsLabVIEW – 2 Windows

►Front Panel- User InterfaceFront Panel- User Interface

►Block Diagram- Programming Block Diagram- Programming ViewView

Page 3: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View
Page 4: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

Front Panel – User InterfaceFront Panel – User Interface

►User can type in valuesUser can type in values►User can flip a switchUser can flip a switch► Instruments can record values such asInstruments can record values such as

TemperatureTemperature Heart RateHeart Rate Wave FormsWave Forms

Page 5: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View
Page 6: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

Block Diagram Block Diagram

►IconsIcons on the Block Diagram represent on the Block Diagram represent examples of examples of programming codeprogramming code

Page 7: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View
Page 8: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

Block DiagramBlock Diagram

Page 9: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

What do we mean by What do we mean by Programming Code?Programming Code?

►Let’s look at two examplesLet’s look at two examples Binary CodeBinary Code HTML CodeHTML Code

Page 10: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

Binary CodeBinary Code

►Code using two numbers 0 1Code using two numbers 0 1

►Click below for a Binary Code Click below for a Binary Code Encoder:Encoder:

Binary Code EncoderBinary Code Encoder

Page 11: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

Example of HTML Code Example of HTML Code

The following is an example of Marquee The following is an example of Marquee HTML Code for a website.HTML Code for a website.

►The Code causes the text to scroll The Code causes the text to scroll across the screenacross the screen

►The Code is hidden from the userThe Code is hidden from the user

►Code ExampleCode Example

Page 12: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

HTML Code RevealedHTML Code Revealed

Page 13: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

LabVIEW Programming CodeLabVIEW Programming Code

►Block Diagrams in LabVIEW represent Block Diagrams in LabVIEW represent the hidden programming codethe hidden programming code

Page 14: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View
Page 15: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

LabVIEW-LabVIEW-A Simple ExampleA Simple Example

►Let’s see both front panel and block Let’s see both front panel and block diagram for calculating the:diagram for calculating the: Area of a TriangleArea of a Triangle

Page 16: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

Formula for Area of Triangle?Formula for Area of Triangle?

Page 17: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

Formula for Area of Triangle?Formula for Area of Triangle?

► .5 x base x height.5 x base x height► .5* b*h.5* b*h

Page 18: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View
Page 19: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

Wires transfer data among Wires transfer data among block diagram objectsblock diagram objects

Page 20: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

WiresWires

Page 21: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

LoopsLoops

►Loops can continue a cycle of input or Loops can continue a cycle of input or can cause input to stopcan cause input to stop

Page 22: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View

WHILE LoopWHILE Loop

► To run the VI until a condition occurs, To run the VI until a condition occurs, you can use a While Loopyou can use a While Loop

Page 23: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View
Page 24: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View
Page 25: LabVIEW – 2 Windows ► Front Panel- User Interface ► Block Diagram- Programming View