RR r

Operation

n--------------m
|  n---------m |  n--m
v->|7------>0|-T->|CY|
   v---------u    v--u
        r

Mnemonic

RR

Operands

r

b7b6b5b4b3b2b1b0
1 1 0 0 1 0 1 1$CB
0 0 0 0 1 r

Description

The contents of register r are rotated right 1 bit position through the Carry flag. The contents of bit 0 are copied to the Carry flag and the previous contents of the Carry flag are copied to bit 7. In the assembled object code, operand r is specified as follows:

RegisterrHex
A111$0F
B000$08
C001$09
D010$0A
E011$0B
H100$0C
L101$0D

Condition Bits Affected

Sis set if result is negative, otherwise it is reset.
Zis set if result is 0, otherwise it is reset.
His reset.
P/Vis set if parity even, otherwise it is reset
Nis reset.
Cis data from bit 0 of source register.

Example

Register D and the Carry flag contains the following data:

76543210C
110111010

Upon the execution of

	RR	D

register D and the Carry Flag now contain:

76543210C
011011101