Example Code

Basic Calculator Using LabVIEW

Products and Environment

This section reflects the products and operating system used to create the example.

To download NI software, including the products shown below, visit ni.com/downloads.

    Software

  • LabVIEW

Code and Documents

Attachment

Download All

Overview

A simple calculator that performs the basic mathematical operations.

 

Description

This is a simple calculator that performs basic mathematical operations. It looks and works different than the conventional calulators.

 

Requirements

Software

LabVIEW 2012 (or compatible)

 

Steps to Implement or Execute Code

  1. Open LabVIEW and run the LOLCalci.vi.
  2. First enter any operand into the input box and press enter to load it into the memory.
  3. Click any operator button once and then enter the operand.
  4. Press Enter button to load the operation and operands into the memory.
  5. When you press any operator button, it glows green. If you want any other operation, you can click on the same button again to disable it and select any other operation of your choice. The operator does not load into memory until you press the Enter button.
  6. Press Refresh button to clear all prior operations and do fresh calulations.

Additional Information or Reference

 1-387FD.png

 

1-387BD.png

 

**This document has been updated to meet the current required format for the NI Code Exchange.**

 

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.