534
Conversion Instructions Section 3-12
â– Example 3: Converting to BCD Data with for an OMRON E6C2-AG5C
Absolute Encoder (Resolution: 360/rotation, Encoder Remainder
Compensation: 76) and Zero Point Offset of 0000 Hex
â– Example 4: Converting to BCD Data with for an OMRON E6C2-AG5C
Absolute Encoder (Resolution: 360/rotation, Encoder Remainder
Compensation: 76) and Zero Point Offset of 000A Hex
3-12-19FOUR-DIGIT NUMBER TO ASCII: STR4(601)
Purpose Converts a 4-digit hexadecimal number (#0000 to #FFFF) to ASCII data (4
characters).
This instruction is supported by CS/CJ-series CPU Units with unit version 4.0
or later only.
0 1
C: D00000
0
00
4 3 7 8111215
0000
C+1: D00001
S: 0010 0001011100000000
0100
D: D00200
0000
D+1: D00201
04C
C+2: D00002
1
Operating mode: Gray binary code conversion
Conversion mode: BCD Mode
Resolution: User-specified
Zero point offset: 0000 hex
User-specified resolution: 360, Encoder remainder compensation: 04C hex (76 decimal)
Gray binary code
Converted and offset.
Result of BCD conversion and offsetting stored.
0 1
C: D00000
0
00
4 3 7 8111215
000A
C+1: D00001
S: 0010 1110011100000000
0100
D: D00200
0000
D+1: D00201
04C
C+2: D00002
1
Operating mode: Gray binary code conversion
Conversion mode: BCD Mode
Resolution: User-specified
Zero point offset: 000A hex
User-specified resolution: 360, Encoder remainder compensation: 04C hex (76 decimal)
Gray binary code
Converted and offset.
Result of BCD conversion and offsetting stored.