59
Chapter 3 Functions
3.2 Functions
Bit TeST & Clear
Test bit & clear
[ Flag Change ]
[ Description Example ]
[ Related Instructions ]
BCLR,BSET,BNOT,BNTST,BTST,BTSTS
dest
bit,R0
bit,R1
bit,R2
bit,R3
bit,A0
bit,A1
[A0]
[A1]
base:8[A0]
base:8[A1]
bit,base:8[SB] bit,base:8[FB]
base:16[A0]
base:16[A1]
bit,base:16[SB] bit,base:16
C
bit,base:11[SB]
BTSTC
BTSTC
[ Syntax ]
BTSTC
dest
[ Selectable dest ]
BTSTC
flag
BTSTC
4,Ram
BTSTC
16,Ram:16[SB]
BTSTC
[A0]
[ Operation ]
Z
________
dest
C
dest
dest
0
[ Function ]
U
I
O
B
S
Z
D
C
Conditions
Z :
The flag is set when
dest
is 0; otherwise cleared.
C :
The flag is set when
dest
is 1; otherwise cleared.
• This instruction transfers inverted
dest
to the Z flag and non-inverted
dest
to the C flag. Then it
stores 0 in
dest
.
[ Instruction Code/Number of Cycles ]
Page=159
Flag
Change
Summary of Contents for R8C/Tiny Series
Page 50: ...Chapter 3 Functions 3 1 Guide to This Chapter 3 2 Functions...
Page 151: ...134 Chapter 3 Functions 3 2 Functions Blank for page layout...
Page 278: ...Chapter 6 Calculation Number of Cycles 6 1 Instruction queue buffer...
Page 297: ...R8C Tiny Series Software Manual 2 6 2 Ote machi Chiyoda ku Tokyo 100 0004 Japan...