Search

User Manual

GETTING STARTED


MODULES AND PLATFORM


APPENDIX


TUTORIALS & HELPFUL TRICKS


STRATEGIC PARTNER LINKS

Sepasoft - MES Modules
Cirrus Link - MQTT Modules

RESOURCES

Inductive University
Ignition Demo Project
Knowledge Base Articles
Forum
IA Support
SDK Documentation
SDK Examples

ALL USER MANUAL VERSIONS

Ignition 8.1
Ignition 7.9
Ignition 7.8

Deprecated Pages

Employees

Sign In

Skip to end of metadata
Go to start of metadata

This function is used by Ignition's Expression language.

Description
This function, whose name stands for "binary encoder", takes a list of booleans, and treats them like the bits in a binary number. It returns an integer representing the decimal value of the number. The digits go from least significant to most significant.
Syntax

binEnc(value[, value...])

  • Parameters

Bool value - A value that represents a bit. Can be either 0 or 1, and can enter in as many values as necessary.

  • Results

int - The integer representation of the binary value entered.

Examples
Code Snippet
binEnc(0,0,1,0) //returns 4 (the value of 0100)
Code Snippet
binEnc(true,0,1,1,0) //returns 13 (the value of 01101)
  • No labels