Advertisement
Diolum

TI86 ROM DIOLUM

May 19th, 2018
155
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.66 KB | None | 0 0
  1. *************************************
  2. * ____ __ __ __ _ _ _ _ *
  3. *( \( )/ \ ( ) / )( \( \/ ) *
  4. * ) D ( )(( O )/ (_/\) \/ (/ \/ \ *
  5. *(____/(__)\__/ \____/\____/\_)(_/ *
  6. * *
  7. * ___ ___ _ _ _ _ *
  8. * | | __ (_) |_ |_) / \ |\/| *
  9. * | _|_ (_) |_) | \ \_/ | | *
  10. * *
  11. *************************************
  12.  
  13.  
  14.  
  15.  
  16. *************************************
  17. * RESET *
  18. *************************************
  19.  
  20. 00000 3e 57 ld a,0x57 //puts 0x57 into a.
  21. 00002 d3 04 out (0x04),a //Writes the a into the port 0x04.
  22. 00004 c3 3e 0e jp 0x0e3e //unconditional jump to 0x0e3e
  23.  
  24.  
  25. *************************************
  26. * Routines *
  27. *************************************
  28.  
  29. 00007 ff rst 0x38 //ROM call 0x38
  30. 00008 c3 be 10 jp 0x10be //unconditional jump to 0x10be
  31. 0000b fd cb 07 46 bit 0,(iy+7) //tests if 0 specified bit is set to iy+7.
  32. 0000f c9 ret //return from the routine.
  33. 00010 c3 2f 1c jp 0x1c2f //unconditional jump to 0x1c2f
  34. 00013 fd cb 08 4e bit 1,(iy+8) //tests if 1 specified bit is set to iy+8.
  35. 00017 c9 ret //return from the routine.
  36. 00018 c3 7d 22 jp 0x227d //unconditional jump to 0x227d
  37. 0001b fd cb 03 c6 set 0,(iy+3) //tests if 0 specified bit is set to iy+3.
  38. 0001f c9 ret //return from the routine.
  39. 00020 c3 81 11 jp 0x1181 //unconditional jump to 0x1181
  40. 00023 3a 0f ce ld a,(0xce0f) //write 0xce0f to a
  41. 00026 b7 or a //?
  42. 00027 c9 ret //return from the routine.
  43. 00028 c3 4c 01 jp 0x014c //unconditional jump to 0x014c
  44. 0002b 97 sub a //substrate a from the Accumulator an writes back
  45. 0002c 32 0f ce ld (0xce0f),a //puts a into 0xce0f.
  46. 0002f c9 ret //return from the routine.
  47. 00030 c3 50 01 jp 0x0150 //unconditional jump to 0x0150
  48. 00033 7e ld a,(hl) //write hl into a.
  49. 00034 23 inc hl //increases hl by 1.
  50. 00035 66 ld h,(hl) //write hl into h.
  51. 00036 6f ld l,a //puts a into l.
  52. 00037 c9 ret //return from the routine.
  53.  
  54.  
  55. *************************************
  56. * ISR *
  57. *************************************
  58.  
  59.  
  60. 00038 08 ex af,af' //Exchanges two 16-bit values.
  61. 00039 d9 exx //exchanges BC, DE, and HL with shadow registers with BC', DE', and HL'.
  62. 0003a fd cb 23 56 bit 2,(iy+35) //tests if 2 specified bit is set to iy+35.
  63. 0003e 28 26 jr z,0x0066 //jumps to 0x0066 if z is set
  64. 00040 3a fd d2 ld a,(0xd2fd) //write 0xd2fd to a
  65. 00043 21 fe d2 ld hl,0xd2fe //puts 0xd2fe into hl.
  66. 00046 96 sub (hl) //substrate hl from the Accumulator an writes back
  67. 00047 21 25 d3 ld hl,0xd325 //puts 0xd325 into hl.
  68. 0004a 96 sub (hl) //substrate hl from the Accumulator an writes back
  69. 0004b 21 4d d3 ld hl,0xd34d //puts 0xd34d into hl.
  70. 0004e 96 sub (hl) //substrate hl from the Accumulator an writes back
  71. 0004f 21 75 d3 ld hl,0xd375 //puts 0xd375 into hl.
  72. 00052 96 sub (hl) //substrate hl from the Accumulator an writes back
  73. 00053 21 9d d3 ld hl,0xd39d //puts 0xd39d into hl.
  74. 00056 96 sub (hl) //substrate hl from the Accumulator an writes back
  75. 00057 21 c5 d3 ld hl,0xd3c5 //puts 0xd3c5 into hl.
  76. 0005a 96 sub (hl) //substrate hl from the Accumulator an writes back
  77. 0005b 20 05 jr nz,0x0062 //jumps to 0x0062 if z is reset
  78. 0005d cd fe d2 call 0xd2fe //Pushes 0xd2fe onto the stack and jumps to the label.
  79. 00060 18 04 jr 0x0066 //unconditional jump to 0x0066
  80. 00062 fd cb 23 96 res 2,(iy+35) //Resets byte 2 to zero.
  81. 00066 db 03 in a,(0x03) //Reads a value from a hardware port 0x03.
  82. 00068 1f rra //?
  83. 00069 38 24 jr c,0x008f //jumps to 0x008f if c is set
  84. 0006b 1f rra //?
  85. 0006c 38 28 jr c,0x0096 //jumps to 0x0096 if c is set
  86. 0006e 18 16 jr 0x0086 //jumps to 0x0086
  87. 00070 fd cb 1e 76 bit 6,(iy+30) //tests if 6 specified bit is set to iy+30.
  88. 00074 28 0e jr z,0x0084 //jumps to 0x0084 if z is set
  89. 00076 47 ld b,a //puts a into b.
  90. 00077 db 01 in a,(0x01) //Reads a value from a hardware port 0x01.
  91. 00079 4f ld c,a //puts a into c.
  92. 0007a 3e ff ld a,0xff //puts 0xff into a.
  93. 0007c d3 01 out (0x01),a //Writes the a into the port 0x01.
  94. 0007e cb 41 bit 0,c //tests if 0 specified bit is set to c.
  95. 00080 ca 5c 0c jp z,0x0c5c //jumps to 0x0c5c if z is set
  96. 00083 78 ld a,b //puts b into a.
  97. 00084 d3 03 out (0x03),a //Writes the a into the port 0x03.
  98. 00086 3e 0b ld a,0x0b //puts 0x0b into a.
  99. 00088 d3 03 out (0x03),a //Writes the a into the port 0x03.
  100. 0008a 08 ex af,af' //Exchanges two 16-bit values.
  101. 0008b d9 exx //?
  102. 0008c fb ei //enables the interrupts.
  103. 0008d ed 4d reti //Returns from an interrupt routine.
  104. 0008f cd d3 0b call 0x0bd3 //Pushes 0xd2fe onto the stack and jumps to the label.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement