Exercise 1 – Convert C to F Build a VI Complete the following steps to create a VI that takes a number representing degrees Celsius and converts it to a number representing degrees Fahrenheit.
In wiring illustrations, the arrow at the end of this mouse icon shows where to click and the number on the arrow indicates how many times to click.
Select File»New to open a new front panel.
(Optional) Select Window»Tile Left and Right to display the front panel and block diagram side by side.
Create a numeric digital control. You will use this control to enter the value for degrees Centigrade.
Move the control to the front panel and click to place the control.
Type deg C inside the label and click outside the label or click the Enter button on the toolbar. If you do not type the name immediately, LabVIEW uses a default label. You can edit a label at any time by using the Labeling tool.
Create a numeric digital indicator. You will use this indicator to display the value for degrees Fahrenheit.
Select the digital indicator on the Controls»Numeric Indicators palette.
Move the indicator to the front panel and click to place the indicator.
Type deg F inside the label and click outside the label or click the Enter button.
LabVIEW creates corresponding control and indicator terminals on the block diagram. The terminals represent the data type of the control or indicator. For example, a DBL terminal represents a double-precision, floating-point numeric control or indicator.
Note Control terminals have a thicker border than indicator terminals.
Note: Block Diagram terminals can be viewed as icons or as terminals. To change the way LabVIEW displays these objects right click on a terminal and select View As Icon.
Select the Multiply and Add functions on the Functions»Numeric palette and place them on the block diagram. If the Functions palette is not visible, right-click an open area on the block diagram to display it.
Select the numeric constant on the Functions»Numeric palette and place two of them on the block diagram. When you first place the numeric constant, it is highlighted so you can type a value.
You can bend a wire by clicking to tack the wire down and moving the cursor in a perpendicular direction. Press the spacebar to toggle the wire direction.
To identify terminals on the nodes, right-click the Multiply and Add functions and select Visible Items»Terminals from the shortcut menu to display the connector pane. Return to the icons after wiring by right-clicking the functions and selecting Visible Items»
Terminals from the shortcut menu to remove the checkmark.