stsr


Stores contents of system register.

[Syntax]

-

stsr regID, reg

-

stsr regID, reg, selID

 

The following can be specified as regID and selID:

-

Absolute expression having a value of up to 5 bits

[Function]

 

-

Syntax "stsr regID, reg"

Stores the value of the system registerNote indicated by the system register number specified by the first operand, to the register specified by the second operand.

-

Syntax "stsr regID, reg, selID"

Stores the value of the system registerNote indicated by the system-register number specified in the first operand and the group number specified in the third operand into the register specified in the second operand.

If selID is omitted, it is assumed that selID=0 was specified.

Note

For details of the system registers, see the Relevant Device's Hardware User's Manual provided with the each device.

[Flag]

CY

---

OV

---

S

---

Z

---

SAT

---

[Caution]

-

If an absolute expression having a value exceeding the range of 0 to 31 is specified as regID and selID, the assembler outputs the following message, then continues assembling using the lower 5 bitsNote of the specified value.

 

W0550018 : illegal regID for stsr

Note

The stsr machine instruction takes an immediate value in the range of 0 to 31 (0x0 to 0x1F) as the first operand.