Labview programming basics Tutorial

Labview is the programming language developed by National Instruments (NI). It is widely used in test and measurement industry for various applications such as automation, conformance testing, pre-certification testing and more. It is adopted by industry in various discipline including wireless, telecom, mechanical and electrical domains. National Instrument provides training on Labview at various levels. Various labview certification courses will be available from National Instruments. This labview tutorial covers very basic knowledge on labview programming for beginners. Programs developed under labview environment are named as VI. VI stands for Virtual Instrumentation.

Creating VI:

After installing labview and clicking and opening blank VI following two windows open up.

1. Front panel - It provides user interface functionalities of the design under development using labview. Basically it provides place where one can keep controls and indicators mainly used to provide inputs and take outputs from the VI. This also helps interface Vis together in the bigger system by connecting outputs of one VI with the inputs of the other VI.

2. Block Diagram -This window contains source code in the form of graphical icons and wires/signals.

In addition there is icon and connector pane which helps use VI as sub VI in a larger bigger system. For Example as mentioned below scrambler is used as sub VI in a transmitter of a wimax physical layer. This is similar to subroutine or function as used in text based programming languages (Pascal, c).

Icon of each VI is visible on the top right corner of both the block diagram and front panel windows. One can edit the icon only in front panel window. Each icon contains text, image and both for function representative purpose.

Use Edit Icon to add text and graphics and colors.

Use Show connector feature to add and remove terminal to the icon (i.e. VI). These terminals acts as an input and output terminals and will hence help pass arguments to the VI and take out the arguments from a VI.

Data types supported in Labview

Labview provides colors, styles, and thicknesses depending on data types used as shown in the figures below, so that they can be easily identified by the Labview programmer and help connect appropriate wires between the two VIs.

labview programming tutorial data type
Figure 1 of data type supported in labview

Programming Syntax

Similar to other programming language labview also provides functions for For Loop, While Loop, case structure, Shift register, Array, File I/O, Case Structure, graphs and more. It provides various string related functions. Various functionalities specific to particular domain such as signal processing are also available and provided in labview programming language. One can drag and drop the icon in the block diagram panel and use right click of mouse and help to go in detail of each of the functions. This helps in speed up of programming development.

Example Implementation using Labview

In this section we will see example implementation of scrambler module as mentioned below in the circuit; it takes input seed and data as input and provides scrambled data as output.

scrambler circuit

Implementation of the above scrambler circuit module as per labview programming constructs is depicted below.

scrambler example implementation using labview
Figure 2 Scrambler example implementation using labview

Input data:
4529C479AD0F5528AD87B5761A9C8050451B9FD92
A8895EBAEB52E034F091469580A5D

Input Seed: 3825

Output data:
D4BAA112F274963027D4889C96E3A952B315ABFD
92530732C0 6248F0 1922E0 91621AC1

Interfacing with RFSG and RFSA using drivers

Labview provides driver VIs to interface offline VIs with the RF Vector Signal Generators and RF Vector Signal Analyzers. This makes design convert into real time or online use applications.

Similar posts on Labview programming

Labview data types
Creating SubVI
Creating Array and Array operations
Cluster concepts in labview
Various plots in labview
File I/Os
For loop,while loop and case structure
Local variable vs Global variable concepts

Useful Links to Labview Source codes

Refer following as well as links mentioned on left side panel for useful labview source codes.

Hex to Binary labview VI      Decimal to Binary labview VI
Number Generator labview VI      Binary to Decimal labview VI
Binary number generator     modulator-demodulator
FFT     up and down sample

Cellular Telecommunications Tutorials -
RF Wireless World

WLAN  802.11ac  802.11ad  wimax  Zigbee  z-wave  GSM  LTE  UMTS  Bluetooth  UWB  IoT  satellite  Antenna  RADAR