WRn

Name

Write Data Ram Status Character

Function

The content of the accumulator is written into the
RAM status character n of the previously selected RAM register.

Syntax

WR0, WR1, WR2, WR3

Assembled

Binary

11100100, 11100101, 11100110, 11100111,

Decimal

228, 229, 230, 231

Hexadecimal

0xE4, 0xE5, 0xE6, 0xE7

Symbolic

../../_images/wrn-sym.png

Execution

1 word, 8-bit code and an execution time of 10.3 \({\mu}\) sec

Side-effects

Not Applicable

Implemented

wrn

Detailed Description

The contents of the DATA RAM status character whose number from 0 to 3 is specified by n, associated with the DATA RAM register specified by tbe last SRC instruction, are replaced by the contents of the accumulator.

The carry bit and the accumulator are not affected.

The DATA RAM status character is encoded in the opcode as shown below:

../../_images/wrn.png

Example program

The example program will write the value 2 into status character 1 of DATA RAM register 0 of chip 0 of the currently selected DATA RAM bank.

/ Example program
FIM   0P  0
SRC   0P
LDM   2
WR1