B/--Bl - Omron SYSMAC CP Series Instruction & Reference Manual

Cpu unit
Hide thumbs Also See for SYSMAC CP Series:
Table of Contents

Advertisement

2 Instructions

--B/--BL

Instruction
DECREMENT BCD
DOUBLE DECREMENT BCD
Symbol
Applicable Program Areas
Area
Usage
Operands
Operand
--B: Word
Wd
--BL: First word
Operand Specifications
Area
CIO
WR
Wd
OK
OK
Flags
Name
Error Flag
Equals Flag
Carry Flag
Function
--B
The --B(596) instruction subtracts 1 from the BCD
content of Wd. The specified word will be decre-
mented by 1 every cycle as long as the execution
condition of --B(596) is ON. When the up-differenti-
ated variation of this instruction (@--B(596)) is used,
the specified word is decremented only when the exe-
cution condition has gone from OFF to ON.
--BL
The --BL(597) instruction subtracts 1 from the 8-digit
BCD content of Wd+1 and Wd. The content of the
specified words will be decremented by 1 every cycle
as long as the execution condition of --BL(597) is ON.
When the up-differentiated variation of this instruction
(@--BL(597)) is used, the content of the specified
words is decremented only when the execution condi-
tion has gone from OFF to ON.
2-156
Mnemonic
Variations
--B
@--B
--BL
@--BL
--B
--B(596)
Wd: Word
Wd
Step program areas
OK
Description
Word addresses
HR
AR
T
C
OK
OK
OK
OK
Label
P_ER
• ON if the content of Wd/Wd+1 and Wd is not BCD.
• OFF in all other cases.
P_EQ
• ON if the result is 0000/0000 0000 after execution.
• OFF in all other cases.
P_CY
• ON if a digit in Wd/Wd+1 or Wd went from 0 to 9 during execution.
• OFF in all other cases.
Function
code
Decrements the 4-digit BCD content of the speci-
596
fied word by 1.
Decrements the 8-digit BCD content of the speci-
597
fied words by 1.
Subroutines
OK
Data type
--
WORD
DWORD
Indirect DM addresses
DM
@DM
*DM
OK
OK
OK
Operation
Wd
-1
Wd+1
Wd
CP1E CPU Unit Instructions Reference Manual(W483)
Function
--BL
--BL(597)
Wd: First word
Wd
Interrupt tasks
OK
Size
--L
--
--L
1
Pulse
Constants
CF
bits
---
---
---
Wd
-1
Wd+1
2
TR
bits
---
Wd

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents