trunk/hash/vz_cass.xml
| r242371 | r242372 | |
| 1 | | <?xml version="1.0"?> |
| 2 | | <!DOCTYPE softwarelist SYSTEM "softwarelist.dtd"> |
| 3 | | |
| 4 | | <!-- |
| 5 | | |
| 6 | | List of known tape releases by Dick Smith in Australia: |
| 7 | | |
| 8 | | X-7274 Attack of the Killer Tomatoes |
| 9 | | X-7231 Match Box |
| 10 | | X-7232 Poker |
| 11 | | X-7233 Hangman |
| 12 | | X-7234 Slot Machine/Knock Off/Russian Roulette |
| 13 | | X-7235 Blackjack |
| 14 | | X-7236 Circus (*) |
| 15 | | X-7237 Biorhythm/Pair Matching/Calendar |
| 16 | | X-7238 Horse Race |
| 17 | | X-7239 Invaders (*) |
| 18 | | X-7240 Dynasty Derby |
| 19 | | X-7241 Learjet |
| 20 | | X-7242 Ghost Hunter (*) |
| 21 | | X-7243 Hoppy (*) |
| 22 | | X-7244 Super Snake |
| 23 | | X-7245 Knights and Dragons |
| 24 | | X-7247 Star Blaster (*) |
| 25 | | X-7248 VZ-Asteroids |
| 26 | | X-7249 Air Traffic Controller |
| 27 | | X-7250 Lunar Lander |
| 28 | | X-7251 Statistics 1 |
| 29 | | X-7252 Statistics 2 |
| 30 | | X-7253 Matrix |
| 31 | | X-7254 Tennis Lesson/Golf Lesson |
| 32 | | X-7255 Introduction to BASIC |
| 33 | | X-7256 Elementary Geometry |
| 34 | | X-7257 Speed Reading |
| 35 | | X-7258 Typing Teacher |
| 36 | | X-7259 Mailing List |
| 37 | | X-7261 Portfolio Management |
| 38 | | X-7262 Discounted Cash Flow Analysis |
| 39 | | X-7263 Financial Ratio Analysis |
| 40 | | X-7264 Tennis (*) |
| 41 | | X-7265 Checkers |
| 42 | | X-7266 Planet Patrol (*) |
| 43 | | X-7268 Ladder Challenge (*) |
| 44 | | X-7270 Panik (*) |
| 45 | | X-7271 Othello |
| 46 | | X-7272 Dracula's Castle |
| 47 | | X-7273 Backgammon |
| 48 | | X-7275 VZ Chess (*) |
| 49 | | X-7276 Music Writer |
| 50 | | X-7278 Disassembler |
| 51 | | X-7279 Duel |
| 52 | | X-7280 Hex Utilities |
| 53 | | X-7281 Word Processor |
| 54 | | X-7282 Editor Assembler |
| 55 | | X-7285 Spell'O'Matic 1 & 2 |
| 56 | | X-7286 Spell'O'Matic 3 & 4 |
| 57 | | X-7287 Flashword 1 & 2 |
| 58 | | X-7288 Flashword 3 & 4 |
| 59 | | X-7289 Metric Spycatcher |
| 60 | | X-7290 Whizkid Spycatcher |
| 61 | | X-7330 Sprite Generator |
| 62 | | X-7331 Formula One |
| 63 | | X-7332 Galaxon (*) |
| 64 | | X-7333 Dawn Patrol (*) |
| 65 | | X-7339 Space RAM |
| 66 | | X-7342 Crash |
| 67 | | X-7344 Maze of Argon |
| 68 | | X-7345 Word Matching |
| 69 | | |
| 70 | | * = dumped |
| 71 | | |
| 72 | | Demonstration Tape (included with the VZ200) |
| 73 | | Demonstration Tape (included with the VZ300) |
| 74 | | |
| 75 | | --> |
| 76 | | |
| 77 | | <softwarelist name="vz_cass" description="Dick Smith VZ-200/300 cassettes"> |
| 78 | | |
| 79 | | <software name="chess"> |
| 80 | | <description>Chess</description> |
| 81 | | <year>198?</year> |
| 82 | | <publisher>Dick Smith</publisher> |
| 83 | | <info name="serial" value="X-7275" /> |
| 84 | | <part name="cass1" interface="vtech1_cass"> |
| 85 | | <dataarea name="cass" size="2854400"> |
| 86 | | <rom name="chess.wav" size="2854400" crc="7cc80cf3" sha1="770b09e8755fad97e12f320cd5fea3416669cd36" offset="0" /> |
| 87 | | </dataarea> |
| 88 | | </part> |
| 89 | | </software> |
| 90 | | |
| 91 | | <software name="circus"> |
| 92 | | <description>Circus</description> |
| 93 | | <year>198?</year> |
| 94 | | <publisher>Dick Smith</publisher> |
| 95 | | <info name="serial" value="X-7236" /> |
| 96 | | <part name="cass1" interface="vtech1_cass"> |
| 97 | | <dataarea name="cass" size="1317376"> |
| 98 | | <rom name="circus.wav" size="1317376" crc="ab3ba833" sha1="1b33e2f3f2389f61f2e815be626b5d84083be77e" offset="0" /> |
| 99 | | </dataarea> |
| 100 | | </part> |
| 101 | | </software> |
| 102 | | |
| 103 | | <software name="dawn"> |
| 104 | | <description>Dawn Patrol</description> |
| 105 | | <year>198?</year> |
| 106 | | <publisher>Dick Smith</publisher> |
| 107 | | <info name="serial" value="X-7333" /> |
| 108 | | <part name="cass1" interface="vtech1_cass"> |
| 109 | | <dataarea name="cass" size="3640544"> |
| 110 | | <rom name="dawn.wav" size="3640544" crc="22d096f5" sha1="ac480a16b6d6b8d6f08875e9c6ca13cadc413fa1" offset="0" /> |
| 111 | | </dataarea> |
| 112 | | </part> |
| 113 | | </software> |
| 114 | | |
| 115 | | <!-- Not released by Dick Smith? --> |
| 116 | | <software name="defpen"> |
| 117 | | <description>Defense Penetrator</description> |
| 118 | | <year>1982</year> |
| 119 | | <publisher>Cosmic Software</publisher> |
| 120 | | <info name="author" value="Tom Thiel" /> |
| 121 | | <part name="cass1" interface="vtech1_cass"> |
| 122 | | <dataarea name="cass" size="1926592"> |
| 123 | | <rom name="defpen.wav" size="1926592" crc="b3dfa117" sha1="b7b53d11483fd78dfc81484e0830e6f6913c6e47" offset="0" /> |
| 124 | | </dataarea> |
| 125 | | </part> |
| 126 | | </software> |
| 127 | | |
| 128 | | <software name="galaxon"> |
| 129 | | <description>Galaxon</description> |
| 130 | | <year>198?</year> |
| 131 | | <publisher>Dick Smith</publisher> |
| 132 | | <info name="serial" value="X-7332" /> |
| 133 | | <part name="cass1" interface="vtech1_cass"> |
| 134 | | <dataarea name="cass" size="1628976"> |
| 135 | | <rom name="galaxon.wav" size="1628976" crc="8909df05" sha1="4ee1ce9aa8538b8aad9d0839fdb1396335074945" offset="0" /> |
| 136 | | </dataarea> |
| 137 | | </part> |
| 138 | | </software> |
| 139 | | |
| 140 | | <software name="ghost"> |
| 141 | | <description>Ghost Hunter</description> |
| 142 | | <year>198?</year> |
| 143 | | <publisher>Dick Smith</publisher> |
| 144 | | <info name="author" value="Dubois and McNamara" /> |
| 145 | | <info name="serial" value="X-7242" /> |
| 146 | | <part name="cass1" interface="vtech1_cass"> |
| 147 | | <dataarea name="cass" size="1732336"> |
| 148 | | <rom name="ghost.wav" size="1732336" crc="b5ed2320" sha1="f58e328e0b20d453a1c0486fd8e10c5f3e7ecfa7" offset="0" /> |
| 149 | | </dataarea> |
| 150 | | </part> |
| 151 | | </software> |
| 152 | | |
| 153 | | <software name="hamsam"> |
| 154 | | <description>Hamburger Sam</description> |
| 155 | | <year>????</year> |
| 156 | | <publisher></publisher> |
| 157 | | <part name="cass1" interface="vtech1_cass"> |
| 158 | | <dataarea name="cass" size="5109472"> |
| 159 | | <rom name="hamsam.wav" size="5109472" crc="7aed86a7" sha1="b5061edb1401cea4aee97d8cd92c582c9c14e66b" offset="0" /> |
| 160 | | </dataarea> |
| 161 | | </part> |
| 162 | | </software> |
| 163 | | |
| 164 | | <software name="hoppy"> |
| 165 | | <description>Hoppy</description> |
| 166 | | <year>198?</year> |
| 167 | | <publisher>Dick Smith</publisher> |
| 168 | | <info name="serial" value="X-7243" /> |
| 169 | | <part name="cass1" interface="vtech1_cass"> |
| 170 | | <dataarea name="cass" size="3172080"> |
| 171 | | <rom name="hoppy.wav" size="3172080" crc="60e7e15a" sha1="1d56a04af700a94d44d6bb0ddfaf89213db39ce8" offset="0" /> |
| 172 | | </dataarea> |
| 173 | | </part> |
| 174 | | </software> |
| 175 | | |
| 176 | | <software name="invaders"> |
| 177 | | <description>Invaders</description> |
| 178 | | <year>198?</year> |
| 179 | | <publisher>Dick Smith</publisher> |
| 180 | | <info name="author" value="Dubois and McNamara" /> |
| 181 | | <info name="serial" value="X-7239" /> |
| 182 | | <part name="cass1" interface="vtech1_cass"> |
| 183 | | <dataarea name="cass" size="1723824"> |
| 184 | | <rom name="invaders.wav" size="1723824" crc="f959681e" sha1="e12bc9384e7fe1efc0ecff6356c3e3ded7ee8373" offset="0" /> |
| 185 | | </dataarea> |
| 186 | | </part> |
| 187 | | </software> |
| 188 | | |
| 189 | | <software name="ladder"> |
| 190 | | <description>Ladder Challenge</description> |
| 191 | | <year>198?</year> |
| 192 | | <publisher>Dick Smith</publisher> |
| 193 | | <info name="serial" value="X-7268" /> |
| 194 | | <part name="cass1" interface="vtech1_cass"> |
| 195 | | <dataarea name="cass" size="1622288"> |
| 196 | | <rom name="ladder.wav" size="1622288" crc="47ab9ccf" sha1="e6d72b7bc26b124c906b9c0e0015137ae8844a4d" offset="0" /> |
| 197 | | </dataarea> |
| 198 | | </part> |
| 199 | | </software> |
| 200 | | |
| 201 | | <software name="missile"> |
| 202 | | <description>Missile</description> |
| 203 | | <year>????</year> |
| 204 | | <publisher></publisher> |
| 205 | | <part name="cass1" interface="vtech1_cass"> |
| 206 | | <dataarea name="cass" size="5109776"> |
| 207 | | <rom name="missile.wav" size="5109776" crc="55a1fda4" sha1="1de495534447cee16d3db22b043d53b6d15f05fe" offset="0" /> |
| 208 | | </dataarea> |
| 209 | | </part> |
| 210 | | </software> |
| 211 | | |
| 212 | | <software name="panik"> |
| 213 | | <description>Panik</description> |
| 214 | | <year>198?</year> |
| 215 | | <publisher>Dick Smith</publisher> |
| 216 | | <info name="serial" value="X-7270" /> |
| 217 | | <part name="cass1" interface="vtech1_cass"> |
| 218 | | <dataarea name="cass" size="1708928"> |
| 219 | | <rom name="panik.wav" size="1708928" crc="8b8c4c5a" sha1="e9e2ae5c406f9ac79b186cb34b2849b9e2a477e3" offset="0" /> |
| 220 | | </dataarea> |
| 221 | | </part> |
| 222 | | </software> |
| 223 | | |
| 224 | | <software name="ppatrol"> |
| 225 | | <description>Planet Patrol</description> |
| 226 | | <year>198?</year> |
| 227 | | <publisher>Dick Smith</publisher> |
| 228 | | <info name="serial" value="X-7266" /> |
| 229 | | <part name="cass1" interface="vtech1_cass"> |
| 230 | | <dataarea name="cass" size="2107776"> |
| 231 | | <rom name="ppatrol.wav" size="2107776" crc="3eb828ed" sha1="b56777b732587856f554d978d844a3815ec50f69" offset="0" /> |
| 232 | | </dataarea> |
| 233 | | </part> |
| 234 | | </software> |
| 235 | | |
| 236 | | <software name="starblas"> |
| 237 | | <description>Star Blaster</description> |
| 238 | | <year>198?</year> |
| 239 | | <publisher>Dick Smith</publisher> |
| 240 | | <info name="serial" value="X-7247" /> |
| 241 | | <info name="usage" value="Needs 16k memory expansion" /> |
| 242 | | <part name="cass1" interface="vtech1_cass"> |
| 243 | | <dataarea name="cass" size="3327120"> |
| 244 | | <rom name="starblas.wav" size="3327120" crc="e6a5b55f" sha1="07715fd8104891d0d4d3b06b5609674ca93af920" offset="0" /> |
| 245 | | </dataarea> |
| 246 | | </part> |
| 247 | | </software> |
| 248 | | |
| 249 | | <software name="tennis"> |
| 250 | | <description>Tennis</description> |
| 251 | | <year>198?</year> |
| 252 | | <publisher>Dick Smith</publisher> |
| 253 | | <info name="serial" value="X-7264" /> |
| 254 | | <part name="cass1" interface="vtech1_cass"> |
| 255 | | <dataarea name="cass" size="2100784"> |
| 256 | | <rom name="tennis.wav" size="2100784" crc="3eb5ed00" sha1="6c2f2d4c9d60b6f2bd977eddd397d6dbdbfc52f1" offset="0" /> |
| 257 | | </dataarea> |
| 258 | | </part> |
| 259 | | </software> |
| 260 | | |
| 261 | | </softwarelist> |
trunk/src/emu/cpu/arcompact/arcompactdasm_ops.c
| r242371 | r242372 | |
| 344 | 344 | // fedc ba98 7654 3210 fedc ba98 7654 3210 |
| 345 | 345 | // fields |
| 346 | 346 | // 0001 0bbb ssss ssss SBBB DaaZ ZXAA AAAA |
| 347 | | int size = 4; |
| 348 | 347 | |
| 348 | |
| 349 | 349 | int A = (op & 0x0000003f) >> 0; //op &= ~0x0000003f; |
| 350 | 350 | int X = (op & 0x00000040) >> 6; //op &= ~0x00000040; |
| 351 | 351 | int Z = (op & 0x00000180) >> 7; //op &= ~0x00000180; |
| r242371 | r242372 | |
| 359 | 359 | int breg = b | (B << 3); |
| 360 | 360 | int sdat = s | (S << 8); // todo - signed |
| 361 | 361 | |
| 362 | | UINT32 limm = 0; |
| 363 | | if (breg == LIMM_REG) |
| 364 | | { |
| 365 | | GET_LIMM_32; |
| 366 | | size = 8; |
| 367 | | } |
| 368 | | |
| 369 | 362 | output += sprintf( output, "LD"); |
| 370 | 363 | output += sprintf( output, "%s", datasize[Z]); |
| 371 | 364 | output += sprintf( output, "%s", dataextend[X]); |
| r242371 | r242372 | |
| 374 | 367 | output += sprintf( output, " "); |
| 375 | 368 | output += sprintf( output, "%s, ", regnames[A]); |
| 376 | 369 | output += sprintf( output, "["); |
| 377 | | if (breg == LIMM_REG) output += sprintf( output, "(%08x), ", limm); |
| 378 | | else output += sprintf( output, "%s, ", regnames[breg]); |
| 370 | output += sprintf( output, "%s, ", regnames[breg]); |
| 379 | 371 | output += sprintf( output, "%d", sdat); |
| 380 | 372 | output += sprintf( output, "]"); |
| 381 | 373 | |
| 382 | | return size; |
| 374 | return 4; |
| 383 | 375 | } |
| 384 | 376 | |
| 385 | 377 | int arcompact_handle03_dasm(DASM_OPS_32) |
| 386 | 378 | { |
| 387 | | int size = 4; |
| 388 | 379 | // bitpos |
| 389 | | // 1111 1111 1111 1111 0000 0000 0000 0000 |
| 390 | | // fedc ba98 7654 3210 fedc ba98 7654 3210 |
| 380 | // 11111 111 11111111 0 000 000000 0 00 00 0 |
| 381 | // fedcb a98 76543210 f edc ba9876 5 43 21 0 |
| 391 | 382 | // fields |
| 392 | | // 0001 1bbb ssss ssss SBBB CCCC CCDa aZZR |
| 393 | | int B = (op & 0x00007000) >> 12;// op &= ~0x00007000; |
| 394 | | int S = (op & 0x00008000) >> 15;// op &= ~0x00008000; |
| 395 | | int s = (op & 0x00ff0000) >> 16;// op &= ~0x00ff0000; |
| 396 | | int b = (op & 0x07000000) >> 24;// op &= ~0x07000000; |
| 383 | // 00011 bbb ssssssss S BBB CCCCCC D aa ZZ R |
| 397 | 384 | |
| 398 | | int breg = b | (B << 3); |
| 399 | | int sdat = s | (S << 8); // todo - signed |
| 400 | | |
| 401 | | int R = (op & 0x00000001) >> 0; op &= ~0x00000001; |
| 402 | | int Z = (op & 0x00000006) >> 1; op &= ~0x00000006; |
| 403 | | int a = (op & 0x00000018) >> 3; op &= ~0x00000018; |
| 404 | | int D = (op & 0x00000020) >> 5; op &= ~0x00000020; |
| 405 | | int C = (op & 0x00000fc0) >> 6; op &= ~0x00000fc0; |
| 406 | | |
| 407 | | UINT32 limm = 0; |
| 408 | | if (breg == LIMM_REG) |
| 409 | | { |
| 410 | | GET_LIMM_32; |
| 411 | | size = 8; |
| 412 | | } |
| 413 | | |
| 414 | | |
| 415 | | output += sprintf( output, "ST"); |
| 416 | | output += sprintf( output, "%s", datasize[Z]); |
| 417 | | output += sprintf( output, "%s", addressmode[a]); |
| 418 | | output += sprintf( output, "%s", cachebit[D]); |
| 419 | | output += sprintf( output, " "); |
| 420 | | |
| 421 | | output += sprintf( output, "%s, ", regnames[C]); |
| 422 | | if (breg == LIMM_REG) output += sprintf( output, "(%08x), ", limm); |
| 423 | | else output += sprintf( output, "%s, ", regnames[breg]); |
| 424 | | output += sprintf( output, "%d", sdat); |
| 425 | | |
| 426 | | if (R) output += sprintf( output, "(reserved bit set)"); |
| 427 | | |
| 428 | | |
| 429 | | return size; |
| 385 | print("ST r+o (%08x)", op ); |
| 386 | return 4; |
| 430 | 387 | } |
| 431 | 388 | |
| 432 | 389 | |
| 433 | | int arcompact_handle04_helper_dasm(char *output, offs_t pc, UINT32 op, const UINT8* oprom, const char* optext, int ignore_dst, int b_reserved) |
| 390 | int arcompact_handle04_helper_dasm(char *output, offs_t pc, UINT32 op, const UINT8* oprom, const char* optext, int ignore_dst) |
| 434 | 391 | { |
| 435 | 392 | // PP |
| 436 | 393 | // 0010 0bbb 00ii iiii FBBB CCCC CCAA AAAA |
| r242371 | r242372 | |
| 444 | 401 | |
| 445 | 402 | output += sprintf( output, "%s", optext); |
| 446 | 403 | output += sprintf( output, "%s", flagbit[F]); |
| 447 | | // output += sprintf( output, " p(%d)", p); |
| 448 | | |
| 449 | | |
| 450 | | if (!b_reserved) |
| 451 | | { |
| 452 | | output += sprintf(output, " %s, ", regnames[breg]); |
| 453 | | } |
| 454 | | else |
| 455 | | { |
| 456 | | if (breg) output += sprintf(output, "reserved(%s), ", regnames[breg]); |
| 457 | | } |
| 404 | output += sprintf( output, " p(%d)", p); |
| 405 | output += sprintf( output, " %s, ", regnames[breg]); |
| 458 | 406 | |
| 459 | | |
| 460 | 407 | if (p == 0) |
| 461 | 408 | { |
| 462 | 409 | // 0010 0bbb 00ii iiii FBBB CCCC CCAA AAAA |
| r242371 | r242372 | |
| 470 | 417 | GET_LIMM_32; |
| 471 | 418 | size = 8; |
| 472 | 419 | output += sprintf( output, "(%08x) ", limm ); |
| 473 | | if (!ignore_dst) output += sprintf( output, "DST(%s)", regnames[A]); |
| 474 | | else |
| 475 | | { |
| 476 | | if (A) output += sprintf(output, "unused(%s)", regnames[A]); |
| 477 | | } |
| 420 | if (!ignore_dst) output += sprintf( output, "A(%s)", regnames[A]); |
| 421 | else output += sprintf( output, "unused(%s)", regnames[A]); |
| 478 | 422 | } |
| 479 | 423 | else |
| 480 | 424 | { |
| 481 | 425 | output += sprintf( output, "C(%s) ", regnames[C]); |
| 482 | | if (!ignore_dst) output += sprintf( output, "DST(%s)", regnames[A]); |
| 483 | | else |
| 484 | | { |
| 485 | | if (A) output += sprintf(output, "unused(%s)", regnames[A]); |
| 486 | | } |
| 426 | if (!ignore_dst) output += sprintf( output, "A(%s)", regnames[A]); |
| 427 | else output += sprintf( output, "unused(%s)", regnames[A]); |
| 487 | 428 | |
| 488 | 429 | } |
| 489 | 430 | } |
| r242371 | r242372 | |
| 494 | 435 | int A = (op & 0x0000003f) >> 0; op &= ~0x0000003f; |
| 495 | 436 | |
| 496 | 437 | output += sprintf( output, "U(%02x) ", U ); |
| 497 | | if (!ignore_dst) output += sprintf( output, "DST(%s)", regnames[A]); |
| 498 | | else |
| 499 | | { |
| 500 | | if (A) output += sprintf(output, "unused(%s)", regnames[A]); |
| 501 | | } |
| 438 | if (!ignore_dst) output += sprintf( output, "A(%s)", regnames[A]); |
| 439 | else output += sprintf( output, "unused(%s)", regnames[A]); |
| 502 | 440 | } |
| 503 | 441 | else if (p == 2) |
| 504 | 442 | { |
| r242371 | r242372 | |
| 534 | 472 | |
| 535 | 473 | int arcompact_handle04_00_dasm(DASM_OPS_32) |
| 536 | 474 | { |
| 537 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD", 0,0); |
| 475 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD", 0); |
| 538 | 476 | } |
| 539 | 477 | |
| 540 | 478 | int arcompact_handle04_01_dasm(DASM_OPS_32) |
| 541 | 479 | { |
| 542 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADC", 0,0); |
| 480 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADC", 0); |
| 543 | 481 | } |
| 544 | 482 | |
| 545 | 483 | int arcompact_handle04_02_dasm(DASM_OPS_32) |
| 546 | 484 | { |
| 547 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB", 0,0); |
| 485 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB", 0); |
| 548 | 486 | } |
| 549 | 487 | |
| 550 | 488 | int arcompact_handle04_03_dasm(DASM_OPS_32) |
| 551 | 489 | { |
| 552 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SBC", 0,0); |
| 490 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SBC", 0); |
| 553 | 491 | } |
| 554 | 492 | |
| 555 | 493 | int arcompact_handle04_04_dasm(DASM_OPS_32) |
| 556 | 494 | { |
| 557 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "AND", 0,0); |
| 495 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "AND", 0); |
| 558 | 496 | } |
| 559 | 497 | |
| 560 | 498 | int arcompact_handle04_05_dasm(DASM_OPS_32) |
| 561 | 499 | { |
| 562 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "OR", 0,0); |
| 500 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "OR", 0); |
| 563 | 501 | } |
| 564 | 502 | |
| 565 | 503 | int arcompact_handle04_06_dasm(DASM_OPS_32) |
| 566 | 504 | { |
| 567 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BIC", 0,0); |
| 505 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BIC", 0); |
| 568 | 506 | } |
| 569 | 507 | |
| 570 | 508 | int arcompact_handle04_07_dasm(DASM_OPS_32) |
| 571 | 509 | { |
| 572 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "XOR", 0,0); |
| 510 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "XOR", 0); |
| 573 | 511 | } |
| 574 | 512 | |
| 575 | 513 | int arcompact_handle04_08_dasm(DASM_OPS_32) |
| 576 | 514 | { |
| 577 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MAX", 0,0); |
| 515 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MAX", 0); |
| 578 | 516 | } |
| 579 | 517 | |
| 580 | 518 | int arcompact_handle04_09_dasm(DASM_OPS_32) |
| 581 | 519 | { |
| 582 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MIN", 0,0); |
| 520 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MIN", 0); |
| 583 | 521 | } |
| 584 | 522 | |
| 585 | 523 | |
| 586 | 524 | int arcompact_handle04_0a_dasm(DASM_OPS_32) |
| 587 | 525 | { |
| 588 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MOV", 1,0); |
| 526 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MOV", 1); |
| 589 | 527 | } |
| 590 | 528 | |
| 591 | 529 | int arcompact_handle04_0b_dasm(DASM_OPS_32) |
| 592 | 530 | { |
| 593 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "TST", 1,0); |
| 531 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "TST", 1); |
| 594 | 532 | } |
| 595 | 533 | |
| 596 | 534 | int arcompact_handle04_0c_dasm(DASM_OPS_32) |
| 597 | 535 | { |
| 598 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "CMP", 1,0); |
| 536 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "CMP", 1); |
| 599 | 537 | } |
| 600 | 538 | |
| 601 | 539 | int arcompact_handle04_0d_dasm(DASM_OPS_32) |
| 602 | 540 | { |
| 603 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "RCMP", 1,0); |
| 541 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "RCMP", 1); |
| 604 | 542 | } |
| 605 | 543 | |
| 606 | 544 | int arcompact_handle04_0e_dasm(DASM_OPS_32) |
| 607 | 545 | { |
| 608 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "RSUB", 0,0); |
| 546 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "RSUB", 0); |
| 609 | 547 | } |
| 610 | 548 | |
| 611 | 549 | int arcompact_handle04_0f_dasm(DASM_OPS_32) |
| 612 | 550 | { |
| 613 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BSET", 0,0); |
| 551 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BSET", 0); |
| 614 | 552 | } |
| 615 | 553 | |
| 616 | 554 | int arcompact_handle04_10_dasm(DASM_OPS_32) |
| 617 | 555 | { |
| 618 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BCLR", 0,0); |
| 556 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BCLR", 0); |
| 619 | 557 | } |
| 620 | 558 | |
| 621 | 559 | int arcompact_handle04_11_dasm(DASM_OPS_32) |
| 622 | 560 | { |
| 623 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BTST", 0,0); |
| 561 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BTST", 0); |
| 624 | 562 | } |
| 625 | 563 | |
| 626 | 564 | int arcompact_handle04_12_dasm(DASM_OPS_32) |
| 627 | 565 | { |
| 628 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BXOR", 0,0); |
| 566 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BXOR", 0); |
| 629 | 567 | } |
| 630 | 568 | |
| 631 | 569 | int arcompact_handle04_13_dasm(DASM_OPS_32) |
| 632 | 570 | { |
| 633 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BMSK", 0,0); |
| 571 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "BMSK", 0); |
| 634 | 572 | } |
| 635 | 573 | |
| 636 | 574 | int arcompact_handle04_14_dasm(DASM_OPS_32) |
| 637 | 575 | { |
| 638 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD1", 0,0); |
| 576 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD1", 0); |
| 639 | 577 | } |
| 640 | 578 | |
| 641 | 579 | int arcompact_handle04_15_dasm(DASM_OPS_32) |
| 642 | 580 | { |
| 643 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD2", 0,0); |
| 581 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD2", 0); |
| 644 | 582 | } |
| 645 | 583 | |
| 646 | 584 | int arcompact_handle04_16_dasm(DASM_OPS_32) |
| 647 | 585 | { |
| 648 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD3", 0,0); |
| 586 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "ADD3", 0); |
| 649 | 587 | } |
| 650 | 588 | |
| 651 | 589 | int arcompact_handle04_17_dasm(DASM_OPS_32) |
| 652 | 590 | { |
| 653 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB1", 0,0); |
| 591 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB1", 0); |
| 654 | 592 | } |
| 655 | 593 | |
| 656 | 594 | int arcompact_handle04_18_dasm(DASM_OPS_32) |
| 657 | 595 | { |
| 658 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB2", 0,0); |
| 596 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB2", 0); |
| 659 | 597 | } |
| 660 | 598 | |
| 661 | 599 | int arcompact_handle04_19_dasm(DASM_OPS_32) |
| 662 | 600 | { |
| 663 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB3", 0,0); |
| 601 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "SUB3", 0); |
| 664 | 602 | } |
| 665 | 603 | |
| 666 | 604 | int arcompact_handle04_1a_dasm(DASM_OPS_32) |
| 667 | 605 | { |
| 668 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPY", 0,0); |
| 606 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPY", 0); |
| 669 | 607 | } // * |
| 670 | 608 | |
| 671 | 609 | int arcompact_handle04_1b_dasm(DASM_OPS_32) |
| 672 | 610 | { |
| 673 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYH", 0,0); |
| 611 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYH", 0); |
| 674 | 612 | } // * |
| 675 | 613 | |
| 676 | 614 | int arcompact_handle04_1c_dasm(DASM_OPS_32) |
| 677 | 615 | { |
| 678 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYHU", 0,0); |
| 616 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYHU", 0); |
| 679 | 617 | } // * |
| 680 | 618 | |
| 681 | 619 | int arcompact_handle04_1d_dasm(DASM_OPS_32) |
| 682 | 620 | { |
| 683 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYU", 0,0); |
| 621 | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "MPYU", 0); |
| 684 | 622 | } // * |
| 685 | 623 | |
| 686 | 624 | |
| 687 | 625 | |
| 688 | 626 | int arcompact_handle04_20_dasm(DASM_OPS_32) |
| 689 | 627 | { |
| 690 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "J", 1,1); |
| 691 | | } |
| 628 | // todo, other bits (in none long immediate mode at least) |
| 692 | 629 | |
| 630 | int size = 4; |
| 631 | int C = (op & 0x00000fc0) >> 6; |
| 632 | UINT8 condition = op & 0x0000001f; |
| 693 | 633 | |
| 634 | op &= ~0x00000fc0; |
| 635 | |
| 636 | if (C == LIMM_REG) |
| 637 | { |
| 638 | UINT32 limm; |
| 639 | GET_LIMM_32; |
| 640 | size = 8; |
| 641 | |
| 642 | print("J(%s) %08x (%08x)", conditions[condition], limm, op); |
| 643 | } |
| 644 | else |
| 645 | { |
| 646 | print("J(%s) (r%d) (%08x)", conditions[condition], C, op); |
| 647 | } |
| 694 | 648 | |
| 695 | | int arcompact_handle04_21_dasm(DASM_OPS_32) |
| 696 | | { |
| 697 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "J.D", 1,1); |
| 649 | return size; |
| 698 | 650 | } |
| 699 | 651 | |
| 700 | | int arcompact_handle04_22_dasm(DASM_OPS_32) |
| 701 | | { |
| 702 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "JL", 1,1); |
| 703 | | } |
| 704 | 652 | |
| 705 | | int arcompact_handle04_23_dasm(DASM_OPS_32) |
| 706 | | { |
| 707 | | return arcompact_handle04_helper_dasm(output, pc, op, oprom, "JL.D", 1,1); |
| 708 | | } |
| 709 | 653 | |
| 654 | int arcompact_handle04_21_dasm(DASM_OPS_32) { print("Jcc.D (%08x)", op); return 4;} |
| 655 | int arcompact_handle04_22_dasm(DASM_OPS_32) { print("JLcc (%08x)", op); return 4;} |
| 656 | int arcompact_handle04_23_dasm(DASM_OPS_32) { print("JLcc.D (%08x)", op); return 4;} |
| 710 | 657 | |
| 711 | 658 | |
| 712 | 659 | |
| 660 | |
| 713 | 661 | int arcompact_handle04_28_dasm(DASM_OPS_32) { print("LPcc (%08x)", op); return 4;} |
| 714 | 662 | int arcompact_handle04_29_dasm(DASM_OPS_32) { print("FLAG (%08x)", op); return 4;} |
| 715 | 663 | int arcompact_handle04_2a_dasm(DASM_OPS_32) { print("LR (%08x)", op); return 4;} |
| r242371 | r242372 | |
| 742 | 690 | |
| 743 | 691 | |
| 744 | 692 | |
| 745 | | // format on these is.. |
| 746 | 693 | |
| 747 | | // 0010 0bbb aa11 0ZZX DBBB CCCC CCAA AAAA |
| 748 | | // note, bits 11 0ZZX are part of the sub-opcode # already - this is a special encoding |
| 749 | | int arcompact_handle04_3x_helper_dasm(char *output, offs_t pc, UINT32 op, const UINT8* oprom, int dsize, int extend) |
| 750 | | { |
| 751 | | int size = 4; |
| 752 | | output += sprintf(output, "LD"); |
| 753 | | output += sprintf(output, "%s", datasize[dsize]); |
| 754 | | output += sprintf(output, "%s", dataextend[extend]); |
| 755 | 694 | |
| 756 | | int mode = (op & 0x00c00000) >> 22; op &= ~0x00c00000; |
| 757 | | int b = (op & 0x07000000) >> 24; op &= ~0x07000000; |
| 758 | | int B = (op & 0x00007000) >> 12; op &= ~0x00007000; |
| 759 | | int breg = b | (B << 3); |
| 760 | | int D = (op & 0x00008000) >> 15;op &= ~0x00008000; |
| 761 | | int C = (op & 0x00000fc0) >> 6; op &= ~0x00000fc0; |
| 762 | | int A = (op & 0x0000003f) >> 0; op &= ~0x0000003f; |
| 695 | int arcompact_handle04_30_dasm(DASM_OPS_32) { print("LD r-r (basecase 0x30) (%08x)", op); return 4;} |
| 696 | int arcompact_handle04_31_dasm(DASM_OPS_32) { print("LD r-r (basecase 0x31) (%08x)", op); return 4;} |
| 697 | int arcompact_handle04_32_dasm(DASM_OPS_32) { print("LD r-r (basecase 0x32) (%08x)", op); return 4;} |
| 698 | int arcompact_handle04_33_dasm(DASM_OPS_32) { print("LD r-r (basecase 0x33) (%08x)", op); return 4;} |
| 699 | int arcompact_handle04_34_dasm(DASM_OPS_32) { print("LD r-r (basecase 0x34) (%08x)", op); return 4;} |
| 700 | int arcompact_handle04_35_dasm(DASM_OPS_32) { print("LD r-r (basecase 0x35) (%08x)", op); return 4;} |
| 701 | int arcompact_handle04_36_dasm(DASM_OPS_32) { print("LD r-r (basecase 0x36) (%08x)", op); return 4;} |
| 702 | int arcompact_handle04_37_dasm(DASM_OPS_32) { print("LD r-r (basecase 0x37) (%08x)", op); return 4;} |
| 763 | 703 | |
| 764 | | output += sprintf(output, "%s", addressmode[mode]); |
| 765 | | output += sprintf(output, "%s", cachebit[D]); |
| 766 | 704 | |
| 767 | | output += sprintf( output, "DST(%s)", regnames[A]); |
| 768 | | output += sprintf( output, "SRC1(%s)", regnames[breg]); |
| 769 | | output += sprintf( output, "SRC2(%s)", regnames[C]); |
| 770 | 705 | |
| 771 | | |
| 772 | 706 | |
| 773 | 707 | |
| 774 | | return size; |
| 775 | | |
| 776 | 708 | |
| 777 | | |
| 778 | | } |
| 779 | | |
| 780 | | int arcompact_handle04_30_dasm(DASM_OPS_32) { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,0,0); } |
| 781 | | // ZZ value of 0x0 with X of 1 is illegal |
| 782 | | int arcompact_handle04_31_dasm(DASM_OPS_32) { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,0,1); } |
| 783 | | int arcompact_handle04_32_dasm(DASM_OPS_32) { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,1,0); } |
| 784 | | int arcompact_handle04_33_dasm(DASM_OPS_32) { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,1,1); } |
| 785 | | int arcompact_handle04_34_dasm(DASM_OPS_32) { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,2,0); } |
| 786 | | int arcompact_handle04_35_dasm(DASM_OPS_32) { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,2,1); } |
| 787 | | // ZZ value of 0x3 is illegal |
| 788 | | int arcompact_handle04_36_dasm(DASM_OPS_32) { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,3,0); } |
| 789 | | int arcompact_handle04_37_dasm(DASM_OPS_32) { return arcompact_handle04_3x_helper_dasm(output,pc,op,oprom,3,1); } |
| 790 | | |
| 791 | | |
| 792 | | |
| 793 | | |
| 794 | | |
| 795 | | |
| 796 | 709 | int arcompact_handle05_00_dasm(DASM_OPS_32) { print("ASL a <- b asl c (%08x)", op); return 4;} |
| 797 | 710 | int arcompact_handle05_01_dasm(DASM_OPS_32) { print("LSR a <- b lsr c (%08x)", op); return 4;} |
| 798 | 711 | int arcompact_handle05_02_dasm(DASM_OPS_32) { print("ASR a <- b asr c (%08x)", op); return 4;} |
trunk/src/mess/drivers/vt240.c
| r242371 | r242372 | |
| 18 | 18 | ****************************************************************************/ |
| 19 | 19 | |
| 20 | 20 | #include "emu.h" |
| 21 | |
| 22 | #include "bus/rs232/rs232.h" |
| 21 | 23 | #include "cpu/i8085/i8085.h" |
| 22 | 24 | #include "cpu/t11/t11.h" |
| 25 | #include "machine/clock.h" |
| 26 | #include "machine/dec_lk201.h" |
| 27 | #include "machine/i8251.h" |
| 28 | #include "machine/mc68681.h" |
| 29 | #include "machine/ms7004.h" |
| 23 | 30 | #include "machine/ram.h" |
| 24 | 31 | #include "video/upd7220.h" |
| 25 | 32 | |
| 33 | #define VERBOSE_DBG 1 /* general debug messages */ |
| 26 | 34 | |
| 35 | #define DBG_LOG(N,M,A) \ |
| 36 | do { \ |
| 37 | if(VERBOSE_DBG>=N) \ |
| 38 | { \ |
| 39 | logerror("%11.6f at %s: ",machine().time().as_double(),machine().describe_context()); \ |
| 40 | logerror A; \ |
| 41 | } \ |
| 42 | } while (0) |
| 43 | |
| 27 | 44 | class vt240_state : public driver_device |
| 28 | 45 | { |
| 29 | 46 | public: |
| 30 | 47 | vt240_state(const machine_config &mconfig, device_type type, const char *tag) |
| 31 | 48 | : driver_device(mconfig, type, tag), |
| 32 | 49 | m_maincpu(*this, "maincpu"), |
| 50 | m_i8251(*this, "i8251"), |
| 51 | m_duart(*this, "duart"), |
| 33 | 52 | m_hgdc(*this, "upd7220"), |
| 34 | 53 | m_video_ram(*this, "video_ram"){ } |
| 35 | 54 | |
| 36 | 55 | required_device<cpu_device> m_maincpu; |
| 56 | |
| 57 | required_device<i8251_device> m_i8251; |
| 58 | DECLARE_WRITE_LINE_MEMBER(write_keyboard_clock); |
| 59 | |
| 60 | required_device<mc68681_device> m_duart; |
| 61 | |
| 37 | 62 | required_device<upd7220_device> m_hgdc; |
| 38 | 63 | DECLARE_READ8_MEMBER( test_r ); |
| 39 | 64 | DECLARE_READ8_MEMBER( pcg_r ); |
| r242371 | r242372 | |
| 44 | 69 | //UINT8 *m_char_rom; |
| 45 | 70 | |
| 46 | 71 | required_shared_ptr<UINT16> m_video_ram; |
| 72 | |
| 47 | 73 | DECLARE_DRIVER_INIT(vt240); |
| 48 | 74 | virtual void machine_reset(); |
| 49 | 75 | INTERRUPT_GEN_MEMBER(vt240_irq); |
| 50 | 76 | UPD7220_DRAW_TEXT_LINE_MEMBER( hgdc_draw_text ); |
| 51 | 77 | }; |
| 52 | 78 | |
| 79 | WRITE_LINE_MEMBER(vt240_state::write_keyboard_clock) |
| 80 | { |
| 81 | m_i8251->write_txc(state); |
| 82 | m_i8251->write_rxc(state); |
| 83 | } |
| 84 | |
| 53 | 85 | /* TODO */ |
| 54 | 86 | UPD7220_DRAW_TEXT_LINE_MEMBER( vt240_state::hgdc_draw_text ) |
| 55 | 87 | { |
| r242371 | r242372 | |
| 101 | 133 | } |
| 102 | 134 | |
| 103 | 135 | |
| 104 | | static ADDRESS_MAP_START(vt240_mem, AS_PROGRAM, 8, vt240_state) |
| 136 | // PDF page 78 (4-25) |
| 137 | static ADDRESS_MAP_START( vt240_mem, AS_PROGRAM, 16, vt240_state ) |
| 105 | 138 | ADDRESS_MAP_UNMAP_HIGH |
| 106 | | AM_RANGE(0x0000, 0x3fff) AM_ROM AM_REGION("ipl", 0) |
| 107 | | AM_RANGE(0x4000, 0x5fff) AM_ROM AM_REGION("ipl", 0x8000) |
| 139 | AM_RANGE (0000000, 0077777) AM_ROM |
| 140 | // 0170xxx MEM MAP/8085 decoder |
| 141 | AM_RANGE (0171000, 0171003) AM_DEVREADWRITE8("i8251", i8251_device, data_r, data_w, 0x00ff) |
| 142 | AM_RANGE (0171004, 0171007) AM_DEVREADWRITE8("i8251", i8251_device, status_r, control_w, 0x00ff) |
| 143 | AM_RANGE (0172000, 0172077) AM_DEVREADWRITE8("duart", mc68681_device, read, write, 0xff) |
| 144 | // 0173000 Video logic |
| 145 | // 0174000 Video logic |
| 146 | // 017500x Video logic |
| 147 | // 0176xxx NVR |
| 148 | // 017700x System comm logic |
| 149 | ADDRESS_MAP_END |
| 150 | |
| 151 | // PDF page 134 (6-9) |
| 152 | static ADDRESS_MAP_START(vt240_char_mem, AS_PROGRAM, 8, vt240_state) |
| 153 | ADDRESS_MAP_UNMAP_HIGH |
| 154 | AM_RANGE(0x0000, 0x3fff) AM_ROM AM_REGION("charcpu", 0) |
| 155 | AM_RANGE(0x4000, 0x5fff) AM_ROM AM_REGION("charcpu", 0x8000) |
| 108 | 156 | AM_RANGE(0x8000, 0x87ff) AM_RAM |
| 109 | 157 | ADDRESS_MAP_END |
| 110 | 158 | |
| 111 | | static ADDRESS_MAP_START(vt240_io, AS_IO, 8, vt240_state) |
| 159 | static ADDRESS_MAP_START(vt240_char_io, AS_IO, 8, vt240_state) |
| 112 | 160 | ADDRESS_MAP_UNMAP_HIGH |
| 113 | 161 | ADDRESS_MAP_GLOBAL_MASK(0xff) |
| 114 | 162 | AM_RANGE(0x00, 0x01) AM_DEVREADWRITE("upd7220", upd7220_device, read, write) |
| r242371 | r242372 | |
| 135 | 183 | //device.execute().set_input_line(I8085_RST65_LINE, ASSERT_LINE); |
| 136 | 184 | } |
| 137 | 185 | |
| 138 | | static const gfx_layout vt240_chars_8x8 = |
| 186 | static const gfx_layout vt240_chars_8x10 = |
| 139 | 187 | { |
| 140 | 188 | 8,10, |
| 141 | 189 | RGN_FRAC(1,1), |
| r242371 | r242372 | |
| 143 | 191 | { 0 }, |
| 144 | 192 | { STEP8(0,1) }, |
| 145 | 193 | { 0*8, 1*8, 2*8, 3*8, 4*8, 5*8, 6*8, 7*8, 8*8, 9*8 }, |
| 146 | | 8*16 |
| 194 | 8*10 |
| 147 | 195 | }; |
| 148 | 196 | |
| 149 | 197 | static GFXDECODE_START( vt240 ) |
| 150 | | GFXDECODE_ENTRY( "ipl", 0x0000, vt240_chars_8x8, 0, 8 ) |
| 198 | GFXDECODE_ENTRY( "charcpu", 0x338*10-2, vt240_chars_8x10, 0, 8 ) |
| 151 | 199 | GFXDECODE_END |
| 152 | 200 | |
| 153 | | static MACHINE_CONFIG_START( vt240, vt240_state ) |
| 154 | | /* basic machine hardware */ |
| 155 | | MCFG_CPU_ADD("maincpu", I8085A, XTAL_16MHz / 4) |
| 201 | static MACHINE_CONFIG_FRAGMENT( vt240_motherboard ) |
| 202 | MCFG_CPU_ADD("maincpu", T11, XTAL_7_3728MHz) // confirm |
| 156 | 203 | MCFG_CPU_PROGRAM_MAP(vt240_mem) |
| 157 | | MCFG_CPU_IO_MAP(vt240_io) |
| 204 | MCFG_T11_INITIAL_MODE(5 << 13) |
| 205 | |
| 206 | /* |
| 207 | MCFG_CPU_ADD("charcpu", I8085A, XTAL_16MHz / 4) |
| 208 | MCFG_CPU_PROGRAM_MAP(vt240_char_mem) |
| 209 | MCFG_CPU_IO_MAP(vt240_char_io) |
| 158 | 210 | MCFG_CPU_VBLANK_INT_DRIVER("screen", vt240_state, vt240_irq) |
| 211 | */ |
| 159 | 212 | |
| 160 | | |
| 161 | | /* video hardware */ |
| 162 | 213 | MCFG_SCREEN_ADD("screen", RASTER) |
| 163 | 214 | MCFG_SCREEN_REFRESH_RATE(50) |
| 164 | 215 | MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */ |
| 165 | 216 | MCFG_SCREEN_SIZE(640, 480) |
| 166 | 217 | MCFG_SCREEN_VISIBLE_AREA(0, 640-1, 0, 480-1) |
| 167 | | // MCFG_VIDEO_START_OVERRIDE(vt240_state,vt240) |
| 218 | // MCFG_VIDEO_START_OVERRIDE(vt240_state,vt240) |
| 168 | 219 | MCFG_SCREEN_UPDATE_DEVICE("upd7220", upd7220_device, screen_update) |
| 169 | 220 | MCFG_PALETTE_ADD_BLACK_AND_WHITE("palette") |
| 170 | 221 | MCFG_GFXDECODE_ADD("gfxdecode", "palette", vt240) |
| r242371 | r242372 | |
| 172 | 223 | MCFG_DEVICE_ADD("upd7220", UPD7220, XTAL_4MHz / 4) |
| 173 | 224 | MCFG_DEVICE_ADDRESS_MAP(AS_0, upd7220_map) |
| 174 | 225 | MCFG_UPD7220_DRAW_TEXT_CALLBACK_OWNER(vt240_state, hgdc_draw_text) |
| 226 | |
| 227 | MCFG_MC68681_ADD("duart", XTAL_3_6864MHz) /* 2681 duart (not 68681!) */ |
| 228 | // MCFG_MC68681_IRQ_CALLBACK(WRITELINE(dectalk_state, dectalk_duart_irq_handler)) |
| 229 | MCFG_MC68681_A_TX_CALLBACK(DEVWRITELINE("rs232", rs232_port_device, write_txd)) |
| 230 | // MCFG_MC68681_B_TX_CALLBACK(WRITELINE(dectalk_state, dectalk_duart_txa)) |
| 231 | // MCFG_MC68681_INPORT_CALLBACK(READ8(dectalk_state, dectalk_duart_input)) |
| 232 | // MCFG_MC68681_OUTPORT_CALLBACK(WRITE8(dectalk_state, dectalk_duart_output)) |
| 233 | // MCFG_I8251_DTR_HANDLER(DEVWRITELINE("rs232", rs232_port_device, write_dtr)) |
| 234 | // MCFG_I8251_RTS_HANDLER(DEVWRITELINE("rs232", rs232_port_device, write_rts)) |
| 235 | |
| 236 | MCFG_RS232_PORT_ADD("rs232", default_rs232_devices, "null_modem") |
| 237 | MCFG_RS232_RXD_HANDLER(DEVWRITELINE("duart", mc68681_device, rx_a_w)) |
| 238 | // MCFG_RS232_DSR_HANDLER(DEVWRITELINE("duart", mc68681_device, ipX_w)) |
| 175 | 239 | MACHINE_CONFIG_END |
| 176 | 240 | |
| 241 | static MACHINE_CONFIG_START( mc7105, vt240_state ) |
| 242 | MCFG_FRAGMENT_ADD(vt240_motherboard) |
| 243 | |
| 244 | // serial connection to MS7004 keyboard |
| 245 | MCFG_DEVICE_ADD("i8251", I8251, 0) |
| 246 | // MCFG_I8251_RXRDY_HANDLER(DEVWRITELINE("pic8259", pic8259_device, ir1_w)) |
| 247 | |
| 248 | MCFG_DEVICE_ADD("ms7004", MS7004, 0) |
| 249 | MCFG_MS7004_TX_HANDLER(DEVWRITELINE("i8251", i8251_device, write_rxd)) |
| 250 | |
| 251 | // baud rate is supposed to be 4800 but keyboard is slightly faster |
| 252 | MCFG_DEVICE_ADD("keyboard_clock", CLOCK, 4960*16) |
| 253 | MCFG_CLOCK_SIGNAL_HANDLER(WRITELINE(vt240_state, write_keyboard_clock)) |
| 254 | MACHINE_CONFIG_END |
| 255 | |
| 177 | 256 | /* ROM definition */ |
| 178 | 257 | ROM_START( mc7105 ) |
| 179 | | ROM_REGION( 0x10000, "ipl", ROMREGION_ERASEFF ) |
| 258 | ROM_REGION( 0x10000, "charcpu", ROMREGION_ERASEFF ) |
| 180 | 259 | ROM_LOAD( "027.bin", 0x8000, 0x8000, CRC(a159b412) SHA1(956097ccc2652d494258b3682498cfd3096d7d4f)) |
| 181 | 260 | ROM_LOAD( "028.bin", 0x0000, 0x8000, CRC(b253151f) SHA1(22ffeef8eb5df3c38bfe91266f26d1e7822cdb53)) |
| 182 | 261 | |
| 183 | | ROM_REGION( 0x20000, "subcpu", ROMREGION_ERASEFF ) |
| 262 | ROM_REGION( 0x20000, "maincpu", ROMREGION_ERASEFF ) |
| 184 | 263 | ROM_LOAD16_BYTE( "029.bin", 0x00000, 0x8000, CRC(4a6db217) SHA1(47637325609ea19ffab61fe31e2700d72fa50729)) |
| 185 | 264 | ROM_LOAD16_BYTE( "031.bin", 0x00001, 0x8000, CRC(47129579) SHA1(39de9e2e26f90c5da5e72a09ff361c1a94b9008a)) |
| 186 | 265 | ROM_LOAD16_BYTE( "030.bin", 0x10000, 0x8000, CRC(05fd7b75) SHA1(2ad8c14e76accfa1b9b8748c58e9ebbc28844a47)) |
| r242371 | r242372 | |
| 190 | 269 | /* Driver */ |
| 191 | 270 | DRIVER_INIT_MEMBER(vt240_state,vt240) |
| 192 | 271 | { |
| 193 | | UINT8 *ROM = memregion("ipl")->base(); |
| 272 | UINT8 *ROM = memregion("charcpu")->base(); |
| 194 | 273 | |
| 195 | 274 | /* patch T11 check */ |
| 196 | 275 | ROM[0x09d] = 0x00; |
| 197 | 276 | ROM[0x09e] = 0x00; |
| 198 | 277 | ROM[0x09f] = 0x00; |
| 199 | 278 | |
| 200 | | /* ROM checksum*/ |
| 279 | /* ROM checksum */ |
| 201 | 280 | ROM[0x15c] = 0x00; |
| 202 | 281 | ROM[0x15d] = 0x00; |
| 203 | 282 | ROM[0x15e] = 0x00; |
| r242371 | r242372 | |
| 206 | 285 | /* YEAR NAME PARENT COMPAT MACHINE INPUT INIT COMPANY FULLNAME FLAGS */ |
| 207 | 286 | //COMP( 1983, vt240, 0, 0, vt220, vt220, driver_device, 0, "Digital Equipment Corporation", "VT240", GAME_NOT_WORKING | GAME_NO_SOUND) |
| 208 | 287 | //COMP( 1983, vt241, 0, 0, vt220, vt220, driver_device, 0, "Digital Equipment Corporation", "VT241", GAME_NOT_WORKING | GAME_NO_SOUND) |
| 209 | | COMP( 1983, mc7105, 0, 0, vt240, vt240, vt240_state, vt240, "Elektronika", "MC7105", GAME_NOT_WORKING | GAME_NO_SOUND) |
| 288 | COMP( 1983, mc7105, 0, 0, mc7105, vt240, vt240_state, vt240, "Elektronika", "MC7105", GAME_NOT_WORKING | GAME_NO_SOUND) |