2-217
2 Instructions
CP1E CPU Unit Instructions Reference Manual(W483)
Logic Instructions
2
COM/COML
Sample program
When CIO 0.00 is ON in the following example, the status of each bit D100 will be reversed.
When CIO 0.00 is ON in the following example, the status of each bit in D100 and D101 will be
reversed.
D100
1001000100010001
012345678915 14 13 12 11 10
D100
0
1 1 0 1 1 1 0 1 1 1 0 1 1 1 0
012345678915 14 13 12 11 10
COM
D100
0.00
COML
D100
0.00
D100
1
0 0 1 0 0 0 1 0 0 0 1 0 0 0 1
012345678915 14 13 12 11 10
D100
0
1 1 0 1 1 1 0 1 1 1 0 1 1 1 0
012345678915 14 13 12 11 10
1 0 0 1 0 0 0 1 0 0 0 1 0 0 0 1
012345678915 14 13 12 11 10
0 1 1 0 1 1 1 0 1 1 1 0 1 1 1 0
012345678915 14 13 12 11 10