21.08.2013 Views

AVR Instruction Set Nomenclature: Status Register (SREG ...

AVR Instruction Set Nomenclature: Status Register (SREG ...

AVR Instruction Set Nomenclature: Status Register (SREG ...

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

BLD - Bit Load from the T Flag in <strong>SREG</strong> to a Bit in <strong>Register</strong>.<br />

Description:<br />

Copies the T flag in the <strong>SREG</strong> (status register) to bit b in register Rd.<br />

Operation:<br />

(i) Rd(b) ← T<br />

Syntax: Operands: Program Counter:<br />

(i) BLD Rd,b 0 ≤ d ≤ 31, 0 ≤ b ≤ 7 PC ← PC + 1<br />

16<br />

16 bit Opcode:<br />

<strong>Status</strong> <strong>Register</strong> (<strong>SREG</strong>) and Boolean Formulae:<br />

Example:<br />

1111 100d dddd 0bbb<br />

I T H S V N Z C<br />

- - - - - - - -<br />

bst r1,2<br />

; Copy bit<br />

; Store bit 2 of r1 in T flag<br />

bld r0,4 ; Load T flag into bit 4 of r0<br />

Words: 1 (2 bytes)<br />

Cycles: 1<br />

<strong>Instruction</strong> <strong>Set</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!