Example Code

Binary Clock Example

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: This is a simple example of a Binary Clock written in LabVIEW.


Documentation: This is a simple example of a Binary Clock written in LabView. The example will read the current time from the PCs clock, extract the Hours, Minutes and Seconds and then display them individually in both decimal and binary form.


Requirements: LabVIEW 2012 (or compatible), Hardware: none.


Steps to Implement or Execute Code:

1. Run the VI.
2. Look at the binary bins.


Additional Information or References:

 

Binary Clock Example FP.png

 

Binary Clock Example sn.png

 

This VI makes use of:

  • Get Time/Date in Seconds
  • Format Date/Time String
  • Decimal String to Number
  • Number to Boolean Array
    **This document has been updated to meet the current required format for the NI Code Exchange.**
Jason W.
Applications Engineer
National Instruments UK & Ireland

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