![background image](http://html.mh-extra.com/html/omron/sysmac-cp-series/sysmac-cp-series_user-manual_742262067.webp)
4-23
4 Understanding Programming
CP2E CPU Unit Software User’s Manual(W614)
4-5 Co
nstants
4
4-4-7 I/O Ref
resh Timing
4-5
Constants
Constants are numeric values expressed in 16 or
3
2 bits and can be specified as instruction operands.
The following types of constants are supported.
•
Bit Strings or Numeric Values (Integers)
Decimal values (with & symbol), hexadecimal values (with # symbol), BCD values (with # symbol), or
signed decimal values (with + or - symbol)
•
Operands Specifying Numbers
Decimal Notation (No Symbol)
•
Floating Point (Real Number) Notation
Signed decimal notation (with + or - symbol and decimal point)
z
Using Operands for Bit Strings or Numeric Values (Integers)
Unsigned Binary
Overview
Notation and Ranges
Data type
Decimal values
Hexadecimal values
Notation
With & symbol
With # symbol
Application
example
MOV &10 D0
Stores 10 decimal (#000A hex) in D0.
MOV #000A D0
Stores #000A hex (&10 decimal) in D0.
Precautions for
correct use
•
An error will occur and the left bus bar
will be displayed in red if a hexadecimal
value including A to F is input with &
from the CX-Programmer.
•
The input will be treated as an address
in the CIO Area and the contents of that
address will be specified if a decimal
value without & is input from the CX-
Programmer.
•
An error will occur and the left bus bar will be
displayed in red if a hexadecimal value
including A to F is input without # from the
CX-Programmer.
•
The input will be treated as an address in the
CIO Area and the contents of that address
will be specified if a decimal value without #
is input from the CX-Programmer.
Range
16 bits
&0 to 655
3
5
#0000 to #FFFF
32 bits
&0 to 4294967295
#00000000 to #FFFFFFFF
&
Decimal sym
b
ol
Decimal
v
al
u
e
(integer)
10
#
Hexadecimal sym
b
ol
Hexadecimal
v
al
u
e
u
sing 0 to F
000A
Summary of Contents for SYSMAC CP Series
Page 3: ......
Page 32: ...1 Overview 1 4 CP2E CPU Unit Software User s Manual W614 ...
Page 44: ...3 CPU Unit Operation 3 8 CP2E CPU Unit Software User s Manual W614 ...
Page 116: ...6 I O Allocation 6 8 CP2E CPU Unit Software User s Manual W614 ...
Page 144: ...7 PLC Setup 7 28 CP2E CPU Unit Software User s Manual W614 ...
Page 170: ...10 Interrupts 10 14 CP2E CPU Unit Software User s Manual W614 ...
Page 200: ...11 High speed Counters 11 30 CP2E CPU Unit Software User s Manual W614 ...
Page 272: ...12 Pulse Outputs 12 72 CP2E CPU Unit Software User s Manual W614 ...
Page 278: ...13 PWM Outputs 13 6 CP2E CPU Unit Software User s Manual W614 ...
Page 460: ...18 Programming Device Operations 18 28 CP2E CPU Unit Software User s Manual W614 ...
Page 576: ...Revision 2 CP2E CPU Unit Software User s Manual W614 ...
Page 577: ......