![background image](http://html1.mh-extra.com/html/omron/sysmac-cs1d-cpu/sysmac-cs1d-cpu_reference-manual_742268454.webp)
415
Increment/Decrement Instructions
Section 3-10
The Equals Flag will be turned ON if the result is 0000, the Carry Flag will be
turned ON when a digit changes from 0 to F, and the Negative Flag will be
turned ON if bit 15 of Wd is ON in the result.
Both the Carry Flag and the Negative Flag will be turned ON when the content
of Wd changes from 0000 to FFFF.
Flags
Examples
Operation of – –(592)
In the following example, the content of D00100 will be decremented by 1
every cycle as long as CIO 000000 is ON.
Operation of @– –(592)
The up-differentiated variation is used in the following example, so the content
of D00100 will be decremented by 1 only when CIO 000000 has gone from
OFF to ON.
Name
Label
Operation
Error Flag
ER
OFF
Equals Flag
=
ON if the content of Wd is 0000 after execution.
OFF in all other cases.
Carry Flag
CY
ON if a digit in Wd went from 0 to F during execution.
OFF in all other cases.
Negative Flag
N
ON if bit 15 of Wd is ON after execution.
OFF in all other cases.
D00100
D00100
−
1
Decrement Decrement Decrement Decrement
Wd:
Wd:
Decremented every cycle
while CIO 000000 is ON.
: Execution of
− −
(592)
@
− −
D00100
D00100
Decrement
Decrement
−
1
Wd:
Wd:
Decremented only
for up-differentiation.
: Execution of @
− −
(592)
Содержание SYSMAC CS1D-CPU**
Страница 3: ...iv...
Страница 29: ...xxx...
Страница 185: ...146 List of Instructions by Function Code Section 2 4...
Страница 193: ...154 3 35 4 MOVE BIT MOVBC 568 1274 3 35 5 BIT COUNTER BCNTC 621 1276 3 35 6 GET VARIABLE ID GETID 286 1278...
Страница 1389: ...1350 CJ series Instruction Execution Times and Number of Steps Section 4 2...
Страница 1390: ...1351 Appendix A ASCII Code Table ASCII SP Four leftmost bits Four rightmost bits...
Страница 1391: ...1352 ASCII Code Table Appendix A...