home *** CD-ROM | disk | FTP | other *** search
/ messroms.de / 2007-01-13_www.messroms.de.zip / CPU / Z8 < prev    next >
Text File  |  2007-01-13  |  16KB  |  241 lines

  1. ----------------------------------------------------------------
  2. |                                                              |
  3. |                                                              |
  4. |                            Zilog                             |
  5. |                                                              |
  6. |                      ZZZZZZZ    88888                        |
  7. |                           Z    8     8                       |
  8. |                          Z     8     8                       |
  9. |                         Z       88888                        |
  10. |                        Z       8     8                       |
  11. |                       Z        8     8                       |
  12. |                      ZZZZZZZ    88888                        |
  13. |                                                              |
  14. |        Z8601/02/03/11/12/13 Single-Chip MICROCOMPUTER        |
  15. |                   Instruction Set Summary                    |
  16. |                                                              |
  17. |                                                              |
  18. |                                                              |
  19. |                                                              |
  20. |                    _________    _________                    |
  21. |                  _|         \__/         |_                  |
  22. |             +5V |_|1                   40|_| P36 -->         |
  23. |                  _|                      |_                  |
  24. |       <-- XTAL2 |_|2                   39|_| P31 <--         |
  25. |                  _|                      |_                  |
  26. |       --> XTAL1 |_|3                   38|_| P27 <-->        |
  27. |                  _|                      |_                  |
  28. |         <-- P37 |_|4                   37|_| P26 <-->        |
  29. |                  _|                      |_                  |
  30. |         --> P30 |_|5                   36|_| P25 <-->        |
  31. |           _____  _|                      |_                  |
  32. |       --> RESET |_|6                   35|_| P24 <-->        |
  33. |               _  _|                      |_                  |
  34. |         <-- R/W |_|7                   34|_| P23 <-->        |
  35. |              __  _|                      |_                  |
  36. |          <-- DS |_|8                   33|_| P22 <-->        |
  37. |              __  _|                      |_                  |
  38. |          <-- AS |_|9       Z8601       32|_| P21 <-->        |
  39. |                  _|        Z8603         |_                  |
  40. |         <-- P35 |_|10      Z8611       31|_| P20 <-->        |
  41. |                  _|        Z8613         |_                  |
  42. |             GND |_|11                  30|_| P33 <--         |
  43. |                  _|                      |_                  |
  44. |         --> P32 |_|12                  29|_| P34 -->         |
  45. |                  _|                      |_                  |
  46. |        <--> P00 |_|13                  28|_| P17 <-->        |
  47. |                  _|                      |_                  |
  48. |        <--> P01 |_|14                  27|_| P16 <-->        |
  49. |                  _|                      |_                  |
  50. |        <--> P02 |_|15                  26|_| P15 <-->        |
  51. |                  _|                      |_                  |
  52. |        <--> P03 |_|16                  25|_| P14 <-->        |
  53. |                  _|                      |_                  |
  54. |        <--> P04 |_|17                  24|_| P13 <-->        |
  55. |                  _|                      |_                  |
  56. |        <--> P05 |_|18                  23|_| P12 <-->        |
  57. |                  _|                      |_                  |
  58. |        <--> P06 |_|19                  22|_| P11 <-->        |
  59. |                  _|                      |_                  |
  60. |        <--> P07 |_|20                  21|_| P10 <-->        |
  61. |                   |______________________|                   |
  62. |                                                              |
  63. |                                                              |
  64. |                                                              |
  65. |                                                              |
  66. |                                                              |
  67. |                                                              |
  68. |Written by     Jonathan Bowen                                 |
  69. |               Programming Research Group                     |
  70. |               Oxford University Computing Laboratory         |
  71. |               8-11 Keble Road                                |
  72. |               Oxford OX1 3QD                                 |
  73. |               England                                        |
  74. |                                                              |
  75. |               Tel +44-865-273840                             |
  76. |                                                              |
  77. |Created        June 1982                                      |
  78. |Updated        April 1985                                     |
  79. |Issue          1.1                Copyright (C) J.P.Bowen 1985|
  80. ----------------------------------------------------------------
  81. ----------------------------------------------------------------
  82. |Mnemonic|Op|CZSVDH|#|Description            |Notes            |
  83. |--------+--+------+-+-----------------------+-----------------|
  84. |ADC d,s |1X|****0*|a|Add with Carry         |d=d+s+C          |
  85. |ADD d,s |0X|****0*|a|Add                    |d=d+s            |
  86. |AND d,s |5X|-**0--|a|Logical AND            |d=d&s            |
  87. |CALL d  |D4|------|b|Call subroutine        |-[SP]=PC,PC=d    |
  88. |CCF     |EF|*-----|c|Complement Carry Flag  |C=~C             |
  89. |CLR d   |B0|------|d|Clear                  |d=0              |
  90. |COM d   |60|-**0--|d|Complement             |d=~d             |
  91. |CP d,s  |AX|****--|a|Compare                |d-s              |
  92. |DA d    |40|***?--|d|Decimal Adjust         |d=BCD format     |
  93. |DEC d   |00|-***--|d|Decrement              |d=d-1            |
  94. |DECW d  |80|-***--|d|Decrement Word         |d=d-1            |
  95. |DI      |8F|------|c|Disable Interrupts     |IMR<7>=0         |
  96. |DJNZ r,d|rA|------|e|Dec. and Jump Non-Zero |r=r-1, if r<>0 JR|
  97. |EI      |9F|------|c|Enable Interrupts      |IMR<7>=1         |
  98. |INC d   |rE|-***--|f|Increment              |d=d+1            |
  99. |INCW d  |A0|-***--|d|Increment Word         |d=d+1            |
  100. |IRET    |BF|******|c|Interrupt Return       |{F,PC}=[SP]+,EI  |
  101. |JP c,d  |cD|------|g|Conditional Jump       |If c PC=d        |
  102. |JR c,d  |cB|------|h|Cond. Jump Relative    |If c PC=PC+d     |
  103. |LD d,s  |rC|------|i|Load                   |d=s              |
  104. |LDC d,s |C2|------|j|Load                   |d=s              |
  105. |LDCI d,s|C3|------|k|Load and Increment     |d=s,r=r+1,rr=rr+1|
  106. |LDE d,s |82|------|j|Load                   |d=s              |
  107. |LDEI d,s|83|------|k|Load and Increment     |d=s,r=r+1,rr=rr+1|
  108. |NOP     |FF|------|c|No Operation           |                 |
  109. |OR d,s  |4X|-**0--|a|Logical inclusive OR   |d=dvs            |
  110. |POP d   |50|------|d|Pop                    |d=[SP]+          |
  111. |PUSH s  |70|------|d|Push                   |-[SP]=s          |
  112. |RCF     |CF|------|c|Reset Carry Flag       |C=0              |
  113. |RET     |AF|------|c|Return                 |PC=[SP]+         |
  114. |RL d    |90|****--|d|Rotate Left            |d=d<-            |
  115. |RLC d   |10|****--|d|Rotate Left Circular   |d={C,d}<-        |
  116. |RR d    |E0|****--|d|Rotate Right           |d=->d            |
  117. |RRC d   |C0|****--|d|Rotate Right Circular  |d=->{C,d}        |
  118. |SBC d,s |3X|****1*|a|Subtract with Carry    |d=d-s-C          |
  119. |SCF     |DF|1-----|c|Set Carry Flag         |C=1              |
  120. |SRA d   |D0|***0--|d|Shift Right Arithmetic |d=d/2            |
  121. |SRP s   |31|------|k|Set Register Pointer   |RP=s             |
  122. |SUB d,s |2X|****1*|a|Subtract               |d=d-s            |
  123. |SWAP d  |F0|?**?--|d|Swap nibbles           |d<0:3><->d<4:7>  |
  124. |TCM d,s |6X|-**0--|a|Test Complement Memory |{~d}&s           |
  125. |TM d,s  |7X|-**0--|a|Test Memory            |d&s              |
  126. |XOR d,s |BX|-**0--|a|Logical Exclusive OR   |d=dxs            |
  127. |-----------+------+-+-----------------------------------------|
  128. | FLAGS     |-/*/  | |Unaffected/affected/   |Register 252     |
  129. |           |0/1/? | |reset/set/unknown.     |                 |
  130. | C         |C     | |Carry flag             |Bit 7            |
  131. | Z         | Z    | |Zero flag              |Bit 6            |
  132. | S         |  S   | |Sign flag              |Bit 5            |
  133. | V         |   V  | |Overflow flag          |Bit 4            |
  134. | D         |    D | |Decimal-adjust flag    |Bit 3            |
  135. | H         |     H| |Half-carry flag        |Bit 2            |
  136. | F2        |      | |User flag 2            |Bit 1            |
  137. | F1        |      | |User flag 1            |Bit 0            |
  138. |--------------------+-----------------------------------------|
  139. | c     = XXXXB      |Condition              |Top nibble of Op |
  140. |         1000B      |Always true            |If true          |
  141. | C     = 0111B      |Carry (C=1)            |If C=1           |
  142. | NC    = 1111B      |No carry (C=0)         |If C=0           |
  143. | Z     = 0110B      |Zero (Z=1)             |If Z=1           |
  144. | NZ    = 1110B      |Not zero (Z=0)         |If Z=0           |
  145. | PL    = 1101B      |Plus (S=0)             |If S=0           |
  146. | MI    = 0101B      |Minus (S=1)            |If S=1           |
  147. | OV    = 0100B      |Overflow (V=1)         |If V=1           |
  148. | NOV   = 1100B      |No overflow (V=0)      |If V=0           |
  149. | EQ    = 0110B      |Equal (Z=1)            |If Z=1           |
  150. | NE    = 1110B      |Not equal (Z=0)        |If Z=0           |
  151. | GE    = 1001B      |Greater than or equal  |If SxV=0         |
  152. | LT    = 0001B      |Less than              |If SxV=1         |
  153. | GT    = 1010B      |Greater than           |If Zv{SxV}=0     |
  154. | LE    = 0010B      |Less than or equal     |If Zv{SxV}=1     |
  155. | UGE   = 1111B      |Unsigned greater/equal |If C=0           |
  156. | ULT   = 0111B      |Unsigned less than     |If C=1           |
  157. | UGT   = 1011B      |Unsigned greater than  |If CvZ=0         |
  158. | ULE   = 0011B      |Unsigned less/equal    |If CvZ=1         |
  159. |         0000B      |Never true             |If false         |
  160. ----------------------------------------------------------------
  161. ----------------------------------------------------------------
  162. |Mnemonic            |Description                              |
  163. |--------------------+-----------------------------------------|
  164. | DA                 |Direct address                           |
  165. | IM                 |Immediate                                |
  166. | Ir                 |Indirect working register                |
  167. | IR                 |Indirect register or Ir                  |
  168. | Irr                |Indirect working register pair address   |
  169. | IRR                |Indirect register pair or Irr            |
  170. | r                  |Working register address                 |
  171. | R                  |Register or r                            |
  172. | RA                 |Relative address                         |
  173. | rr                 |Working register pair address            |
  174. | RR                 |Register pair or rr                      |
  175. | X                  |Indexed address                          |
  176. |--------------------+-----------------------------------------|
  177. | d                  |Destination location or contents         |
  178. | s                  |Source location or contents              |
  179. | #                  |Addressing mode type(s)                  |
  180. | #a                 |X=2-7: d,s=r,r/r,Ir/R,R/R,IR/R,IM/IR,IM  |
  181. | #b                 |Op=D4/D6: d=IRR/DA                 (CALL)|
  182. | #c                 |No operands                              |
  183. | #d                 |Op=X0/X1: d=R/IR                         |
  184. | #e                 |Op=rA: r=0-F, d=RA                 (DJNZ)|
  185. | #f                 |Op=rE/20/21: d=r/R/IR               (INC)|
  186. | #g                 |Op=cD/30: d=DA/IRR                   (JP)|
  187. | #h                 |Op=cB: d=RA                          (JR)|
  188. | #i                 |Op=rC/r8/r9/C7/ d,s=r,Im/r,R/R,r/r,X/    |
  189. |                    |   D7/E3/E4/E5/ X,r/r,Ir/R,R/R,IR/       |
  190. |                    |   E6/E7/F3/F5: R,Im/IR,Im/Ir,r/IR,R (LD)|
  191. | #j                 |Op=C2/D2: d,s=r,Irr/Irr,r       (LDC/LDE)|
  192. | #k                 |Op=C3/D3: d,s=Ir,Irr/Irr,Ir   (LDCI/LDEI)|
  193. |--------------------+-----------------------------------------|
  194. |           0 - 255  |Register file addresses|00H-FFH          |
  195. | P0    =   0        |Port 0                 |00H R/W          |
  196. | P1    =   1        |Port 1                 |01H R/W          |
  197. | P2    =   2        |Port 2                 |02H R/W          |
  198. | P3    =   3        |Port 3                 |03H R W          |
  199. |           4 - 127  |General purpose regs.  |04H-7FH R/W      |
  200. |         128 - 239  |Unused                 |80H-EFH          |
  201. | SIO   = 240        |Serial I/O             |F0H R/W          |
  202. | TMR   = 241        |Timer mode             |F1H R/W          |
  203. | T1    = 242        |Timer/counter 1        |F2H R/W          |
  204. | PRE1  = 243        |T1 prescaler           |F3H WO           |
  205. | T0    = 244        |Timer/counter 0        |F4H R/W          |
  206. | PRE0  = 245        |T0 prescaler           |F5H WO           |
  207. | P2M   = 246        |Port 2 mode            |F6H WO           |
  208. | P3M   = 247        |Port 3 mode            |F7H WO           |
  209. | P01M  = 248        |Ports 0-1 mode         |F8H WO           |
  210. | IPR   = 249        |Interrupt priority reg.|F9H WO           |
  211. | IRQ   = 250        |Interrupt request reg. |FAH R/W          |
  212. | IMR   = 251        |Interrupt mask reg.    |FBH R/W          |
  213. | FLAGS = 252        |Program control flags  |FCH R/W          |
  214. | RP    = 253        |Register pointer       |FDH R/W          |
  215. | SPH   = 254        |Stack pointer high byte|FEH R/W          |
  216. | SPL   = 255        |Stack pointer low byte |FFH R/W          |
  217. |--------------------+-----------------------------------------|
  218. | +                  |Add                                      |
  219. | -                  |Subtract                                 |
  220. | *                  |Multiply                                 |
  221. | /                  |Divide                                   |
  222. | &                  |Logical AND                              |
  223. | ~                  |Logical NOT                              |
  224. | v                  |Logical inclusive OR                     |
  225. | x                  |Logical exclusive OR                     |
  226. | <-                 |Rotate left                              |
  227. | ->                 |Rotate right                             |
  228. | <->                |Exchange                                 |
  229. | [ ]                |Indirect addressing                      |
  230. | [ ]+  -[ ]         |Auto-increment/decrement indirect address|
  231. | < >   < : >        |Bit number/range                         |
  232. | { }                |Combination of operands                  |
  233. |--------------------+-----------------------------------------|
  234. | Z8601              |Single-chip microcomputer with 2K ROM    |
  235. | Z8602              |Development device with memory interface |
  236. | Z8603              |Prototyping device with EPROM interface  |
  237. | Z8611              |Single-chip microcomputer with 4K ROM    |
  238. | Z8612              |Development device with memory interface |
  239. | Z8613              |Prototyping device with EPROM interface  |
  240. ----------------------------------------------------------------
  241.