
Core CPU Manual
MF297-07a

No part of this material may be reproduced or duplicated in any form or by any means without the written permission of Seiko Epson. Seiko Epson reserves the right to make changes to this material without notice. Seiko Epson does not assume any liability of any kind arising out of any inaccuracies contained in this material or due to its application or use in any product or circuit and, further, there is no representation that this material is applicable to products requiring high level reliability, such as medical products. Moreover, no license to any intellectual property rights is granted by implication or otherwise, and there is no representation or warranty that anything made in accordance with this material will be free from any patent or copyright infringement of a third party. This material or portions thereof may contain technology or the subject relating to strategic products under the control of the Foreign Exchange and Foreign Trade Law of Japan and may require an export license from the Ministry of International Trade and Industry or other approval from another government agency.
© SEIKO EPSON CORPORATION 2001, All rights reserved.

S1 C 60N01 F 0A01
Packing specifications 00 : Besides tape & reel 0A : TCP BL 2 directions 0B : Tape & reel BACK 0C : TCP BR 2 directions 0D : TCP BT 2 directions 0E : TCP BD 2 directions 0F : Tape & reel FRONT 0G : TCP BT 4 directions 0H : TCP BD 4 directions 0J : TCP SL 2 directions 0K : TCP SR 2 directions 0L : Tape & reel LEFT 0M : TCP ST 2 directions 0N : TCP SD 2 directions 0P : TCP ST 4 directions 0Q : TCP SD 4 directions 0R : Tape & reel RIGHT 99 : Specs not fixed
S5U1 C 60R08 D1 1
Tool type Hx : ICE Ex : EVA board Px : Peripheral board Wx : Flash ROM writer for the microcomputer Xx : ROM writer peripheral board
Cx : C compiler package Ax : Assembler package Dx : Utility tool by the model Qx : Soft simulator






The S1C6200/6200A is the Core CPU of the S1C62 Family of CMOS 4-bit single-chip microcomput- ers. The CPU features a highly-integrated architecture. Memory-mapped peripheral circuits can include RAM, ROM, I/O ports, interrupt controllers, timers and LCD drivers, depending upon the application.
The memory address space is divided into program and data memory, each with data and address lines. Program memory consists of on-chip ROM, containing instructions to be executed by the CPU. Data memory consists of RAM and memory-mapped I/O, as determined by the design of the peripheral cir- cuitry.
A large memory as well as instructions capable of 8-bit data manipulation enhance the functionality of the S1C62 Family. Implementation of a common Core CPU ensures that a wide range of application-specific devices can be designed and fabricated with the minimum turnaround time.
There are some differences in the following operation/circuit between the S1C6200 and the S1C6200A. For the detailes of each difference, refer to the section enclosed with parentheses.
– Interrupt timing (refer to Section 2.5.3, "Operation during interrupt generation".) – Writing to interrupt mask registers and reading of interrupt flags (refer to Appendix A, "S1C6200A (Advanced S1C6200) Core CPU".)
efficient code · and rotation

Data Memory RAM, Peripheral I/O (4,096 4-bit words max.)
YP (4)
8-bit address bus 13-bit address bus
YHL (8)
XHL (8)
A (4)
B (4)
TEMPB (5)
TEMPA (5)
ALU
I D Z C
S1C6200 CORE CPU
Program Memory
ROM (8,192 12-bit words max.)
Fig. 1.1 Block diagram

2 M EMORY AND O PERATIONS
A single-chip microcomputer using the S1C6200/6200A Core CPU has four major blocks: the program memory (ROM), the data memory (RAM and I/O), the arithmetic logic unit (ALU) and the timing generator circuit. This section describes each of these blocks in detail.
Program memory contains the instructions that the CPU executes. Figure 2.1.1 shows the configuration of the program memory.
Each instruction is a 12-bit word. Program memory can also be used for data tables for the table look-up instructions.
There are two banks of program memory. Each bank is subdivided into 16 pages of 256 words (or steps). That is:
Program memory = 2 banks
= 8,192 steps 1 bank = 4,096 steps = 16 pages 1 page = 256 steps 1 step = 1 word = 12 bits
Certain addresses in ROM have specific functions, as shown in Table 2.1.1.
Table 2.1.1 Allocated program memory
Page 1 Reset vector
Step 0 Step 1
vectors for Bank 0
Step 254 Step 255
Step 0 Step 1
Step 254 Step 255
Program or data code area
Program or data code or CALZ subloutines in Bank 0
Program or data code or CALZ subloutines in Bank 1
Fig. 2.1.1 Program memory configuration

2.1.1 Program counter block
The program counter is used to point to the next instruction step to be executed by the CPU. See Figure 2.1.1.1.
The program counter has the following registers.
Table 2.1.1.1 Program counter registers
(8,192 12-bit words max.)
PCP
PCS
NBP
NPP
Fig. 2.1.1.1 Program counter configuration
PCB, PCP and PCS together from a 13-bit counter which can address any location in program memory.
PCP and PCS together from a 12-bit counter which can address any location within a given bank of pro- gram memory. Each time an instruction other than a jump is executed, this counter increments by one. Thus, a jump instruction does not need to be executed between the last step of one page and the first step of the next.
The contents of NBP and NPP are loaded into PCB and PCP each time an instruction is executed. On reset, NBP and NPP are loaded with the same values as PCB and PCP.
The following flags are provided.
Table 2.1.2.1 Flags

2.1.3 Jump instructions
A jump can be made using the instructions in Table 2.1.3.1.
Table 2.1.3.1 Jump instructions
The differences between jumps within the same page and jumps from one page to another is as follows.
A jump can be made within the same page using any of the following instructions:
JP, JP C, JP Z, JP NZ, JPBA or CALL
The destination address is specified by the 8-bit operand. A label can be used to specify a destination address with the S1C62 Family cross assembler.
The destination bank and page should be set using PSET before executing a JP instruction.
PSET loads the four low-order bits (page part) of its 5-bit operand to NPP (new page pointer) and loads the high-order bit (bank part) to NBP (new bank pointer). Executing a JP instruction immediately after PSET causes a jump to the bank specified by NBP, the page specified by NPP and the step specified by the JP instruction operand. See Figure 2.1.4.1.
Page 15 Bank 0
Jump with PSET can go anywhere within the program memory
Step 0 Step 1
Jump can go between banks
Page 3 Bank 0
Page 2 Bank 0
Page 1 Bank 0
Step 254 Step 255
Page 0 Bank 0
Page 15 Bank 1 Bank 1
Step 0 Step 1
Step 0 Step 1
Page 3 Bank 1
Step 254 Step 255
Page 2 Bank 1
Page 1 Bank 1
Step 254 Step 255
Page 0 Bank 1
Step 0 Step 1
Jump without PSET can go anywhere within one page
Step 254 Step 255
Fig. 2.1.4.1 The PSET and jump instructions
As only the page data specified by NPP is loaded to PCP when a call instruction is executed, subroutine calls between banks are not possible. Jumps between banks can only be made using JP instructions.
Bank 0 · Page 14 · Page 14

2.1.6 PSET instruction
Jump or call instructions must follow PSET immediately in order for PSET to affect the destination address. When a jump or call is not immediately preceded by PSET, the destination address is within the current page.
Some examples using PSET are shown in Table 2.1.6.1.
Table 2.1.6.1 PSET examples
CALZ is a direct subroutine call instruction. It calls a subroutine, in page 0 of the current bank, from any page without requiring the use of PSET.
If CALZ is executed immediately after PSET, the bank and page set by PSET is canceled. This allows direct subroutine calls to page 0, minimizing repeated code and unnecessary use of PSET. See Figure 2.1.7.1.
EEE
Bank 0 Page 2
PSET
0AH
Not effect on destination of CALZ
EEE
LD
A,0
Fig. 2.1.7.1 The use of the CALZ instruction

The difference between CALL and CALZ is shown in Figure 2.1.7.2.
CALL with PSET can go anywhere within a bank
Bank 0 Bank 1
Page 15 Bank 0
Page 15 Bank 1 Bank 1
Step 0 Step 1
Step 0 Step 1
PSET CALL
CALZ
Page 1 Bank 0
Step 254 Step 255
Page 1 Bank 1
Step 254 Step 255
Page 0 Bank 0
Page 0 Bank 1
Step 0 Step 1
Step 0 Step 1
CALL without PSET can go anywhere in a page
CALL and CALZ cannot go between banks
Step 254 Step 255
Step 254 Step 255
CALZ can only go to page 0 of the current bank
Fig. 2.1.7.2 The difference between CALL and CALZ instructions
The RET instruction causes a return from a subroutine to the address immediately following the address from where that subroutine was called. The RETS instruction causes a return to the address following this address. Proper use of RET and RETS allows simple conditional exits subroutines back to the main routine. See Figure 2.1.8.1.
Bank 0 Page 0 Program memory
0AH
CALL
DDD
LD
A,0
LD Bank 0 Page 10
DDD
RETS
Fig. 2.1.8.1 Difference between RET and RETS instructions
When a subroutine is called, the return address is loaded into the stack and retrieved when control is returned to the calling program. Nesting allows efficient usage of the stack area.
As the stack area resides in the data memory, care should be taken to ensure that the stack area is not corrupted by other data.

2.2 Data Memory
The data memory area comprises 4,096 4-bit words. The RAM, timer, I/O and other peripheral circuits are mapped into this memory according to the designer's specifications. Figure 2.2.1 shows the data memory configuration.
Step 0 Step 1
XHL or YHL (within page)
Step 254 Step 255
Step 0 Step 1
Memory or I/O
Step 254 Step 255
Register area
Fig. 2.2.1 Data memory configuration
The following registers and pointers, which are described in detail below, are used to address the data memory.
Table 2.2.1.1 Registers and pointer for data memory addressing
Index Register X Index Register Y Stack Pointer Register
12 12 8 4
LSB 4 4
Index register IX has a 4-bit page part (XP) and an 8- bit register (XHL), and can address any location in the data memory. See Figure 2.2.1.1.
X H X L
X HL
XHL is divided into two 4-bit groups: the four high- order bits (XH) and the four low-order bits (XL), and can address any location within a page. Fig. 2.2.1.1 The configuration of the index register IX
– MX is the data memory location whose address is specified by IX.
– M(X) refers to the contents of the data memory location whose address is specified by IX.
– XHL can be incremented by 1 or 2 using a post-increment instruction (LDPX, ACPX, SCPX, LBPX or RETD). An overflow occurring in XHL does not affect the flags.

Index register IY is like the index register IX: it has a 4-bit page part (YP), an 8-bit register (YHL), and can address any location in the data memory. See Figure 2.2.1.2.
LSB 4 4
Y P
Y H Y L
Y HL
YHL is divided into two 4-bit groups: the four high- order bits (YH) and the four low-order bits (YL), and can address any location within a page. Fig. 2.2.1.2 The configuration of the index register IY
– MY is the data memory location whose address is specified by IY.
– M(Y) refers to the contents of the data memory location whose address is specified by IY.
– YHL can be incremented by 1 using a post-increment instruction (LDPY, ACPY or SCPY). An overflow occurring in YHL does not affect the flags.
The stack area resides in the data memory. The 8-bit, push-down/pop-up stack pointer (SP) is used to address an element within the stack.
Table 2.2.1.2 Stack usage
Since it is an 8-bit pointer, SP can only address 256 words out of the total 4,096 words of data memory. When SP is used, the high-order 4 bits (page part) of the data memory address are 0, giving a stack area of 256 words in the address range 000H to 0FFH.
Operation Instruction Stack usage
DEC SP
In systems with a RAM area of less than 256 words, the entire RAM area can be used as the stack area.
RET, RETS or RETD
INC SP
Stack area usage is shown in Table 2.2.1.2.
The PUSH instruction can be used to store registers and flags in the stack in single-word (4-bit) units. The POP instruction is used to retrieve this data.
When an interrupt occurs or a call instruction is executed, the return address from the program counter is pushed onto the stack. When a return instruction is executed, the return address is retrieved from the stack and loaded into the program counter.
On an interrupt, only the program counter is saved on the stack; flag and register data are not saved. Programs should be designed so that flag and register data are pushed onto the stack by the interrupt service routines.
Following a system reset, SP should be initialized using the LD SPH,r or LD SPL,r instructions, where r represents A, B, MX or MY (4 bits).
Stack pointer data can be read using LD r,SPH or LD r,SPL.
The register pointer (RP) is a 4-bit register used to address the first 16 words of data memory, or the register area. Direct addressing can be used to read from, write to, increment or decrement any location within this area efficiently, using a single instruction.
Programs cannot directly access RP. It uses the operand of direct addressing instructions. The instructions that can access the register area of data memory are:
A,Mn B,Mn Mn,A Mn,B Mn Mn
A ← M(n) B ← M(n) M(n) ← A M(n) ← B M(n) ← M(n) + 1 M(n) ← M(n) – 1 n: 0 to F
where M(n) is the contents of a data memory location within the register area.
As the register area can also be indirectly accessed using IX, IY or SP, the stack area should not grow to address 000H to 00FH when RP is used.

2.3 ALU (Arithmetic Logic Unit) and Registers
Table 2.3.1 shows ALU operations between the 4-bit registers, TEMPA and TEMPB.
Table 2.3.1 ALU register operation
ADC
SUB
SBC
AND
OR
XOR
CP
FAN
Rotate right, with carry
Rotate left, with carry
NOT
The Z (zero) flag is set when the result of ALU operation is
C 3 2 1 0 X 0 X: Don't care.
The C (carry) flag is set when an add operation causes a carry or when a subtract operation causes a borrow.
Setting the D (decimal) flag activates the decimal mode, allowing decimal addition and subtraction. Table 2.3.1.1 shows the relations of actual (decimal) results, ALU outputs, and the values of the C and Z flags.
Table 2.3.1.1 Results of hexadecimal and decimal operations
Z 1 0 1 0
Z 1 0 1 0 1 0
Z 1 0 1 0
Z 0 1 0 1 0
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
0 1
0 1 2 3 4 5 6 7 8 9 A B C D E F 0 1 2 3 4 5 6 7 8 9 A B C D E F
0 1
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 A B C D E F 0 1 2 3 4 5
-16 -15 -14 -13 -12 -11 -10
1 0
0 1 2 3 4 5 6 7 8 9 A B C D E F 0 1 2 3 4 5 6 7 8 9 A B C D E F
1 0
A B C D E F 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 A B C D E F
-9 -8 -7 -6 -5 -4 -3 -2 -1
0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15

Hexadecimal operations will not always produce the correct result if performed in decimal mode.
does not involve decimal correction even if it is performed in the decimal mode. This is because it uses an 8-bit field for 4-bit data.
are not decimal-corrected.
The A and B registers are 4-bit general-purpose registers used as accumulators. They transfer data and perform ALU operations with other registers, data memory and immediate data.
The data in A can be paired with that in B for use as an indirect jump address by the JPBA instruction.
S1C6200/6200A instructions can be divided into three different types depending on the number of clock cycles per instruction: 5, 7 or 12 clock cycles. The more complex the instruction, the more cycles it requires. Note that the number of clock cycles determines the duration of instructions which, in turn, will affect any timing performed in software.
As shown in Figure 2.4.1, the first state of all instructions is a fetch cycle. This is followed by a number of execute cycles.
12-clock instructions
Fig. 2.4.1 Instruction execution timing
HALT and SLP cause the CPU to store the return address on the stack and then stop. HALT will only stop the CPU; the system clock will continue to run. SLP also stops the system clock, resulting in reduced power consumption. The CPU can be restarted by an interrupt.
As interrupts are not automatically enabled by the execution of HALT or SLP, programs should always enable interrupts before executing HALT or SLP, otherwise they will hang waiting for an interrupt.

2.5 Interrupts
The S1C6200/6200A can have up to 15 interrupt vectors. When used with peripheral circuits, these allow internal and external interrupts to be processed easily. See Figure 2.5.3.1 through 2.5.3.4.
The interrupt vectors are assigned to steps 1 to 15 in page 1 of each bank of the program memory. When an interrupt occurs, the program jumps to the appropriate interrupt vector in the current bank.
The priority and linking of these vectors to actual outside events depends on the configuration of the peripheral circuits and therefore is device-specific. This information can be found in the technical manuals for the specific device.
The I (interrupt) flag enables or disables all interrupts.
When DI or RST F is used to reset the I flag, interrupts are disabled with that instruction step. When EI or SET F is used to set the I flag, interrupts are enabled after the following instruction step. For example, to return control from the interrupt subroutine to the main routine, the sequence EI, RET, does not enable interrupts until after RET has been executed.
The I flag is reset to 0 (DI) on reset.
When an interrupt is generated, the program is halted, the program counter (PCP and PCS) is stored on the stack, the I flag is reset to DI mode and NPP is set to 1. The program then branches to the interrupt vector corresponding to the interrupt request. Registers and flags are unaffected by an interrupt.
Register and flag data must be saved by the program since they are not automatically stored on the stack.
The I flag can be set to 1 (EI) within the interrupt subroutine, because nesting of multiple interrupts is available.
If an interrupt is generated while the CPU is in HALT or SLP mode, the CPU is restarted and the interrupt serviced. When the interrupt service routine is completed, the program resumes from the instruction following the HALT or SLP.
<Differences between S1C6200 and S1C6200A> In the S1C6200 and the S1C6200A, the time it takes to complete interrupt processing by hardware after the Core CPU receives the interrupt request is different as follows:
Table 2.5.3.1 Required interrupt processing time
a) During instruction execution
12-cycle instruction execution 7-cycle instruction execution 5-cycle instruction execution
12.5 to 24.5 12.5 to 19.5 12.5 to 17.5 14 to 15 12.5 to 24.5 12.5 to 22.5
13 to 25 13 to 20 13 to 18 14 to 15 13 to 25 13 to 23
b) At HALT mode c) During PSET instruction execution
S1C6200A (clock cycles) · S1C6200 (clock cycles) · Item

S1C6200
INT1 (*1) INT2 (*1) JP (*2)
Interrupt processing:
12-clock instruction 7-clock instruction 5-clock instruction
... 13 to 25 clock cycles ... 13 to 20 clock cycles ... 13 to 18 clock cycles
INT1 (*1) INT2 (*1) JP (*2)
Interrupt processing:
12-clock instruction 7-clock instruction 5-clock instruction
... 12.5 to 24.5 clock cycles ... 12.5 to 19.5 clock cycles ... 12.5 to 17.5 clock cycles
INT1 and INT2 are dummy instructions Branches to the top of the interrupt service routine Status:
Fig. 2.5.3.1 Interrupt timing during execution
Instruction 5-clock Instrruction Interrupt
INT1 (*1) INT2 (*1) JP (*2)
INT1 and INT2 are dummy instructions Branches to the top of the interrupt service routine Status:
Fig. 2.5.3.2 Interrupt timing in the HALT mode

S1C6200/6200A
SLEEP
INT1 (*1) INT2 (*1) JP (*2)
INT1 and INT2 are dummy instructions Branches to the top of the interrupt service routine Status:
Fig. 2.5.3.3 Interrupt timing in SLEEP mode
PSET
CALL
INT1 (*1) INT2 (*1) JP (*2)
... 13 to 25 clock cycles ... 13 to 23 clock cycles Interrupt processing:
PSET + JP
S1C6200A
CALL
INT1 (*1) INT2 (*1) JP (*2)
... 12.5 to 24.5 clock cycles ... 12.5 to 22.5 clock cycles Interrupt processing:
PSET + JP
INT1 and INT2 are dummy instructions Branches to the top of the interrupt service routine Status:
Fig. 2.5.3.4 Interrupt timing with PSET

2.5.4 Initial reset
On reset, the registers and flags are set as shown in Table 2.5.4.1.
Table 2.5.4.1 Reset value
00H
PCP
01H
PCB
00H
NPP
01H
NBP
SP
IY
RP
A
B
0H
D
Z
* S1C6200 ...Undefined S1C6200A ...0
<Difference between S1C6200 and S1C6200A> There is a difference in the setting value of the D (decimal) flag at initial reset between the S1C6200 and the S1C6200A.
Table 2.5.4.2 D (decimal) flag initial setting
D (decimal) flag setting
When using the model loaded with the S1C6200 Core CPU, set or reset the D flag in the user's initial routine before using an arithmetic instruction. (refer to the SDF and RDF instructions.)

This chapter describes the entire instruction set of the S1C6200/6200A Core CPU. A subset is allocated to each device within the S1C62 Family according to the configuration of the device. Therefore not all instructions are available in every device. The relevant information is in the technical manual for each device.
The source format and a description of the assembler is in the series-specific cross assembler manuals.
The instruction set contains 109 instructions. Each instruction comprises of one 12-bit word.
Three index tables are used for easy reference instructions.
The instructions are arranged by function. 1. Branch 2. System control 3. Flag operation 4. Stack operation 5. Index operation 6. Data transfer 7. Arithmetic and logical operation
The instructions are arranged in alphabetical order. Page number references are provided.
The instructions are arranged in numerical order by operation code.

Classification Operand Clock Operation Code Flag Mne- monic Operation
A
I D Z C
PSET
NBP ← p4, NPP ← p3~p0
PCB ← NBP, PCP ← NPP, PCS ← s7~s0
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if C=1
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if C=0
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if Z=1
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if Z=0
PCB ← NBP, PCP ← NPP, PCSH ← B, PCSL ← A
M(SP-1) ← PCP, M(SP-2) ← PCSH, M(SP-3) ← PCSL+1
SP ← SP-3, PCP ← NPP, PCS ← s7~s0
M(SP-1) ← PCP, M(SP-2) ← PCSH, M(SP-3) ← PCSL+1
SP ← SP-3, PCP ← 0, PCS ← s7~s0
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2)
RETS
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2)
RETD
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2)
SP ← SP+3, M(X) ← e3~e0, M(X+1) ← e7~e4, X ← X+2
No operation (5 clock cycles)
No operation (7 clock cycles)
SLP
INC
X ← X+1
Y
Y ← Y+1
LD
XH ← e7~e4, XL ← e3~e0
YH ← e7~e4, YL ← e3~e0
r ← Y H

Clock Operation Code Flag
A
I D Z C
CP
LD
LDPX
M(X) ← i3~i0, X ← X+1
r ← q, X ← X+1
M(Y) ← i3~i0, Y ← Y+1
r ← q, Y ← Y+1
M(X) ← e3~e0, M(X+1) ← e7~e4, X ← X+2
F ← FVi3~i0
F ← FΛi3~i0
C ← 1
RCF
C ← 0
SZF
Z ← 1
RZF
Z ← 0
SDF
D ← 1 (Decimal Adjuster ON)
D ← 0 (Decimal Adjuster OFF)
I ← 1 (Enables Interrupt)
I ← 0 (Disables Interrupt)
SP
SP ← SP+1
DEC
SP
SP ← SP-1
PUSH
SP ← SP-1, M(SP) ← r
SP ← SP-1, M(SP) ← XP
XH
SP ← SP-1, M(SP) ← XH
SP ← SP-1, M(SP) ← XL
YP
SP ← SP-1, M(SP) ← YP
YH
SP ← SP-1, M(SP) ← YH
YL
SP ← SP-1, M(SP) ← YL
F
SP ← SP-1, M(SP) ← F
POP
r ← M(SP), SP ← SP+1
XP ← M(SP), SP ← SP+1
XH
XH ← M(SP), SP ← SP+1
XL ← M(SP), SP ← SP+1
YP
YP ← M(SP), SP ← SP+1

Clock Operation Code Flag
A
I D Z C
POP
YH
YH ← M(SP), SP ← SP+1
YL
YL ← M(SP), SP ← SP+1
F
F ← M(SP), SP ← SP+1
LD
ADD
ADC
SUB
SBC
AND
r ← rΛi3~i0
r ← rΛq
r ← rVi3~i0
r ← rVq
r ← r∀i3~i0
r ← r∀q
FAN
RLC
d3 ← d2, d2 ← d1, d1 ← d0, d0 ← C, C ← d3
d3 ← C, d2 ← d3, d1 ← d2, d0 ← d1, C ← d0
DEC
ACPX
M(X) ← M(X)+r+C, X ← X+1
M(Y) ← M(Y)+r+C, Y ← Y+1
M(X) ← M(X)-r-C, X ← X+1
M(Y) ← M(Y)-r-C, Y ← Y+1

Page Operand Clock Operation Code Flag Mne- monic Operation
A
I D Z C
ACPX
M(X) ← M(X)+r+C, X ← X+1
M(Y) ← M(Y)+r+C, Y ← Y+1
ADD
AND
r ← rΛi3~i0
r ← rΛq
M(SP-1) ← PCP, M(SP-2) ← PCSH, M(SP-3) ← PCSL+1
SP ← SP-3, PCP ← NPP, PCS ← s7~s0
M(SP-1) ← PCP, M(SP-2) ← PCSH, M(SP-3) ← PCSL+1
SP ← SP-3, PCP ← 0, PCS ← s7~s0
DEC
SP
SP ← SP-1
DI
I ← 0 (Disables Interrupt)
I ← 1 (Enables Interrupt)
HALT
INC
SP
SP ← SP+1
X ← X+1
Y
Y ← Y+1
JPBA
PCB ← NBP, PCP ← NPP, PCSH ← B, PCSL ← A
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if C=1
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if C=0
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if Z=0
PCB ← NBP, PCP ← NPP, PCS ← s7~s0
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if Z=1
M(X) ← e3~e0, M(X+1) ← e7~e4, X ← X+2

Page Operand Clock Operation Code Flag Mne- monic Operation
A
I D Z C
LD
XH ← e7~e4, XL ← e3~e0
YH ← e7~e4, YL ← e3~e0
M(X) ← i3~i0, X ← X+1
r ← q, X ← X+1
M(Y) ← i3~i0, Y ← Y+1
r ← q, Y ← Y+1
No operation (5 clock cycles)
No operation (7 clock cycles)
OR
r ← rVi3~i0
r ← rVq
F
F ← M(SP), SP ← SP+1
r ← M(SP), SP ← SP+1
XH ← M(SP), SP ← SP+1
XL ← M(SP), SP ← SP+1
XP
XP ← M(SP), SP ← SP+1
YH
YH ← M(SP), SP ← SP+1
YL
YL ← M(SP), SP ← SP+1
YP
YP ← M(SP), SP ← SP+1

Page Operand Clock Operation Code Flag Mne- monic Operation
A
I D Z C
PSET
NBP ← p4, NPP ← p3~p0
F
SP ← SP-1, M(SP) ← F
SP ← SP-1, M(SP) ← r
SP ← SP-1, M(SP) ← XH
SP ← SP-1, M(SP) ← XL
XP
SP ← SP-1, M(SP) ← XP
YH
SP ← SP-1, M(SP) ← YH
YL
SP ← SP-1, M(SP) ← YL
YP
SP ← SP-1, M(SP) ← YP
RCF
C ← 0
RDF
D ← 0 (Decimal Adjuster OFF)
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2)
RETD
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2)
SP ← SP+3, M(X) ← e3~e0, M(X+1) ← e7~e4, X ← X+2
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2)
RLC
d3 ← d2, d2 ← d1, d1 ← d0, d0 ← C, C ← d3
d3 ← C, d2 ← d3, d1 ← d2, d0 ← d1, C ← d0
F ← FΛi3~i0
Z ← 0
SBC
SCF
C ← 1
SCPX
M(X) ← M(X)-r-C, X ← X+1
M(Y) ← M(Y)-r-C, Y ← Y+1
D ← 1 (Decimal Adjuster ON)
F ← FVi3~i0
SUB
SZF
Z ← 1
XOR
r ← r∀i3~i0
r ← r∀q

Operand Clock Operation Code Flag Mne- monic Operation Operation Code (HEX)
A
I D Z C
JP
PCB ← NBP, PCP ← NPP, PCS ← s7~s0
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2)
SP ← SP+3, M(X) ← e3~e0, M(X+1) ← e7~e4, X ← X+2
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if C=1
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if C=0
M(SP-1) ← PCP, M(SP-2) ← PCSH, M(SP-3) ← PCSL+1
SP ← SP-3, PCP ← NPP, PCS ← s7~s0
M(SP-1) ← PCP, M(SP-2) ← PCSH, M(SP-3) ← PCSL+1
SP ← SP-3, PCP ← 0, PCS ← s7~s0
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if Z=1
PCB ← NBP, PCP ← NPP, PCS ← s7~s0 if Z=0
YH ← e7~e4, YL ← e3~e0
M(X) ← e3~e0, M(X+1) ← e7~e4, X ← X+2
ADC
ADC
ADC
CP
CP
CP
CP
ADD
ADC
SUB
SBC
AND
r ← rΛq
r ← rVq
r ← r∀q
d3 ← d2, d2 ← d1, d1 ← d0, d0 ← C, C ← d3
XH ← e7~e4, XL ← e3~e0
ADC
AND
r ← rΛi3~i0
r ← rVi3~i0
r ← r∀i3~i0
SBC
FAN
CP
LD

Operand Clock Operation Code Flag Mne- monic Operation Operation Code (HEX)
A
I D Z C
PSET
NBP ← p4, NPP ← p3~p0
M(X) ← i3~i0, X ← X+1
M(Y) ← i3~i0, Y ← Y+1
LD
LD
RRC
d3 ← C, d2 ← d3, d1 ← d2, d0 ← d1, C ← d0
LD
LD
LD
LD
LD
LD
LD
LD
LD
EE0
INC
X ← X+1
LDPX
r ← q, X ← X+1
INC
Y
Y ← Y+1
LDPY
r ← q, Y ← Y+1
FAN
ACPX
M(X) ← M(X)+r+C, X ← X+1
M(Y) ← M(Y)+r+C, Y ← Y+1
M(X) ← M(X)-r-C, X ← X+1
M(Y) ← M(Y)-r-C, Y ← Y+1
F ← FVi3~i0
SCF
C ← 1
F42
SZF
Z ← 1
F44
SDF
D ← 1 (Decimal Adjuster ON)
EI
I ← 1 (Enables Interrupt)
F ← FΛi3~i0
DI
I ← 0 (Disables Interrupt)
RDF
D ← 0 (Decimal Adjuster OFF)
RZF
Z ← 0
F5E
RCF
C ← 0
INC
DEC
LD

Operand Clock Operation Code Flag Mne- monic Operation Operation Code (HEX)
A
I D Z C
LD
LD
LD
PUSH
SP ← SP-1, M(SP) ← r
PUSH
XP
SP ← SP-1, M(SP) ← XP
FC5
PUSH
XH
SP ← SP-1, M(SP) ← XH
FC6
PUSH
SP ← SP-1, M(SP) ← XL
FC7
PUSH
YP
SP ← SP-1, M(SP) ← YP
FC8
PUSH
YH
SP ← SP-1, M(SP) ← YH
FC9
PUSH
YL
SP ← SP-1, M(SP) ← YL
FCA
PUSH
F
SP ← SP-1, M(SP) ← F
FCB
DEC
SP
SP ← SP-1
POP
r ← M(SP), SP ← SP+1
POP
XP
XP ← M(SP), SP ← SP+1
FD5
POP
XH
XH ← M(SP), SP ← SP+1
FD6
POP
XL ← M(SP), SP ← SP+1
FD7
POP
YP
YP ← M(SP), SP ← SP+1
FD8
POP
YH
YH ← M(SP), SP ← SP+1
FD9
POP
YL
YL ← M(SP), SP ← SP+1
FDA
POP
F
F ← M(SP), SP ← SP+1
FDB
INC
SP
SP ← SP+1
FDE
RETS
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2)
FDF
RET
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2)
LD
LD
FE8
JPBA
PCB ← NBP, PCP ← NPP, PCSH ← B, PCSL ← A
LD
FF8
HALT
FF9
SLP
FFB
NOP5
No operation (5 clock cycles)
NOP7
No operation (7 clock cycles)

This section describes the operands used in the instructions.
p 5-bit immediate data or labels 00H to 1FH. Used to specify a destination address. s 8-bit immediate data or labels 00H to FFH. Used to specify a destination address. e 8-bit immediate data 00H to FFH. i 4-bit immediate data 00H to 0FH. r 2-bit immediate data. See Table 3.2.1. q 2-bit immediate data. See Table 3.2.1.
The contents of A, B, MX, MY are referenced using r and q as shown in the following table.
Table 3.2.1 Values of r and q
r1 or q1
r0 or q0
B
MX
MY
A A register B B register XP XP register---four high-order bits of IX YP YP register---four high-order bits of IY X XHL register---eight low-order bits of IX Y YHL register---eight low-order bits of IY XH XH register---four high-order bits of XHL XL XL register---four low-order bits of XHL YH YH register---four high-order bits of YHL YL YL register---four low-order bits of YHL SP Stack pointer SP SPH Four high-order bits of SP SPL Four low-order bits of SP F Flag register (IF, DF, ZF, CF) MX Data memory location whose address is specified by IX MY Data memory location whose address is specified by IY Mn Data memory location within the register area (000H to 00FH), specified by immediate data n (0H to FH) C Carry NC No carry Z Zero NZ Not zero

Instructions are divided into six types according to the size of the operand.
etc.
r, i r, i r, i
etc.
F, i r, q Mn
etc.
MX, r XH, r r
etc.
etc.
This section describes S1C6200/6200A instructions in alphabetical order.

M(X) ← M(X) + r + C, X ← X + 1
1 0 0 1 0 1 0 r1 r0 F28H to F2BH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds the carry bit and the contents of the r-register to the data memory location addressed by IX. X is incremented by one. Incrementing X does not affect the flags.
ACPX MX,A ACPX MX,MY X register 1010 0000 1010 0001 1010 0010 Y register 0100 0110 0100 0110 0100 0110 Memory (A0H) 0110 1111 1111 Memory (A1H) 0011 0011 0111 Memory (46H) 0100 0100 0100 A register 1000 1000 1000 C flag 1 0 0 Z flag 0 0 0
M(Y) ← M(Y) + r + C, Y ← Y + 1
1 0 0 1 0 1 1 r1 r0 F2CH to F2FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds the carry bit and the contents of the r-register to the data memory location addressed by IY. Y is incremented by one. Incrementing Y does not affect the flags.
ACPY MY,A ACPY MY,MX X register 0010 0001 0010 0001 0010 0001 Y register 0000 1110 0000 1111 0001 0000 Memory (0EH) 1000 1011 1011 Memory (0FH) 0100 0100 1010 Memory (21H) 0110 0110 0110 A register 0010 0010 0010 C flag 1 0 0 Z flag 0 0 0

r ← r + i3 to i0 + C
1 1 0 0 0 1 r1 r0 i3 i2 i1 i0 C40H to C7FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds the carry bit and immediate data i to the r-register.
ADC MX,3 ADC B,7 Memory (MX) 0100 1000 1000 B register 1001 1001 0000 C flag 1 0 1 Z flag 1 0 1
r ← r + q + C
1 0 1 0 1 0 0 1 r1 r0 q1 q0 A90H to A9FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds the carry bit and the contents of the q-register to the r-register.
ADC MY,A ADC MX,B A register 0101 0101 0101 B register 0001 0001 0001 Memory (MX) 0111 0111 1001 Memory (MY) 1011 0001 0001 C flag 1 1 0 Z flag 0 0 0

XH ← XH + i3 to i0 + C
1 0 1 0 i3 i2 i1 i0 A00H to A0FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds the carry bit and immediate data i to XH, the four high-order bits of XHL.
ADC XH,2 ADC XH,4 XH register 1001 1100 0000 C flag 1 0 1 Z flag 0 0 1
XL ← XL + i3 to i0 + C
1 0 1 0 1 i3 i2 i1 i0 A10H to A1FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds the carry bit and immediate data i to XL, the four low-order bits of XHL.
ADC XL,3 ADC XL,0EH XL register 0000 0100 0010 C flag 1 0 1 Z flag 1 0 0

YH ← YH + i3 to i0 + C
1 0 1 0 0 0 1 0 i3 i2 i1 i0 A20H to A2FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds the carry bit and immediate data i to YH, the four high-order bits of YHL.
ADC YH,3 ADC YH,6 YH register 1010 1110 0100 C flag 1 0 1 Z flag 0 0 0
YL ← YL + i3 to i0 + C
1 0 1 0 0 0 1 1 i3 i2 i1 i0 A30H to A3FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds the carry bit and immediate data i to YL, the four low-order bits of YHL.
ADC YL,3 ADC YL,2 YL register 1010 1110 0000 C flag 1 0 1 Z flag 0 0 1

r ← r + i3 to i0
1 1 0 r1 r0 i3 i2 i1 i0 C00H to C3FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds immediate data i to the contents of the r-register.
ADD A,5 ADD MY,2 A register 1010 1111 1111 Memory (MY) 0110 0110 1000 C flag 1 0 0 Z flag 0 0 0
r ← r + q
1 0 1 0 1 0 0 0 r1 r0 q1 q0 A80H to A8FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Adds the contents of the q-register to the contents of the r-register.
ADD A,MY ADD MX,B A register 0010 1111 1111 B register 0100 0100 0100 Memory (MX) 0111 0111 1011 Memory (MY) 1101 1101 1101 C flag 1 0 0 Z flag 1 0 0

r ← r ∧ i3 to i0
1 1 0 0 1 0 r1 r0 i3 i2 i1 i0 C80H to CBFH
Not affected Set if the result is zero; otherwise, reset. Not affected Not affected
Performs a logical AND operation between immediate data i and the contents of the r-register. The result is stored in the r-register.
AND A,5 AND MX,3 A register 0110 0100 0100 Memory (MX) 1000 1000 0000 C flag 1 1 1 Z flag 0 0 1
r ← r ∧ q
1 0 1 0 1 1 0 0 r1 r0 q1 q0 AC0H to ACFH
Not affected Set if the result is zero; otherwise, reset. Not affected Not affected
Performs a logical AND operation between the contents of the q-register and the contents of the r-register. The result is stored in the r-register.
AND MX,A AND B,MY A register 0100 0100 0100 B register 1011 1011 0010 Memory (MX) 1010 0000 0000 Memory (MY) 0010 0010 0010 C flag 0 0 0 Z flag 0 1 0

M(SP-1) ← PCP, M(SP-2) ← PCSH, M(SP-3) ← PCSL + 1, SP ← SP - 3, PCP ← NPP, PCS ← s7 to s0
0 1 0 0 s7 s6 s5 s4 s3 s2 s1 s0 400H to 4FFH
Pushes the program counter (PCP, PCS) onto the stack as the return address, then calls the subroutine addressed by NPP and the 8-bit operand.
PSET 06H CALL 10H PCP 0011 0011 0110 PCS 0010 1100 0010 1100 0001 0000 NPP 0001 0110 0110 SP C0 C0 BD Memory (SP-1) xxxx xxxx 0011 Memory (SP-2) xxxx xxxx 0010 Memory (SP-3) xxxx xxxx 1101
M(SP-1) ← PCP, M(SP-2) ← PCSH, M(SP-3) ← PCSL + 1, SP ← SP - 3, PCP ← 0, PCS ← s7 to s0
0 1 0 1 s7 s6 s5 s4 s3 s2 s1 s0 500H to 5FFH
Pushes the program counter (PCP, PCS) onto the stack as the return address, then calls the subroutine addressed by the 8-bit operand. As NPP is reset to 0H, only a subroutine in page 0 can be called.
CALZ 10H PCP 1010 0000 PCS 0010 1110 0001 0000 SP CA C7 Memory (SP-1) xxxx 1010 Memory (SP-2) xxxx 0010 Memory (SP-3) xxxx 1111

r - i3 to i0
1 1 0 1 1 1 r1 r0 i3 i2 i1 i0 DC0H to DFFH
Set if r < i3 to i0; otherwise, reset. Set if r = i3 to i0; otherwise, reset. Not affected Not affected
Compares immediate data i to the r-register by subtracting i from the contents of r. The r-register remains unchanged. 1. When Z = 0 and C = 0 then i < r 2. When Z = 1 and C = 0 then i = r 3. When Z = 0 and C = 1 then i > r
CP A,4 CP MX,7 CP B,2 A register 0100 B register 1010 Memory (MX) 0010 C flag 1 0 1 0 Z flag 0 1 0 0
1 0 r1 r0 q1 q0 F00H to F0FH
Set if r < q; otherwise, reset. Set if r = q; otherwise, reset. Not affected Not affected
Compares the q-register to the r-register by subtracting the contents of q from the contents of r. The registers remain unchanged. 1. When Z = 0 and C = 0 then q < r 2. When Z = 1 and C = 0 then q = r 3. When Z = 0 and C = 1 then q > r
CP A,B CP MY,A A register 1000 1000 1000 B register 0100 0100 0100 Memory (MY) 0111 0111 0111 C flag 0 0 1 Z flag 0 0 0
r - q

XH - i3 to i0
1 0 1 0 0 1 0 0 i3 i2 i1 i0 A40H to A4FH
Set if XH < i3 to i0; otherwise, reset. Set if XH = i3 to i0; otherwise, reset. Not affected Not affected
Compares immediate data i to XH by subtracting i from the contents of XH. XH remains unchanged. 1. When Z = 0 and C = 0 then i < XH 2. When Z = 1 and C = 0 then i = XH 3. When Z = 0 and C = 1 then i > XH
CP XH,2 CP XH,4 CP XH,9 XH register 0100 C flag 1 0 0 1 Z flag 0 0 1 0
XL - i3 to i0
1 0 1 0 0 1 0 1 i3 i2 i1 i0 A50H to A5FH
Set if XL < i3 to i0; otherwise, reset. Set if XL = i3 to i0; otherwise, reset. Not affected Not affected
Compares immediate data i to XL by subtracting i from the contents of XL. XL remains unchanged. 1. When Z = 0 and C = 0 then i < XL 2. When Z = 1 and C = 0 then i = XL 3. When Z = 0 and C = 1 then i > XL
CP XL,7 CP XL,9 CP XL,0AH XL register 1001 C flag 0 0 0 1 Z flag 0 0 1 0

YH - i3 to i0
1 0 1 0 0 1 1 0 i3 i2 i1 i0 A60H to A6FH
Set if YH < i3 to i0; otherwise, reset. Set if YH = i3 to i0; otherwise, reset. Not affected Not affected
Compares immediate data i to YH by subtracting i from the contents of YH. YH remains unchanged. 1. When Z = 0 and C = 0 then i < YH 2. When Z = 1 and C = 0 then i = YH 3. When Z = 0 and C = 1 then i > YH
CP YH,0AH CP YH,3 CP YH,0FH YH register 1010 C flag 1 0 0 1 Z flag 0 1 0 0
YL - i3 to i0
1 0 1 0 0 1 1 1 i3 i2 i1 i0 A70H to A7FH
Set if YL < i3 to i0; otherwise, reset. Set if YL = i3 to i0; otherwise, reset. Not affected Not affected
Compares immediate data i to YL by subtracting i from the contents of YL. YL remains unchanged. 1. When Z = 0 and C = 0 then i < YL 2. When Z = 1 and C = 0 then i = YL 3. When Z = 0 and C = 1 then i > YL
CP YL,5 CP YL,1 CP YL,4 YL register 0100 C flag 0 1 0 0 Z flag 1 0 0 1

Decrement memory
M(n3 to n0) ← M(n3 to n0) - 1
1 0 1 1 1 n3 n2 n1 n0 F70H to F7FH
Set if a borrow is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Decrements the contents of the data memory location addressed by Mn by 1.
DEC M0 DEC M2 DEC M0FH Memory (00H) 1001 1000 1000 1000 Memory (02H) 0000 0000 1111 1111 Memory (0FH) 0001 0001 0001 0000 C flag 1 0 1 0 Z flag 0 0 0 1
SP ← SP - 1
1 0 0 1 0 1 1 FCBH
Decrements the contents of the stack pointer by 1. This operation does not affect the flags.
DEC SP Memory (SP) 1011 0001 1011 0000 C flag 0 0 Z flag 1 1

1 0 1 0 1 0 1 1 1 F57H
Not affected Not affected Not affected Reset
Disables all interrupts.
DI C flag 0 0 Z flag 1 1 D flag 0 0 I flag 1 0
1 0 1 0 0 1 0 0 0 F48H
Not affected Not affected Not affected Set
Enables all interrupts.
EI C flag 1 1 Z flag 0 0 D flag 0 0 I flag 0 1

r ∧ i3 to i0
1 1 0 1 1 0 r1 r0 i3 i2 i1 i0 D80H to DBFH
Not affected Set if the result is zero; otherwise, reset. Not affected Not affected
Performs a logical AND operation between immediate data i and the contents of the r-register. Only the Z flag is affected. The r-register remains unchanged.
FAN A,7 FAN MY,9 FAN B,2 A register 1000 B register 0100 Memory (MY) 1000 C flag 1 Z flag 0 1 0 1
1 0 0 0 1 r1 r0 q1 q0 F10H to F1FH
Not affected Set if the result is zero; otherwise, reset. Not affected Not affected
Performs a logical AND operation between the contents of the q-register and the contents of the r-register. Only the Z flag is affected. The registers remains unchanged.
FAN A,B FAN MX,B FAN A,MY A register 1000 B register 1010 Memory (MX) 0101 Memory (MY) 1110 C flag 0 Z flag 0 0 1 0
r ∧ q

1 0 0 0 FF8H
Stops the CPU. When an interrupt occurs, PCP and PCS are pushed onto the stack as the return address and the interrupt service routine is executed.
Instruction State PCP PCS I flag HALT RUN 0001 0011 0011 1 HALT Interrupt 0001 0011 0100 1 RUN 0001 Interrupt vector address 0
M(n3 to n0) ← M(n3 to n0) + 1
1 0 1 1 0 n3 n2 n1 n0 F60H to F6FH
Set if a carry is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
The contents of the data memory location addressed by Mn is incremented by 1.
INC M1 INC M3 INC M0DH Memory (01H) 0100 0101 0101 0101 Memory (03H) 1111 1111 0000 0000 Memory (0DH) 0111 0111 0111 1000 C flag 0 0 1 0 Z flag 1 0 1 0
Stops CPU

SP ← SP + 1
1 0 1 1 0 1 1 FDBH
Increments the contents of the stack pointer by 1. This operation does not affect the flags.
INC SP SP 1110 1111 1111 0000 C flag 0 0 Z flag 0 0
X ← X + 1
1 1 1 0 1 1 1 0 EE0H
Increments the contents of register X by 1. This operation does not affect the flags.
INC X X register 1111 1110 1111 1111 C flag 1 1 Z flag 0 0

Y ← Y + 1
1 1 1 0 1 0 EF0H
Increments the contents of register Y by 1. This operation does not affect the flags.
INC Y Y register 1011 0111 1011 1000 C flag 1 1 Z flag 0 0
PCB ← NBP, PCP ← NPP, PCSH ← B, PCSL ← A
1 0 1 0 0 0 FE8H
Uses the contents of a- and b-registers to specify the destination address of the jump. The b-register contains the four high-order bits of the address and the a- register contains the four low-order bits of the address.
PSET 15H JPBA PCB 0 0 1 NBP 0 1 1 PCP 1000 1000 0101 NPP 0001 0101 0101 PCS 1001 0000 1001 0001 0000 0110 A register 0110 0110 0110 B register 0000 0000 0000

PCB ← NBP, PCP ← NPP, PCS ← s7 to s0 if C = 1
0 0 1 0 s7 s6 s5 s4 s3 s2 s1 s0 200H to 2FFH
Jumps to the destination address specified by the 8-bit operand when the carry flag is set.
ADD A,8 PSET 06H JP C,10H PCB 0 NBP 0 PCP 0010 0010 0010 0110 NPP 0001 0001 0110 0110 PCS 0011 1100 0011 1101 0011 1110 0001 0000 A register 1000 0000 0000 0000 C flag 0 1 1 1
PCB ← NBP, PCP ← NPP, PCS ← s7 to s0 if C = 0
0 0 1 1 s7 s6 s5 s4 s3 s2 s1 s0 300H to 3FFH
Jumps to the destination address specified by the 8-bit operand when the carry flag is not set.
PSET 11H JP NC,10H PCB 0 0 1 NBP 0 1 1 PCP 1001 1001 0001 NPP 0001 0001 0001 PCS 1000 1111 1001 0000 0001 0000 C flag 0 0 0

PCB ← NBP, PCP ← NPP, PCS ← s7 to s0 if Z = 0
0 1 1 1 s7 s6 s5 s4 s3 s2 s1 s0 700H to 7FFH
Jumps to the destination address specified by the 8-bit operand when the zero flag is not set.
JP NZ,10H PCB 1 1 NBP 1 1 PCP 0000 0000 NPP 0000 0000 PCS 0000 0111 0001 0000 Z flag 0 0
PCB ← NBP, PCP ← NPP, PCS ← s7 to s0
0 s7 s6 s5 s4 s3 s2 s1 s0 000H to 0FFH
Unconditional jump to the destination address specified by the 8-bit operand.
PSET 0AH JP 10H PCB 0 0 0 NBP 0 0 0 PCP 0000 0000 1010 NPP 0001 1010 1010 PCS 0100 0010 0100 0011 0001 0000

PCB ← NBP, PCP ← NPP, PCS ← s7 to s0 if Z = 1
0 1 1 0 s7 s6 s5 s4 s3 s2 s1 s0 600H to 6FFH
Jumps to the destination address specified by the 8-bit operand when the zero flag is set.
SUB A,B PSET 1BH JP Z,10H PCB 0 0 0 1 NBP 0 0 1 1 PCP 0101 0101 0101 1011 NPP 0001 0001 1011 1011 PCS 0000 0010 0000 0011 0000 0100 0001 0000 A register 0110 0000 0000 0000 B register 0110 Z flag 0 1 1 1
LBPX MX,e Load immediate data e to memory, and increment X by 2
M(X) ← e3 to e0, M(X+1) ← e7 to e4, X ← X + 2
1 0 0 1 e7 e6 e5 e4 e3 e2 e1 e0 900H to 9FFH
Stores 8-bit immediate data e in two, consecutive 4-bit locations in data memory. The X-register is incremented by 2. An overflow in X does not affect the flags.
LBPX MX,18H LBPX MX,36H X register 0001 1110 0010 0000 0010 0010 Memory (1EH) 0010 1000 1000 Memory (1FH) 1111 0001 0001 Memory (20H) 0000 0000 0110 Memory (21H) 0111 0111 0011

A ← M(n3 to n0)
1 0 1 0 n3 n2 n1 n0 FA0H to FAFH
Loads the contents of the data memory location addressed by Mn into the A- register.
LD A,M5 LD A,M6 A register 0100 1111 0100 Memory (05H) 1111 1111 1111 Memory (06H) 0100 0100 0100
B ← M(n3 to n0)
1 0 1 1 n3 n2 n1 n0 FB0H to FBFH
Loads the contents of the data memory location addressed by Mn into the B- register.
LD B,M7 LD B,M8 B register 0100 0110 1010 Memory (07H) 0110 0110 0110 Memory (08H) 1010 1010 1010

M(n3 to n0) ← A
1 0 0 0 n3 n2 n1 n0 F80H to F8FH
Loads the contents of the A-register into the location addressed by Mn.
LD M0AH,A LD M0BH,A A register 0110 0110 0110 Memory (0AH) 0100 0110 0110 Memory (0BH) 1011 1011 0110
M(n3 to n0) ← B
1 0 0 1 n3 n2 n1 n0 F90H to F9FH
Loads the contents of the B-register into the data memory location addressed by Mn.
LD M0,B LD M1,B B register 0100 0100 0100 Memory (00H) 1011 0100 0100 Memory (01H) 1111 1111 0100

M(X) ← i3 to i0, X ← X + 1
1 1 1 0 0 1 1 0 i3 i2 i1 i0 E60H to E6FH
Loads immediate data i into the data memory location addressed by IX. X is incremented by 1. Incrementing X does not affect the flags.
LDPX MX,7 LDPX MX,0AH X register 1000 0011 1000 0100 1000 0101 Memory (83H) 0010 0111 0111 Memory (84H) 1001 1001 1010
r ← q, X ← X + 1
1 1 1 0 1 1 1 0 r1 r0 q1 q0 EE0H to EEFH
Loads the contents of the q-register into the r-register. X is incremented by 1. Incrementing X does not affect the flags.
LDPX A,B LDPX B,MY X register 0100 1001 0100 1010 0100 1011 A register 1010 1101 1101 B register 1101 1101 0000 Memory (MY) 0000 0000 0000

M(Y) ← i3 to i0, Y ← Y + 1
1 1 1 0 0 1 1 1 i3 i2 i1 i0 E70H to E7FH
Loads immediate data i into the data memory location addressed by IY. Y is incremented by 1. Incrementing Y does not affect the flags.
LDPY MY,7 LDPY MY,0 Y register 0010 1101 0010 1110 0010 1111 Memory (2DH) 1010 0111 0111 Memory (2EH) 0010 0010 0000
r ← q, Y ← Y + 1
1 1 1 0 1 r1 r0 q1 q0 EF0H to EFFH
Loads the contents of the q-register into the r-register. Y is incremented by 1. Incrementing Y does not affect the flags.
LDPY A,B LDPY MX,B Y register 0100 1000 0100 1001 0100 1010 A register 1010 1000 1000 B register 1000 1000 1000 Memory (MX) 0010 0010 1000

r ← i3 to i0
1 1 1 0 0 0 r1 r0 i3 i2 i1 i0 E00H to E3FH
Loads immediate data i into the r-register.
LD A,6 LD MY,0 A register 0101 0110 0110 Memory (MY) 1001 1001 0000
1 1 1 0 1 1 0 0 r1 r0 q1 q0 EC0H to ECFH
The contents of the q-register are loaded into the r-register.
LD A,B LD B,MY A register 0010 0000 0000 B register 0000 0000 0110 Memory (MY) 0110 0110 0110
r ← q

1 0 0 1 r1 r0 FE4H to FE7H
Loads the four high-order bits of the stack pointer into the r-register.
LD MX,SPH LD A,SPH SPH 0111 0111 0111 A register 0000 0000 0111 Memory (MX) 1100 0111 0111
1 0 1 r1 r0 FF4H to FF7H
Loads the four low-order bits of the stack pointer into the r-register.
LD A,SPL LD MY,SPL SPL 1001 1001 1001 A register 0010 1001 1001 Memory (MY) 0000 0000 1001
r ← SPH · r ← SPL

1 1 1 0 1 0 1 0 0 1 r1 r0 EA4H to EA7H
Loads the four high-order bits of register X into the r-register.
LD B,XH LD MX,XH XH register 1010 1010 1010 B register 0010 1010 1010 Memory (MX) 0000 0000 1010
1 1 1 0 1 0 1 0 1 0 r1 r0 EA8H to EABH
Loads the four low-order bits of register X into the r-register.
LD MY,XL LD A,XL XL register 0000 0000 0000 A register 1101 1101 0000 Memory (MY) 0001 0000 0000
r ← XH · r ← XL

1 1 1 0 1 0 1 0 0 0 r1 r0 EA0H to EA3H
Loads the 4-bit page part of index register IX into the r-register.
LD MX,XP LD A,XP XP register 1111 1111 1111 A register 0010 0010 1111 Memory (MX) 0101 1111 1111
1 1 1 0 1 0 1 1 0 1 r1 r0 EB4H to EB7H
Loads the four high-order bits of register Y into the r-register.
LD A,YH LD MY,YH YH register 1010 1010 1010 A register 1100 1010 1010 Memory (MY) 1110 1110 1010
r ← XP · r ← YH

1 1 1 0 1 0 1 1 1 0 r1 r0 EB8H to EBBH
Loads the four low-order bits of register Y into the r-register.
LD B,YL LD MX,YL YL register 0000 0000 0000 B register 0110 0000 0000 Memory (MX) 1011 1011 0000
1 1 1 0 1 0 1 1 0 0 r1 r0 EB0H to EB3H
Loads the 4-bit page part of index register IY into the r-register.
LD MY,YP LD B,YP YP register 1010 1010 1010 B register 1100 1100 1010 Memory (MY) 0110 1010 1010
r ← YL · r ← YP

1 0 0 0 r1 r0 FE0H to FE3H
Loads the contents of the r-register into the four high-order bits of the stack pointer.
LD SPH,A LD SPH,MY SPH 1001 0011 1100 A register 0011 0011 0011 Memory (MY) 1100 1100 1100
1 0 0 r1 r0 FF0H to FF3H
Loads the contents of the r-register into the four low-order bits of the stack pointer.
LD SPL,B LD SPL,MX SPL 1011 0111 1111 B register 0111 0111 0111 Memory (MX) 1111 1111 1111
SPH ← r · SPL ← r

XH ← e7 to e4, XL ← e3 to e0
1 0 1 1 e7 e6 e5 e4 e3 e2 e1 e0 B00H to BFFH
Loads 8-bit immediate data e into register X.
LD X,6FH XH register 0000 0110 XL register 1011 1111
1 1 1 0 1 0 1 r1 r0 E84H to E87H
Loads the contents of the r-register into the four high-order bits of register X.
LD XH,A LD XH,MY XH register 0000 1011 0110 A register 1011 1011 1011 Memory (MY) 0110 0110 0110
XH ← r

1 1 1 0 1 0 0 0 1 0 r1 r0 E88H to E8BH
Loads the contents of the r-register into the four low-order bits of register X.
LD XL,MY LD XL,A XL register 0000 0010 1011 A register 1011 1011 1011 Memory (MY) 0010 0010 0010
1 1 1 0 1 0 r1 r0 E80H to E83H
Loads the contents of the r-register into the 4-bit page part of index register IX.
LD XP,B LD XP,MX XP register 1001 0001 1011 B register 0001 0001 0001 Memory (MX) 1011 1011 1011
XL ← r · XP ← r

YH ← e7 to e4, YL ← e3 to e0
1 0 0 0 e7 e6 e5 e4 e3 e2 e1 e0 800H to 8FFH
Loads 8-bit immediate data e into register Y.
LD Y,E1H YH register 0001 1110 YL register 1100 0001
1 1 1 0 1 0 0 1 0 1 r1 r0 E94H to E97H
Loads the contents of the r-register into the four high-order bits of register Y.
LD YH,B LD YH,MX YH register 0000 0110 0101 B register 0110 0110 0110 Memory (MX) 0101 0101 0101
YH ← r

1 1 1 0 1 0 0 1 1 0 r1 r0 E98H to E9BH
Loads the contents of the r-register into the four low-order bits of register Y.
LD YL,B LD YL,MX YL register 1011 1010 0111 B register 1010 1010 1010 Memory (MX) 0111 0111 0111
1 1 1 0 1 0 0 1 0 0 r1 r0 E90H to E93H
Loads the contents of the r-register into the 4-bit page part of index register IY.
LD YP,MX LD YP,A YP register 0011 0000 0100 A register 0100 0100 0100 Memory (MX) 0000 0000 0000
YL ← r · YP ← r

No operation (5 clock cycles)
1 0 1 1 FFBH
Increments the program counter by 1. Has no other effect for 5 clock cycles.
NOP5 PCB 0 0 PCP 0011 0011 PCS 0001 0011 0001 0100
No operation (7 clock cycles)
1 FFFH
Increments the program counter by 1. Has no other effect for 7 clock cycles.
NOP7 PCB 0 0 PCP 1010 1010 PCS 1001 1001 1001 1010

1 1 0 1 0 0 r1 r0 1 D0FH to D3FH
Not affected Set if the result is zero; otherwise, reset. Not affected Not affected
Performs a one's complement operation on the contents of the r-register.
NOT A NOT MY A register 1001 0110 0110 Memory (MY) 1111 1111 0000 Z flag 0 0 1
r ← r ∨ i3 to i0
1 1 0 0 1 1 r1 r0 i3 i2 i1 i0 CC0H to CFFH
Not affected Set if the result is zero; otherwise, reset. Not affected Not affected
Performs a logical OR operation between immediate data i and the contents of the r-register. The result is stored in the r-register.
OR B,5 OR MX,0BH B register 0100 0101 0101 Memory (MX) 0011 0011 0111 Z flag 0 0 0
r ← r

r ← r ∨ q
1 0 1 0 1 1 0 1 r1 r0 q1 q0 AD0H to ADFH
Not affected Set if the result is zero; otherwise, reset. Not affected Not affected
Performs a logical OR operation between the contents of the q-register and the contents of the r-register. The result is stored in the r-register.
OR MY,0 OR A,0CH A register 0011 0011 1111 Memory (MY) 0000 0000 0000 Z flag 0 1 0
F ← M(SP), SP ← SP + 1
1 0 1 1 0 1 0 FDAH
Set or Reset by M(SP) data Set or Reset by M(SP) data Set or Reset by M(SP) data Set or Reset by M(SP) data
Replaces the flags (F) with the contents of the data memory location addressed by the stack pointer. SP is incremented by 1.
POP F SP C0 C1 Memory (C0H) 1001 1001 Flags (I,D,Z,C) 0001 1001
23 22 21 20 M(SP) =
flag

r ← M(SP), SP ← SP + 1
1 0 1 0 0 r1 r0 FD0H to FD3H
Loads the contents of the data memory location addressed by the stack pointer into the r-register. SP is incremented by 1.
POP B SP C0 C1 Memory (C0H) 1001 1001 B register 0101 1001
23 22 21 20 M(SP) =
= r-register 20 21 22 23
XH ← M(SP), SP ← SP + 1
1 0 1 0 1 0 1 FD5H
Loads the contents of the data memory location addressed by the stack pointer into XH, the four high-order bits of X. SP is incremented by 1.
POP XH SP CE CF Memory (CEH) 0110 0110 XH register 0010 0110
23 22 21 20 M(SP) =
= XH 20 21 22 23

XL ← M(SP), SP ← SP + 1
1 0 1 0 1 1 0 FD6H
Loads the contents of the data memory location addressed by the stack pointer into XL, the four low-order bits of X. SP is incremented by 1.
POP XL SP C0 C1 Memory (C0H) 0001 0001 XL register 1101 0001
23 22 21 20 M(SP) =
= XL 20 21 22 23
XP ← M(SP), SP ← SP + 1
1 0 1 0 1 0 0 FD4H
Loads the contents of the data memory location addressed by the stack pointer into XP, the 4-bit page part of IX. SP is incremented by 1.
POP XP SP B4 B5 Memory (B4H) 0101 0101 XP register 0111 0101
23 22 21 20 M(SP) =
= XP 20 21 22 23

YH ← M(SP), SP ← SP + 1
1 0 1 1 0 0 0 FD8H
Loads the contents of the data memory location addressed by the stack pointer into YH, the four high-order bits of Y. SP is incremented by 1.
POP YH SP C1 C2 Memory (C1H) 1101 1101 YH register 0010 1101
23 22 21 20 M(SP) =
= YH 20 21 22 23
YL ← M(SP), SP ← SP + 1
1 0 1 1 0 0 1 FD9H
Loads the contents of the data memory location addressed by the stack pointer into YL, the four low-order bits of Y. SP is incremented by 1.
POP YL SP CA CB Memory (CAH) 0100 0100 YL register 0101 0100
23 22 21 20 M(SP) =
= YL 20 21 22 23

YP ← M(SP), SP ← SP + 1
1 0 1 0 1 1 1 FD7H
Loads the contents of the data memory location addressed by the stack pointer into YP, the 4-bit page part of IY. SP is incremented by 1.
POP YP SP C0 C1 Memory (C0H) 0000 0000 YP register 0001 0000
23 22 21 20 M(SP) =
= YP 20 21 22 23
NBP ← p4, NPP ← p3 to p0
1 1 1 0 0 1 0 p4 p3 p2 p1 p0 E40H to E5FH
Loads the most-significant bit of the 5-bit immediate data p to the new bank pointer (NBP) and the four low-order bits to the new page pointer (NPP).
PSET 1FH JP 00H PCB 0 0 1 NBP 0 1 1 PCP 1000 1000 1111 NPP 0001 1111 1111 PCS 0010 0011 0010 0100 0000 0000

SP' ← SP - 1, M(SP') ← F
1 0 0 1 0 1 0 FCAH
Decrements the stack pointer by 1 and loads the flags (F) into the data memory location addressed by SP.
PUSH F SP D0 CF Memory (CFH) 0100 0001 Flags (I,D,Z,C) 0001 0001
23 22 21 20 M(SP) =
flag
PUSH r Push r-register onto stack
PUSH r
SP' ← SP - 1, M(SP') ← r
1 0 r1 r0 FC0H to FC3H
Decrements the stack pointer by 1 and loads the contents of the r-register into the data memory location addressed by SP.
PUSH A SP D0 CF Memory (CFH) 1000 0010 A register 0010 0010
23 22 21 20 M(SP) =
= r-register 20 21 22 23

SP' ← SP - 1, M(SP') ← XH
1 0 0 0 1 0 1 FC5H
Decrements the stack pointer by 1 and loads the contents of XH, the four high- order bits of XHL, into the data memory location addressed by SP.
PUSH XH SP CC CB Memory (CBH) 0000 1000 XH register 1000 1000
23 22 21 20 M(SP) =
= XH 20 21 22 23
SP' ← SP - 1, M(SP') ← XL
1 0 0 0 1 1 0 FC6H
Decrements the stack pointer by 1 and loads the contents of XL, the four low-order bits of XHL, into the data memory location addressed by SP.
PUSH XL SP D0 CF Memory (CFH) 1111 0110 XL register 0110 0110
23 22 21 20 M(SP) =
= XL 20 21 22 23

SP' ← SP - 1, M(SP') ← XP
1 0 0 0 1 0 0 FC4H
Decrements the stack pointer by 1 and loads the contents of XP, the page part of IX, into the data memory location addressed by SP.
PUSH XP SP D0 CF Memory (CFH) 0011 0000 XP register 0000 0000
23 22 21 20 M(SP) =
= XP 20 21 22 23
SP' ← SP - 1, M(SP') ← YH
1 0 0 1 0 0 0 FC8H
Decrements the stack pointer by 1 and loads the contents of YH, the four high- order bits of YHL, into the data memory location addressed by SP.
PUSH YH SP BF BE Memory (BEH) 0100 0001 YH register 0001 0001
23 22 21 20 M(SP) =
= YH 20 21 22 23

SP' ← SP - 1, M(SP') ← YL
1 0 0 1 0 0 1 FC9H
Decrements the stack pointer by 1 and loads the contents of YL, the four low-order bits of YHL, into the data memory location addressed by SP.
PUSH YL SP D0 CF Memory (CFH) 0001 0111 YL register 0111 0111
23 22 21 20 M(SP) =
= YL 20 21 22 23
SP' ← SP - 1, M(SP') ← YP
1 0 0 0 1 1 1 FC7H
Decrements the stack pointer by 1 and loads the contents of YP, the page part of IY, into the data memory location addressed by SP.
PUSH YP SP C0 BF Memory (BFH) 1111 0000 YP register 0000 0000
23 22 21 20 M(SP) =
= YP 20 21 22 23

C ← 0
1 0 1 0 1 0 F5EH
Reset Not affected Not affected Not affected
Resets the C (carry) flag.
ADD A,4 RCF A register 1101 0001 0001 C flag 0 1 0
D ← 0
1 0 1 0 1 1 0 1 1 F5BH
Not affected Not affected Reset Not affected
Resets the D (decimal) flag.
ADD A,8 RDF LD A,6 ADD A,8 A register 0110 0100 0100 0110 1110 D flag 1 1 0 0 0 C flag 0 1 1 1 0 Z flag 0

PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2), SP ← SP + 3
1 0 1 FDFH
Jumps to the return address that was pushed onto the stack when the subroutine was called.
RET PCP 1101 0010 PCS 1000 1101 0010 1101 SP BD C0 Memory (SP) 1101 1101 Memory (SP+1) 0010 0010 Memory (SP+2) 0010 0010
RETD e Load immediate data e to memory, and increment X by 2, then return
PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2), SP ← SP + 3, M(X) ← e3 to e0, M(X+1) ← e7 to e4, X ← X + 2
0 0 0 1 e7 e6 e5 e4 e3 e2 e1 e0 100H to 1FFH
Loads 8-bit immediate data e into the data memory location addressed by IX and executes the RET command. X is incremented by 2.
RETD F5H PCP 0000 0010 PCS 1010 1011 0010 1101 SP BD C0 Memory (SP) 1101 1101 Memory (SP+1) 0010 0010 Memory (SP+2) 0010 0010 X register 0010 1010 0010 1100 Memory (2AH) 0000 0101 Memory (2BH) 0000 1111

PCSL ← M(SP), PCSH ← M(SP+1), PCP ← M(SP+2), SP ← SP + 3, PC ← PC + 1
1 0 1 0 FDEH
Jumps to the return address that was pushed onto the stack when the subroutine was called and then skips one instruction.
RETS PCP 0110 0000 PCS 1001 0000 0000 0111 SP B0 B3 Memory (SP) 0110 0110 Memory (SP+1) 0000 0000 Memory (SP+2) 0000 0000
d3 ← d2, d2 ← d1, d1 ← d0, d0 ← C, C ← d3
1 0 1 0 1 r1 r0 r1 r0 AF0H to AFFH
Set when the high-order bit of the r-register is 1; otherwise, reset. Not affected Not affected Not affected
Shifts the contents of the r-register one bit to the left. The high-order bit is shifted into the carry flag and the carry bit becomes the low-order bit of the r-register.
C C d3
d3 d2 d1 d0
d2 d1 d0
RLC A A register 0011 0111 C flag 1 0
r-register C C · r-register

d3 ← C, d2 ← d3, d1 ← d2, d0 ← d1, C ← d0
1 1 1 0 1 0 0 0 1 1 r1 r0 E8CH to E8FH
Set when the low-order bit of the r-register is 1; otherwise, reset. Not affected Not affected Not affected
Shifts the contents of the r-register one bit to the right. The low-order bit is shifted into the carry flag and the carry bit becomes the high-order bit of the r-register.
d3 d2 d1 r-register C
d3 d2 d1 d0
RRC MY Memory (MY) 1010 1101 C flag 1 0
F ← F ∧ i3 to i0
1 0 1 0 1 i3 i2 i1 i0 F50H to F5FH
Reset if i0 is zero; otherwise, not affected. Reset if i1 is zero; otherwise, not affected. Reset if i2 is zero; otherwise, not affected. Reset if i3 is zero; otherwise, not affected.
Performs a logical AND operation between immediate data i and the contents of the flags. The result is stored in each respective flag.
RST F,2 Flags (I,D,Z,C) 1010 0010
r-register · C d0

Z ← 0
1 0 1 0 1 1 1 0 1 F5DH
Not affected Reset Not affected Not affected
Resets the Z (zero) flag.
ADD A,3 RZF Z flag 0 1 0 A register 1101 0000 0000
r ← r - i3 to i0 - C
1 1 0 1 0 1 r1 r0 i3 i2 i1 i0 D40H to D7FH
Set if a borrow is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Subtracts the carry flag and immediate data i from the r-register.
SBC A,9 SBC MY,0DH A register 1000 1111 1111 Memory (MY) 1110 1110 0000 C flag 0 1 0 Z flag 0 0 1

r ← r - q - C
1 0 1 0 1 0 1 1 r1 r0 q1 q0 AB0H to ABFH
Set if a borrow is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Subtracts the carry flag and the contents of the q-register from the r-register.
SBC A,B SBC MY,MX A register 1110 1011 1011 B register 0010 0010 0010 Memory (MX) 1001 1001 1001 Memory (MY) 0100 0100 1011 C flag 1 0 1 Z flag 0 0 0
C ← 1
1 0 1 0 1 F41H
Set Not affected Not affected Not affected
Sets the C (carry) flag.
SCF C flag 0 1

SCPX MX,r Subtract with carry r-register from M(X) and increment X by 1
M(X) ← M(X) - r - C, X ← X + 1
1 0 0 1 1 1 0 r1 r0 F38H to F3BH
Set if a borrow is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Subtracts the carry flag and the contents of the r-register from the data memory location addressed by IX. X is incremented by 1. Incrementing X does not affect the flags.
SCPX MX,B X register 0101 0000 0101 0001 Memory (50H) 0110 0100 B register 0010 0010 C flag 0 0 Z flag 0 0
SCPY MY,r Subtract with carry r-register from M(Y) and increment Y by 1
M(Y) ← M(Y) - r - C, Y ← Y + 1
1 0 0 1 r1 r0 F3CH to F3FH
Set if a borrow is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Subtracts the carry flag and the contents of the r-register from the data memory location addressed by IY. Y is incremented by 1. Incrementing Y does not affect the flags.
SCPY MY,A Y register 1111 1111 0000 0000 Memory (FFH) 0111 0100 A register 0010 0010 C flag 1 0 Z flag 1 0

D ← 1
1 0 1 0 0 0 1 0 0 F44H
Not affected Not affected Set Not affected
Sets the D (decimal) flag.
SDF D flag 0 1
F ← F ∨ i3 to i0
1 0 1 0 0 i3 i2 i1 i0 F40H to F4FH
Set if i0 is 1; otherwise, not affected. Set if i1 is 1; otherwise, not affected. Set if i2 is 1; otherwise, not affected. Set if i3 is 1; otherwise, not affected.
Performs a logical OR operation between immediate data i and the contents of the flags. The results are stored in each respective flag.
SET F,0DH Flags (C,Z,D,I) 0011 1111

Stop CPU and peripheral oscillator
1 0 0 1 FF9H
Stops the CPU and the peripheral oscillator. When an interrupt occurs PCP and PCS are pushed onto the stack as the return address and the interrupt service routine is executed.
Instruction State PCP PCS I flag RUN 0100 0011 0000 1 SLP 0100 0011 0001 1 SLEEP Interrupt →
0001 0000 0001 0
r ← r - q
1 0 1 0 1 0 1 0 r1 r0 q1 q0 AA0H to AAFH
Set if a borrow is generated; otherwise, reset. Set if the result is zero; otherwise, reset. Not affected Not affected
Subtracts the contents of the q-register from the r-register.
SUB A,B A register 1100 1001 B register 0011 0011 C flag 1 0 Z flag 0 0

Z ← 1
1 0 1 0 1 0 F42H
Not affected Set Not affected Not affected
Sets the Z (zero) flag.
SZF Z flag 0 1
r ← r ∀ i3 to i0
1 1 0 1 0 0 r1 r0 i3 i2 i1 i0 D00H to D3FH
Not affected Set if the result is zero; otherwise, reset. Not affected Not affected
Performs an exclusive-OR operation between immediate data i and the contents of the r-register. The result is stored in the r-register.
XOR A,12 XOR MX,1 A register 0110 1010 1010 Memory (MX) 0001 0001 0000 Z flag 0 0 1

r ← r ∀ q
1 0 1 0 1 1 1 0 r1 r0 q1 q0 AE0H to AEFH
Not affected Set if the result is zero; otherwise, reset. Not affected Not affected
Performs an exclusive-OR operation between the contents of the q-register and the contents of the r-register. The result is stored in the r-register.
XOR A,MY XOR MX,B A register 0100 1100 1100 B register 1111 1111 1111 Memory (MX) 0111 0111 1000 Memory (MY) 1000 1000 1000 Z flag 0 0 0

A A register (4 bits) B B register (4 bits)
M(SP) Contents of the data memory location whose address is specified by stack pointer SP (4 bits) M(X) Contents of the data memory location whose address is specified by IX (4 bits)
M(Y) Contents of the data memory location whose address is specified by IY (4 bits) M(n3-0) Contents of the data memory location within the register area 00H to 0FH (4 bits)
MX Data memory location whose address is specified by IX MY Data memory location whose address is specified by IY
NBP New Bank Pointer (1 bit) NPP New Page Pointer (4 bits)
PCB Program Counter-Bank (1 bit) PCP Program Counter-Page (4 bits)
PCS Program Counter-Step (8 bits) PCSH Four high-order bits of PCS
PCSL Four low-order bits of PCS RP Register Pointer (4 bits)
SP Stack Pointer (8 bits) SPH Four high-order bits of SP
SPL Four low-order bits of SP X Eight low-order bits of IX, that is, XHL
XH Four high-order bits of X XL Four low-order bits of X
XP Four high-order bits of IX (page part) Y Eight low-order bits of IY, that is, YHL
YH Four high-order bits of Y YL Four low-order bits of Y
YP Four high-order bits of IY (page part) + Addition
– Subtraction ∧ Logical AND
∨ Logical OR ∀ Exclusive-OR
↓ Reset flag ↑ Set flag
↕ Set/reset flag ∗ Decimal addition/subtraction

APPENDIX A. S1C6200A (A DVANCED S1C6200) C ORE CPU
S1C6200A is an improved version of the S1C6200. In this section, S1C6200A is described only in terms of its differences with S1C6200. It is recommended that users of S1C6200A read this section.
S1C6200A is a Core CPU which has been made easier to integrate software by improving the parts of the S1C6200 CPU which are difficult to use. This section lists its differences with S1C6200; for items which are not included here, refer to the corre- sponding section in this manual.
and reading the interrupt factor flag during EI (enable interrupt flag) are possible. (However, consult the respective hardware manuals to find out whether these are possible with the CPU peripheral circuits.)
A2.1 Initial reset
The D (decimal) flag will be set as follows through initial reset:
Table A2.1.1 D (decimal) flag initial setting
D (decimal) flag setting
Owing to this, bugs due to omission of D (decimal) flag setting during software development can now be easily prevented.
For the values of other registers and flags during initial reset, see Section 2.5.4, "Initial reset".
Operation during interrupt issuance The time it takes to complete interrupt processing by hardware after the Core CPU receives the interrupt request has changed as follows:
Table A2.2.1 Required interrupt processing time
S1C6200
a) During instruction execution
12.5 to 24.5
12.5 to 19.5
12.5 to 17.5
b) At HALT mode
c) During PSET instruction execution
12.5 to 24.5
12.5 to 22.5
Figure A2.2.1 shows the timing chart of the S1C6200A interrupt.

INT1 (*1) INT2 (*1) JP (*2)
Interrupt processing:
12-clock instruction 7-clock instruction 5-clock instruction
... 12.5 to 24.5 clock cycles ... 12.5 to 19.5 clock cycles ... 12.5 to 17.5 clock cycles
INT1 and INT2 are dummy instructions Branches to the top of the interrupt service routine Status:
a) During instruction execution
Instruction 5-clock Instrruction Interrupt
INT1 (*1) INT2 (*1) JP (*2)
INT1 and INT2 are dummy instructions Branches to the top of the interrupt service routine Status:
b) At HALT mode
INT1 (*1) INT2 (*1) JP (*2)
... 12.5 to 24.5 clock cycles ... 12.5 to 22.5 clock cycles Interrupt processing:
PSET + JP
INT1 and INT2 are dummy instructions Branches to the top of the interrupt service routine Status:
c) During "PSET" instruction execution
Fig. A2.2.1 Timing chart of S1C6200A interrupt

<Reference 1> Writing on the interrupt mask register during EI This section describes the operation for writing on the interrupt mask register during EI (enable interrupt flag) in the regular 1-chip micro controller which uses S1C6200 Core CPU and in the regular 1-chip micro controller which uses S1C6200A Core CPU. For information on accurate operation, see the respective hardware manuals of the S1C62 Family.
Table A2.2.2 Writing on the interrupt mask register at EI
S1C6200
Writing on the interrupt mask register at EI
The operation during the instruction execution for writing "0" (i.e., to mask the interrupt factor) on the interrupt mask register at EI is shown in Figure A2.2.2. At this point, the interrupt is masked 0.5 clock before the start of the instruction execution through the 0.5 clock advance operation. Moreover, during the instruction execution for writing "1" (i.e., to cancel the interrupt mask) on the mask register at EI, it is the same as the ordinary interrupt timing as shown in Figure A2.2.2. In other words, if the interrupt factor flag value is set to "1", the interrupt processing by hardware will start in the next instruction execution cycle 0.5 clock before the completion of the instruction execution.
Fetch Execute Fetch Execute Fetch Execute Fetch
"0" is written to the interrupt mask register Execute next instruction INT1(interrupt processing)
"1" is written to the interrupt mask register
Corresponding interrupt factor flag
Fig. A2.2.2 Writing on the interrupt mask register and interrupt request generation
<Reference 2> Reading the interrupt factor flag during EI This section describes the operation for reading the interrupt factor flag during EI (enable interrupt flag) in the regular 1-chip micro controller which uses S1C6200 Core CPU and in the regular 1-chip micro control- ler which uses S1C6200A Core CPU. For information on accurate operation, see the respective hardware manuals of the S1C62 Family.
Table A2.2.3 Reading the interrupt factor flag at EI
S1C6200
Reading the interrupt factor flag at EI
At EI, reading the interrupt factor flag is possible but caution must be observed in the following case: when the value of the interrupt mask register corresponding to the interrupt factor flag which is to be read is set to "1" (unmasked). In this case, interrupt request may be issued to the CPU due to the timing by which the interrupt factor flag is set to "1", or the interrupt factor flag may be cleared by reading it and hence inter- rupt request will not be issued. Particularly when there are multiple interrupt factor flags in the same address, extra caution is required.

APPENDIX B. I NSTRUCTION I NDEX
A
ACPX MX,r Add with carry r-register to M(X), increment X by 1 28 ACPY MY,r Add with carry r-register to M(Y), increment Y by 1 28
ADC r,i Add with carry immediate data i to r-register 29 ADC r,q Add with carry q-register to r-register 29
ADC XH,i Add with carry immediate data i to XH 30 ADC XL,i Add with carry immediate data i to XL 30
ADC YH,i Add with carry immediate data i to YH 31 ADC YL,i Add with carry immediate data i to YL 31
ADD r,i Add immediate data i to r-register 32 ADD r,q Add q-register to r-register 32
AND r,i Logical AND immediate data i with r-register 33 AND r,q Logical AND q-register with r-register 33
CALZ s Call subroutine at page zero 34 CP r,i Compare immediate data i with r-register 35
CP r,q Compare q-register with r-register 35 CP XH,i Compare immediate data i with XH 36
CP XL,i Compare immediate data i with XL 36 CP YH,i Compare immediate data i with YH 37
CP YL,i Compare immediate data i with YL 37
DI Disable interrupts 39
FAN r,i Logical AND immediate data i with r-register for flag check 40 FAN r,q Logical AND q-register with r-register for flag check 40 F
INC Mn Increment memory by 1 41
INC SP Increment stack pointer by 1 42 INC X Increment X-register by 1 42
INC Y Increment Y-register by 1 43
JPBA Indirect jump using registers A and B 43
JP C,s Jump if carry flag is set 44 JP NC,s Jump if not carry 44
JP NZ,s Jump if not zero 45 JP s Jump 45
JP Z,s Jump if zero 46

LBPX MX,e Load immediate data e to memory, and increment X by 2 46
LD A,Mn Load memory into A-register 47 LD B,Mn Load memory into B-register 47
LD Mn,A Load A-register into memory 48 LD Mn,B Load B-register into memory 48
LDPX MX,i Load immediate data i into MX, increment X by 1 49 LDPX r,q Load q-register into r-register, increment X by 1 49
LDPY MY,i Load immediate data i into MY, increment Y by 1 50 LDPY r,q Load q-register into r-register, increment Y by 1 50
LD r,i Load immediate data i into r-register 51 LD r,q Load q-register into r-register 51
LD r,SPH Load SPH into r-register 52 LD r,SPL Load SPL into r-register 52
LD r,XH Load XH into r-register 53 LD r,XL Load XL into r-register 53
LD r,XP Load XP into r-register 54 LD r,YH Load YH into r-register 54
LD r,YL Load YL into r-register 55 LD r,YP Load YP into r-register 55
LD SPH,r Load r-register into SPH 56 LD SPL,r Load r-register into SPL 56
LD X,e Load immediate data e into X-register 57 LD XH,r Load r-register into XH 57
LD XL,r Load r-register into XL 58 LD XP,r Load r-register into XP 58
LD Y,e Load immediate data e into Y-register 59 LD YH,r Load r-register into YH 59
LD YL,r Load r-register into YL 60 LD YP,r Load r-register into YP 60
NOP7 No operation for 7 clock cycles 61 NOT r NOT r-register (one's complement) 62
O OR r,i Logical OR immediate data i with r-register 62 OR r,q Logical OR q-register with r-register 63
POP r Pop stack data into r-register 64 POP XH Pop stack data into XH 64
POP XL Pop stack data into XL 65 POP XP Pop stack data into XP 65
POP YH Pop stack data into YH 66 POP YL Pop stack data into YL 66
POP YP Pop stack data into YP 67 PSET p Page set 67
PUSH F Push flag onto stack 68

P
PUSH r Push r-register onto stack 68
PUSH XH Push XH onto stack 69 PUSH XL Push XL onto stack 69
PUSH XP Push XP onto stack 70 PUSH YH Push YH onto stack 70
PUSH YL Push YL onto stack 71 PUSH YP Push YP onto stack 71
RET Return from subroutine 73 RETD e Load immediate data e to memory, and increment X by 2, then return73
RETS Return then skip an instruction 74 RLC r Rotate r-register left with carry 74
RRC r Rotate r-register right with carry 75 RST F,i Reset flags using immediate data i 75
RZF Reset zero flag 76
S SBC r,i Subtract with carry immediate data i from r-register 76 SBC r,q Subtract with carry q-register from r-register 77
SCF Set carry flag 77 SCPX MX,r Subtract with carry r-register from M(X) and increment X by 1 78
SCPY MY,r Subtract with carry r-register from M(Y) and increment Y by 1 78 SDF Set decimal flag 79
SET F,i Set flags using immediate data i 79 SLP Sleep 80
SUB r,q Subtract q-register from r-register 80 SZF Set zero flag 81
X XOR r,i Exclusive-OR immediate data i with r-register 81 XOR r,q Exclusive-OR q-register with r-register 82

ASIA
EPSON ELECTRONICS AMERICA, INC.
EPSON (CHINA) CO., LTD. 23F, Beijing Silver Tower 2# North RD DongSanHuan ChaoYang District, Beijing, CHINA Phone: 64106655 Fax: 64107319
- HEADQUARTERS - 150 River Oaks Parkway San Jose, CA 95134, U.S.A. Phone: +1-408-922-0200 Fax: +1-408-922-0238
SHANGHAI BRANCH 4F, Bldg., 27, No. 69, Gui Qing Road Caohejing, Shanghai, CHINA Phone: 21-6485-5552 Fax: 21-6485-0775
West 1960 E. Grand Avenue EI Segundo, CA 90245, U.S.A. Phone: +1-310-955-5300 Fax: +1-310-955-5400
EPSON HONG KONG LTD. 20/F., Harbour Centre, 25 Harbour Road Wanchai, Hong Kong Phone: +852-2585-4600 Fax: +852-2827-4346 Telex: 65542 EPSCO HX
Central 101 Virginia Street, Suite 290 Crystal Lake, IL 60014, U.S.A. Phone: +1-815-455-7630 Fax: +1-815-455-7633
EPSON TAIWAN TECHNOLOGY & TRADING LTD. 10F, No. 287, Nanking East Road, Sec. 3 Taipei Phone: 02-2717-7360 Fax: 02-2712-9164 Telex: 24444 EPSONTB
Northeast 301 Edgewater Place, Suite 120 Wakefield, MA 01880, U.S.A. Phone: +1-781-246-3600 Fax: +1-781-246-5443
HSINCHU OFFICE 13F-3, No. 295, Kuang-Fu Road, Sec. 2 HsinChu 300 Phone: 03-573-9900 Fax: 03-573-9169
Southeast 3010 Royal Blvd. South, Suite 170 Alpharetta, GA 30005, U.S.A. Phone: +1-877-EEA-0020 Fax: +1-770-777-2637
EPSON SINGAPORE PTE., LTD. No. 1 Temasek Avenue, #36-00 Millenia Tower, SINGAPORE 039192 Phone: +65-337-7911 Fax: +65-334-2716
SEIKO EPSON CORPORATION KOREA OFFICE 50F, KLI 63 Bldg., 60 Yoido-dong Youngdeungpo-Ku, Seoul, 150-763, KOREA Phone: 02-784-6027 Fax: 02-767-3677
- HEADQUARTERS - Riesstrasse 15 80992 Munich, GERMANY Phone: +49-(0)89-14005-0 Fax: +49-(0)89-14005-110
SALES OFFICE Altstadtstrasse 176 51379 Leverkusen, GERMANY Phone: +49-(0)2171-5045-0 Fax: +49-(0)2171-5045-10
IC Marketing Department IC Marketing & Engineering Group 421-8, Hino, Hino-shi, Tokyo 191-8501, JAPAN Phone: +81-(0)42-587-5816 Fax: +81-(0)42-587-5624
UK BRANCH OFFICE Unit 2.4, Doncastle House, Doncastle Road Bracknell, Berkshire RG12 8PE, ENGLAND Phone: +44-(0)1344-381700 Fax: +44-(0)1344-381701
ED International Marketing Department Europe & U.S.A. 421-8, Hino, Hino-shi, Tokyo 191-8501, JAPAN Phone: +81-(0)42-587-5812 Fax: +81-(0)42-587-5564
FRENCH BRANCH OFFICE 1 Avenue de l' Atlantique, LP 915 Les Conquerants Z.A. de Courtaboeuf 2, F-91976 Les Ulis Cedex, FRANCE Phone: +33-(0)1-64862350 Fax: +33-(0)1-64862355
ED International Marketing Department Asia 421-8, Hino, Hino-shi, Tokyo 191-8501, JAPAN Phone: +81-(0)42-587-5814 Fax: +81-(0)42-587-5110
BARCELONA BRANCH OFFICE Barcelona Design Center Edificio Testa, Avda. Alcalde Barrils num. 64-68 E-08190 Sant Cugat del Vallès, SPAIN Phone: +34-93-544-2490 Fax: +34-93-544-2491

EPSON Electronic Devices Website
First issue February, 1989 Printed February, 2001 in Japan A M
Pagine di riferimento in questo manuale: produttore, supporto e download.
I possessori del prodotto e il nostro team di solito rispondono entro 24 ore, e la tua domanda sarà utile anche ad altri.
Invia la prima domanda: risponderanno altri possessori o il nostro team.