Data Types; Constants - AMX NETLINX PROGRAMMING LANGUAGE Manual

Programming language
Table of Contents

Advertisement

NetLinx Programming Overview

Data Types

NetLinx expanded the types of data handled beyond the 8-bit and 16-bit integers handled by Axcess.
NetLinx supports integers up to 32-bits and signed values to allow positive and negative values. The
following table lists the data types available to NetLinx.
Data Types Supported by NetLinx
Type
Names
CHAR
WIDECHAR
INTEGER
SINTEGER
FLOAT
DOUBLE
LONG
SLONG

Constants

The
DEFINE_CONSTANT
The scope of the constant extends throughout the module in which it is defined. If the
DEFINE_CONSTANT
extends globally throughout the program.
DEFINE_CONSTANT Data Formats
Types
Decimal Integer
Hexadecimal Integer $000
Binary Integer
Floating Point
Exponential Notation 0.0e0
Character
String Literal
The standard format for
<constant name> = <constant expression>
10
Used to Store
Single byte values and character
strings
Wide character strings dealing with
Unicode fonts that use 16-bit character
codes (and most Far-eastern fonts)
Default variable value to store values
up to 65,535
Signed integer values both greater
than and less than zero
Small real numbers with 5 digits of
precision
Large real numbers with 15 digits of
precision
Stores large integer values esp.
greater than 65,535
Signed large integer values less than -
32,767 and greater than 32,767
section in NetLinx is similar to the
section appears in the main program or in an include file, the constant's scope
DEFINE_CONSTANT
Formats
Examples
0000
1500
$DE60
000b
01110011b
000.0
924.5
.5e-12
'c' or <char code> 'R' or 255
'ssss'
'Reverse'
DEFINE_CONSTANT
Data Ranges
Sample of Stored Values
0 to 255 (8-bit)
'a', 145, $FE, 'The quick gray fox'
0 to 65,535 (16-bit) "'OFF',500"
0 to 65,535 (16-bit) 512, 32468, 12
32,767 to 32,767
24, -24, 568, -568
(16-bit)
10e-38 to 10e38
1.2345
123.451.2345e5
-16.323.1415
10e-308 to 10e308 1.23456789012345
12,345,678.9012545
3.14159265358979
-0.048512934
0 to 4,294,967,295
1,000,000
(32-bit)
2,000,046
-2,147,483,647 to
-1,000,000
2,147,483,647
1,000,000-2,000,000
(32-bit)
2,000,000
DEFINE_CONSTANTS
accepts data in these formats:
is:
NetLinx Programming Language Reference Guide
section in Axcess.

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Netlinx studio 2

Table of Contents