Omron CP1E CPU UNIT SOFTWARE User Manual page 61

Cp1e cpu unit software
Table of Contents

Advertisement

Signed Binary
Data type
Notation
Application
example
Precautions for
correct use
Range 16 bits
32 bits
Unsigned BCD
Data type
Notation
Application
example
Precautions for
correct use
Range 16 bits
32 bits
CP1E CPU Unit Software User's Manual(W480)
Decimal values
Signed + or -
-
10
Decimal value
(integer)
+ or - sign
MOV -10 D0
Stores 10 decimal (#FFF6 hex) in D0.
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 + or - is input from the CX-
Programmer.
Negative: -32768 to -1
Positive: 0 to +32767
Negative: -2147483648 to -1
Positive: 0 to +2147483647
Decimal values
None
None
4 Understanding Programming
Hexadecimal values
With # symbol
#
FFF6
Hexadecimal value
using 0 to F
Hexadecimal symbol
MOV # FFF6 D0
Stores #FFF6 hex (10 decimal) in D0.
• 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.
Negative: #8000 to #FFFF
Positive: #0000 to #7FFF
Negative: #80000000 to #FFFFFFFF
Positive: #00000000 to #7FFFFFFF
BCD values
#
0010
Decimal value using
0 to 9
BCD symbol
+B #0010 D0 D1
Adds #0010 and the contents of D0 as BCD data
and stores the result in D1.
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.
#0000 to #9999
#0000 0000 to #99999999
4
4 - 17

Advertisement

Table of Contents
loading

Table of Contents