trunk/src/mess/drivers/cbm2.c
r18116 | r18117 | |
2 | 2 | |
3 | 3 | TODO: |
4 | 4 | |
5 | | - foreign keyboard inputs |
| 5 | - basic does not work |
| 6 | - shift lock |
| 7 | - Hungarian keyboard |
6 | 8 | - cbm620hu charom banking? |
7 | | - read VIC video RAM thru PLA |
8 | | - read VIC color RAM thru PLA |
| 9 | - read VIC video/color RAM thru PLA (Sphi2 = 1, AE = 0) |
9 | 10 | - user port |
10 | 11 | - co-processor bus |
11 | 12 | |
r18116 | r18117 | |
39 | 40 | //************************************************************************** |
40 | 41 | |
41 | 42 | //------------------------------------------------- |
42 | | // read_pla - |
| 43 | // read_pla - low profile PLA read |
43 | 44 | //------------------------------------------------- |
44 | 45 | |
45 | | void cbm2_state::read_pla(offs_t offset, int busy2, int eras, int ecas, int refen, int cas, int ras, int *casseg1, int *casseg2, int *casseg3, int *casseg4) |
| 46 | void cbm2_state::read_pla(offs_t offset, int ras, int cas, int refen, int eras, int ecas, int busy2, |
| 47 | int *casseg1, int *casseg2, int *casseg3, int *casseg4, int *rasseg1, int *rasseg2, int *rasseg3, int *rasseg4) |
46 | 48 | { |
47 | 49 | UINT32 input = P0 << 15 | P1 << 14 | P2 << 13 | P3 << 12 | busy2 << 11 | eras << 10 | ecas << 9 | refen << 8 | cas << 7 | ras << 6; |
48 | 50 | UINT32 data = m_pla1->read(input); |
49 | 51 | |
50 | 52 | *casseg1 = BIT(data, 0); |
51 | | //*rasseg1 = BIT(data, 1); |
52 | | //*rasseg2 = BIT(data, 2); |
| 53 | *rasseg1 = BIT(data, 1); |
| 54 | *rasseg2 = BIT(data, 2); |
53 | 55 | *casseg2 = BIT(data, 3); |
54 | | //*rasseg4 = BIT(data, 4); |
| 56 | *rasseg4 = BIT(data, 4); |
55 | 57 | *casseg4 = BIT(data, 5); |
56 | 58 | *casseg3 = BIT(data, 6); |
57 | | //*rasseg3 = BIT(data, 7); |
| 59 | *rasseg3 = BIT(data, 7); |
58 | 60 | } |
59 | 61 | |
60 | | void cbm2hp_state::read_pla(offs_t offset, int busy2, int eras, int ecas, int refen, int cas, int ras, int *casseg1, int *casseg2, int *casseg3, int *casseg4) |
| 62 | |
| 63 | //------------------------------------------------- |
| 64 | // read_pla - high profile PLA read |
| 65 | //------------------------------------------------- |
| 66 | |
| 67 | void cbm2hp_state::read_pla(offs_t offset, int ras, int cas, int refen, int eras, int ecas, int busy2, |
| 68 | int *casseg1, int *casseg2, int *casseg3, int *casseg4, int *rasseg1, int *rasseg2, int *rasseg3, int *rasseg4) |
61 | 69 | { |
62 | 70 | UINT32 input = ras << 13 | cas << 12 | refen << 11 | eras << 10 | ecas << 9 | busy2 << 8 | P3 << 3 | P2 << 2 | P1 << 1 | P0; |
63 | 71 | UINT32 data = m_pla1->read(input); |
r18116 | r18117 | |
66 | 74 | *casseg2 = BIT(data, 1); |
67 | 75 | *casseg3 = BIT(data, 2); |
68 | 76 | *casseg4 = BIT(data, 3); |
69 | | //*rasseg1 = BIT(data, 4); |
70 | | //*rasseg2 = BIT(data, 5); |
71 | | //*rasseg3 = BIT(data, 6); |
72 | | //*rasseg4 = BIT(data, 7); |
| 77 | *rasseg1 = BIT(data, 4); |
| 78 | *rasseg2 = BIT(data, 5); |
| 79 | *rasseg3 = BIT(data, 6); |
| 80 | *rasseg4 = BIT(data, 7); |
73 | 81 | } |
74 | 82 | |
75 | 83 | |
r18116 | r18117 | |
82 | 90 | int *diskromcs, int *csbank1, int *csbank2, int *csbank3, int *basiccs, int *knbcs, int *kernalcs, |
83 | 91 | int *crtccs, int *cs1, int *sidcs, int *extprtcs, int *ciacs, int *aciacs, int *tript1cs, int *tript2cs) |
84 | 92 | { |
85 | | this->read_pla(offset, busy2, eras, ecas, refen, cas, ras, casseg1, casseg2, casseg3, casseg4); |
| 93 | int rasseg1 = 1, rasseg2 = 1, rasseg3 = 1, rasseg4 = 1; |
86 | 94 | |
| 95 | this->read_pla(offset, ras, cas, refen, eras, ecas, busy2, casseg1, casseg2, casseg3, casseg4, &rasseg1, &rasseg2, &rasseg3, &rasseg4); |
| 96 | |
87 | 97 | int busen1 = m_dramon; |
88 | | int decoden = 0; // TODO |
| 98 | int decoden = 0; |
89 | 99 | *sysioen = !(P0 && P1 && P2 && P3) && busen1; |
90 | 100 | *dramen = !((!(P0 && P1 && P2 && P3)) && busen1); |
91 | 101 | |
r18116 | r18117 | |
164 | 174 | { |
165 | 175 | data = m_ram->pointer()[offset & 0xffff]; |
166 | 176 | } |
167 | | else if (!casseg2) |
| 177 | if (!casseg2) |
168 | 178 | { |
169 | 179 | data = m_ram->pointer()[0x10000 | (offset & 0xffff)]; |
170 | 180 | } |
171 | | else if (!casseg3 && (m_ram->size() > 0x20000)) |
| 181 | if (!casseg3 && (m_ram->size() > 0x20000)) |
172 | 182 | { |
173 | 183 | data = m_ram->pointer()[0x20000 | (offset & 0xffff)]; |
174 | 184 | } |
175 | | else if (!casseg4 && (m_ram->size() > 0x30000)) |
| 185 | if (!casseg4 && (m_ram->size() > 0x30000)) |
176 | 186 | { |
177 | 187 | data = m_ram->pointer()[0x30000 | (offset & 0xffff)]; |
178 | 188 | } |
r18116 | r18117 | |
184 | 194 | { |
185 | 195 | data = m_buffer_ram[offset & 0x7ff]; |
186 | 196 | } |
187 | | else if (!vidramcs) |
| 197 | if (!vidramcs) |
188 | 198 | { |
189 | 199 | data = m_video_ram[offset & 0x7ff]; |
190 | 200 | } |
191 | | else if (!basiccs || !knbcs) |
| 201 | if (!basiccs || !knbcs) |
192 | 202 | { |
193 | 203 | data = m_basic[offset & 0x3fff]; |
194 | 204 | } |
195 | | else if (!kernalcs) |
| 205 | if (!kernalcs) |
196 | 206 | { |
197 | 207 | data = m_kernal[offset & 0x1fff]; |
198 | 208 | } |
199 | | else if (!crtccs) |
| 209 | if (!crtccs) |
200 | 210 | { |
201 | 211 | if (A0) |
202 | 212 | { |
r18116 | r18117 | |
207 | 217 | data = m_crtc->status_r(space, 0); |
208 | 218 | } |
209 | 219 | } |
210 | | else if (!sidcs) |
| 220 | if (!sidcs) |
211 | 221 | { |
212 | 222 | data = m_sid->read(space, offset & 0x1f); |
213 | 223 | } |
214 | | else if (!ciacs) |
| 224 | if (!ciacs) |
215 | 225 | { |
216 | 226 | data = m_cia->read(space, offset & 0x0f); |
217 | 227 | } |
218 | | else if (!aciacs) |
| 228 | if (!aciacs) |
219 | 229 | { |
220 | 230 | data = m_acia->read(space, offset & 0x03); |
221 | 231 | } |
222 | | else if (!tript1cs) |
| 232 | if (!tript1cs) |
223 | 233 | { |
224 | 234 | data = m_tpi1->read(space, offset & 0x07); |
225 | 235 | } |
226 | | else if (!tript2cs) |
| 236 | if (!tript2cs) |
227 | 237 | { |
228 | 238 | data = m_tpi2->read(space, offset & 0x07); |
229 | 239 | } |
r18116 | r18117 | |
263 | 273 | { |
264 | 274 | m_ram->pointer()[offset & 0xffff] = data; |
265 | 275 | } |
266 | | else if (!casseg2) |
| 276 | if (!casseg2) |
267 | 277 | { |
268 | 278 | m_ram->pointer()[0x10000 | (offset & 0xffff)] = data; |
269 | 279 | } |
270 | | else if (!casseg3 && (m_ram->size() > 0x20000)) |
| 280 | if (!casseg3 && (m_ram->size() > 0x20000)) |
271 | 281 | { |
272 | 282 | m_ram->pointer()[0x20000 | (offset & 0xffff)] = data; |
273 | 283 | } |
274 | | else if (!casseg4 && (m_ram->size() > 0x30000)) |
| 284 | if (!casseg4 && (m_ram->size() > 0x30000)) |
275 | 285 | { |
276 | 286 | m_ram->pointer()[0x30000 | (offset & 0xffff)] = data; |
277 | 287 | } |
r18116 | r18117 | |
283 | 293 | { |
284 | 294 | m_buffer_ram[offset & 0x7ff] = data; |
285 | 295 | } |
286 | | else if (!vidramcs) |
| 296 | if (!vidramcs) |
287 | 297 | { |
288 | 298 | m_video_ram[offset & 0x7ff] = data; |
289 | 299 | } |
290 | | else if (!basiccs || !knbcs) |
| 300 | if (!basiccs || !knbcs) |
291 | 301 | { |
292 | 302 | m_basic[offset & 0x3fff] = data; |
293 | 303 | } |
294 | | else if (!kernalcs) |
| 304 | if (!kernalcs) |
295 | 305 | { |
296 | 306 | m_kernal[offset & 0x1fff] = data; |
297 | 307 | } |
298 | | else if (!crtccs) |
| 308 | if (!crtccs) |
299 | 309 | { |
300 | 310 | if (A0) |
301 | 311 | { |
r18116 | r18117 | |
306 | 316 | m_crtc->address_w(space, 0, data); |
307 | 317 | } |
308 | 318 | } |
309 | | else if (!sidcs) |
| 319 | if (!sidcs) |
310 | 320 | { |
311 | 321 | m_sid->write(space, offset & 0x1f, data); |
312 | 322 | } |
313 | | else if (!ciacs) |
| 323 | if (!ciacs) |
314 | 324 | { |
315 | 325 | m_cia->write(space, offset & 0x0f, data); |
316 | 326 | } |
317 | | else if (!aciacs) |
| 327 | if (!aciacs) |
318 | 328 | { |
319 | 329 | m_acia->write(space, offset & 0x03, data); |
320 | 330 | } |
321 | | else if (!tript1cs) |
| 331 | if (!tript1cs) |
322 | 332 | { |
323 | 333 | m_tpi1->write(space, offset & 0x07, data); |
324 | 334 | } |
325 | | else if (!tript2cs) |
| 335 | if (!tript2cs) |
326 | 336 | { |
327 | 337 | m_tpi2->write(space, offset & 0x07, data); |
328 | 338 | } |
r18116 | r18117 | |
333 | 343 | |
334 | 344 | |
335 | 345 | //------------------------------------------------- |
| 346 | // read_pla1 - P500 PLA #1 read |
| 347 | //------------------------------------------------- |
| 348 | |
| 349 | void p500_state::read_pla1(offs_t offset, int bras, int busy2, int sphi2, int clrnibcsb, int procvid, int refen, int ba, int aec, int srw, |
| 350 | int *datxen, int *dramxen, int *clrniben, int *segf, int *_64kcasen, int *casenb, int *viddaten, int *viddat_tr) |
| 351 | { |
| 352 | UINT32 input = P0 << 15 | P2 << 14 | bras << 13 | P1 << 12 | P3 << 11 | busy2 << 10 | m_statvid << 9 | sphi2 << 8 | |
| 353 | clrnibcsb << 7 | m_dramon << 6 | procvid << 5 | refen << 4 | m_vicdotsel << 3 | ba << 2 | aec << 1 | srw; |
| 354 | |
| 355 | UINT32 data = m_pla1->read(input); |
| 356 | |
| 357 | *datxen = BIT(data, 0); |
| 358 | *dramxen = BIT(data, 1); |
| 359 | *clrniben = BIT(data, 2); |
| 360 | *segf = BIT(data, 3); |
| 361 | *_64kcasen = BIT(data, 4); |
| 362 | *casenb = BIT(data, 5); |
| 363 | *viddaten = BIT(data, 6); |
| 364 | *viddat_tr = BIT(data, 7); |
| 365 | } |
| 366 | |
| 367 | |
| 368 | //------------------------------------------------- |
| 369 | // read_pla2 - P500 PLA #2 read |
| 370 | //------------------------------------------------- |
| 371 | |
| 372 | void p500_state::read_pla2(offs_t offset, offs_t va, int ba, int sphi2, int vicen, int ae, int segf, int bcas, int bank0, |
| 373 | int *clrnibcsb, int *extbufcs, int *discromcs, int *buframcs, int *charomcs, int *procvid, int *viccs, int *vidmatcs) |
| 374 | { |
| 375 | UINT32 input = VA12 << 15 | ba << 14 | A13 << 13 | A15 << 12 | A14 << 11 | A11 << 10 | A10 << 9 | A12 << 8 | |
| 376 | sphi2 << 7 | vicen << 6 | m_statvid << 5 | m_vicdotsel << 4 | ae << 3 | segf << 2 | bcas << 1 | bank0; |
| 377 | |
| 378 | UINT32 data = m_pla2->read(input); |
| 379 | |
| 380 | *clrnibcsb = BIT(data, 0); |
| 381 | *extbufcs = BIT(data, 1); |
| 382 | *discromcs = BIT(data, 2); |
| 383 | *buframcs = BIT(data, 3); |
| 384 | *charomcs = BIT(data, 4); |
| 385 | *procvid = BIT(data, 5); |
| 386 | *viccs = BIT(data, 6); |
| 387 | *vidmatcs = BIT(data, 7); |
| 388 | } |
| 389 | |
| 390 | |
| 391 | //------------------------------------------------- |
336 | 392 | // bankswitch - |
337 | 393 | //------------------------------------------------- |
338 | 394 | |
r18116 | r18117 | |
343 | 399 | int *cs1, int *sidcs, int *extprtcs, int *ciacs, int *aciacs, int *tript1cs, int *tript2cs, int *aec, int *vsysaden) |
344 | 400 | { |
345 | 401 | *aec = !((m_statvid || ae) && sphi2); |
| 402 | *vsysaden = sphi1 || ba; |
346 | 403 | |
347 | | int clrnibcsb = 1; |
348 | | int procvid = 1; |
| 404 | int clrnibcsb = 1, procvid = 1, segf = 1; |
349 | 405 | |
350 | | UINT32 input = P0 << 15 | P2 << 14 | bras << 13 | P1 << 12 | P3 << 11 | busy2 << 10 | m_statvid << 9 | sphi2 << 8 | |
351 | | clrnibcsb << 7 | m_dramon << 6 | procvid << 5 | refen << 4 | m_vicdotsel << 3 | ba << 2 | *aec << 1 | srw; |
352 | | UINT32 data = m_pla1->read(input); |
| 406 | read_pla1(offset, bras, busy2, sphi2, clrnibcsb, procvid, refen, ba, *aec, srw, |
| 407 | datxen, dramxen, clrniben, &segf, _64kcasen, casenb, viddaten, viddat_tr); |
353 | 408 | |
354 | | int segf = BIT(data, 3); |
355 | | |
356 | 409 | int bank0 = 1, vicen = 1; |
357 | 410 | |
358 | 411 | if (!*aec && !segf) |
r18116 | r18117 | |
386 | 439 | } |
387 | 440 | } |
388 | 441 | |
389 | | input = VA12 << 15 | ba << 14 | A13 << 13 | A15 << 12 | A14 << 11 | A11 << 10 | A10 << 9 | A12 << 8 | |
390 | | sphi2 << 7 | vicen << 6 | m_statvid << 5 | m_vicdotsel << 4 | ae << 3 | segf << 2 | bcas << 1 | bank0; |
391 | | data = m_pla2->read(input); |
| 442 | int vidmatcsb = 1; |
392 | 443 | |
393 | | clrnibcsb = BIT(data, 0); |
394 | | if (!bcas) *clrnibcs = clrnibcsb; |
395 | | *extbufcs = BIT(data, 1); |
396 | | *discromcs = BIT(data, 2); |
397 | | *buframcs = BIT(data, 3); |
398 | | *charomcs = BIT(data, 4); |
399 | | procvid = BIT(data, 5); |
400 | | *viccs = BIT(data, 6); |
401 | | if (!bcas) *vidmatcs = BIT(data, 7); |
| 444 | read_pla2(offset, va, ba, sphi2, vicen, ae, segf, bcas, bank0, |
| 445 | &clrnibcsb, extbufcs, discromcs, buframcs, charomcs, &procvid, viccs, &vidmatcsb); |
402 | 446 | |
403 | | input = P0 << 15 | P2 << 14 | bras << 13 | P1 << 12 | P3 << 11 | busy2 << 10 | m_statvid << 9 | sphi2 << 8 | |
404 | | clrnibcsb << 7 | m_dramon << 6 | procvid << 5 | refen << 4 | m_vicdotsel << 3 | ba << 2 | *aec << 1 | srw; |
405 | | data = m_pla1->read(input); |
| 447 | *clrnibcs = clrnibcsb || bcas; |
| 448 | *vidmatcs = vidmatcsb || bcas; |
406 | 449 | |
407 | | *datxen = BIT(data, 0); |
408 | | *dramxen = BIT(data, 1); |
409 | | *clrniben = BIT(data, 2); |
410 | | //*segf = BIT(data, 3); |
411 | | *_64kcasen = BIT(data, 4); |
412 | | *casenb = BIT(data, 5); |
413 | | *viddaten = BIT(data, 6); |
414 | | *viddat_tr = BIT(data, 7); |
415 | | |
416 | | *vsysaden = sphi1 || ba; |
| 450 | read_pla1(offset, bras, busy2, sphi2, clrnibcsb, procvid, refen, ba, *aec, srw, |
| 451 | datxen, dramxen, clrniben, &segf, _64kcasen, casenb, viddaten, viddat_tr); |
417 | 452 | } |
418 | 453 | |
419 | 454 | |
r18116 | r18117 | |
421 | 456 | // read_memory - |
422 | 457 | //------------------------------------------------- |
423 | 458 | |
424 | | UINT8 p500_state::read_memory(address_space &space, offs_t offset, offs_t va, int sphi0, int sphi1, int sphi2, int ba, int ae, int bras, int bcas) |
| 459 | UINT8 p500_state::read_memory(address_space &space, offs_t offset, offs_t va, int sphi0, int sphi1, int sphi2, int ba, int ae, int bras, int bcas, UINT8 *clrnib) |
425 | 460 | { |
426 | 461 | int srw = 1, busy2 = 1, refen = 0; |
427 | 462 | |
r18116 | r18117 | |
439 | 474 | /* |
440 | 475 | if (!space.debugger_access()) |
441 | 476 | logerror("r %05x %u %u %u %u %u %u %u - %u %u %u %u %u %u %u - %u %u %u %u %u %u - %u %u %u %u %u %u %u - %u %u : ", |
442 | | offset, datxen, dramxen, clrniben, _64kcasen, casenb, viddaten, viddat_tr, |
| 477 | va, datxen, dramxen, clrniben, _64kcasen, casenb, viddaten, viddat_tr, |
443 | 478 | clrnibcs, extbufcs, discromcs, buframcs, charomcs, viccs, vidmatcs, |
444 | 479 | csbank1, csbank2, csbank3, basiclocs, basichics, kernalcs, |
445 | 480 | cs1, sidcs, extprtcs, ciacs, aciacs, tript1cs, tript2cs, aec, vsysaden); |
446 | 481 | */ |
447 | 482 | UINT8 data = 0xff; |
| 483 | *clrnib = 0xf; |
448 | 484 | |
449 | | if (aec && !datxen && !_64kcasen) |
| 485 | if (vsysaden) |
450 | 486 | { |
451 | | data = m_ram->pointer()[offset & 0xffff]; |
452 | | //if (!space.debugger_access()) logerror("64K\n"); |
| 487 | if (!_64kcasen && !aec && !viddaten && !viddat_tr) |
| 488 | { |
| 489 | data = m_ram->pointer()[(m_vicbnksel << 14) | va]; |
| 490 | } |
| 491 | if (!clrnibcs) |
| 492 | { |
| 493 | *clrnib = m_color_ram[va & 0x3ff]; |
| 494 | } |
| 495 | if (!vidmatcs) |
| 496 | { |
| 497 | data = m_video_ram[va & 0x3ff]; |
| 498 | } |
| 499 | if (!charomcs) |
| 500 | { |
| 501 | data = m_charom[va & 0xfff]; |
| 502 | } |
453 | 503 | } |
454 | | else if (!aec && !viddaten && viddat_tr && !_64kcasen) |
| 504 | |
| 505 | if (clrniben) |
455 | 506 | { |
456 | | data = m_ram->pointer()[(m_vicbnksel << 14) | va]; |
457 | | //if (!space.debugger_access()) logerror("64K\n"); |
| 507 | if (!clrnibcs && !vsysaden) |
| 508 | { |
| 509 | data = m_color_ram[offset & 0x3ff]; |
| 510 | } |
458 | 511 | } |
459 | | else if (!dramxen && casenb && !P3) |
| 512 | |
| 513 | if (!dramxen) |
460 | 514 | { |
461 | | switch ((offset >> 15) & 0x07) |
| 515 | if (casenb) |
462 | 516 | { |
463 | | case 1: data = m_ram->pointer()[0x10000 + (offset & 0xffff)]; break; |
464 | | case 2: if (m_ram->size() > 0x20000) data = m_ram->pointer()[0x20000 + (offset & 0xffff)]; break; |
465 | | case 3: if (m_ram->size() > 0x30000) data = m_ram->pointer()[0x30000 + (offset & 0xffff)]; break; |
| 517 | switch (offset >> 16) |
| 518 | { |
| 519 | case 1: data = m_ram->pointer()[0x10000 + (offset & 0xffff)]; break; |
| 520 | case 2: if (m_ram->size() > 0x20000) data = m_ram->pointer()[0x20000 + (offset & 0xffff)]; break; |
| 521 | case 3: if (m_ram->size() > 0x30000) data = m_ram->pointer()[0x30000 + (offset & 0xffff)]; break; |
| 522 | } |
466 | 523 | } |
467 | | //if (!space.debugger_access()) logerror("CASEN\n"); |
468 | 524 | } |
469 | | else if (!datxen && !buframcs) |
| 525 | |
| 526 | if (!datxen) |
470 | 527 | { |
471 | | data = m_buffer_ram[offset & 0x7ff]; |
472 | | //if (!space.debugger_access()) logerror("BUFRAM\n"); |
| 528 | if (!_64kcasen && !aec) |
| 529 | { |
| 530 | data = m_ram->pointer()[offset & 0xffff]; |
| 531 | } |
| 532 | if (!buframcs) |
| 533 | { |
| 534 | data = m_buffer_ram[offset & 0x7ff]; |
| 535 | } |
| 536 | if (!vidmatcs && !vsysaden && !viddaten && viddat_tr) |
| 537 | { |
| 538 | data = m_video_ram[offset & 0x3ff]; |
| 539 | } |
| 540 | if (!basiclocs || !basichics) |
| 541 | { |
| 542 | data = m_basic[offset & 0x3fff]; |
| 543 | } |
| 544 | if (!kernalcs) |
| 545 | { |
| 546 | data = m_kernal[offset & 0x1fff]; |
| 547 | } |
| 548 | if (!charomcs && !vsysaden && !viddaten && viddat_tr) |
| 549 | { |
| 550 | data = m_charom[offset & 0xfff]; |
| 551 | } |
| 552 | if (!viccs && !viddaten && viddat_tr) |
| 553 | { |
| 554 | data = m_vic->read(space, offset & 0x3f); |
| 555 | } |
| 556 | if (!sidcs) |
| 557 | { |
| 558 | data = m_sid->read(space, offset & 0x1f); |
| 559 | } |
| 560 | if (!ciacs) |
| 561 | { |
| 562 | data = m_cia->read(space, offset & 0x0f); |
| 563 | } |
| 564 | if (!aciacs) |
| 565 | { |
| 566 | data = m_acia->read(space, offset & 0x03); |
| 567 | } |
| 568 | if (!tript1cs) |
| 569 | { |
| 570 | data = m_tpi1->read(space, offset & 0x07); |
| 571 | } |
| 572 | if (!tript2cs) |
| 573 | { |
| 574 | data = m_tpi2->read(space, offset & 0x07); |
| 575 | } |
| 576 | |
| 577 | data = m_exp->read(space, offset & 0x1fff, data, csbank1, csbank2, csbank3); |
473 | 578 | } |
474 | | else if (!vsysaden && clrniben && !clrnibcs) |
475 | | { |
476 | | data = m_color_ram[offset & 0x3ff]; |
477 | | //if (!space.debugger_access()) logerror("CLRNIB\n"); |
478 | | } |
479 | | else if (vsysaden && !clrnibcs) |
480 | | { |
481 | | data = m_color_ram[va & 0x3ff]; |
482 | | //if (!space.debugger_access()) logerror("CLRNIB\n"); |
483 | | } |
484 | | else if (!datxen && !vsysaden && !viddaten && viddat_tr && !vidmatcs) |
485 | | { |
486 | | data = m_video_ram[offset & 0x3ff]; |
487 | | //if (!space.debugger_access()) logerror("VIDMAT\n"); |
488 | | } |
489 | | else if (vsysaden && !vidmatcs) |
490 | | { |
491 | | data = m_video_ram[va & 0x3ff]; |
492 | | //if (!space.debugger_access()) logerror("VIDMAT\n"); |
493 | | } |
494 | | else if (!datxen && (!basiclocs || !basichics)) |
495 | | { |
496 | | data = m_basic[offset & 0x3fff]; |
497 | | //if (!space.debugger_access()) logerror("BASIC\n"); |
498 | | } |
499 | | else if (!datxen && !kernalcs) |
500 | | { |
501 | | data = m_kernal[offset & 0x1fff]; |
502 | | //if (!space.debugger_access()) logerror("KERNAL\n"); |
503 | | } |
504 | | else if (!datxen && !vsysaden && !viddaten && viddat_tr && !charomcs) |
505 | | { |
506 | | data = m_charom[offset & 0xfff]; |
507 | | //if (!space.debugger_access()) logerror("CHAROM\n"); |
508 | | } |
509 | | else if (vsysaden && !charomcs) |
510 | | { |
511 | | data = m_charom[va & 0xfff]; |
512 | | //if (!space.debugger_access()) logerror("CHAROM\n"); |
513 | | } |
514 | | else if (!datxen && !viddaten && viddat_tr && !viccs) |
515 | | { |
516 | | data = m_vic->read(space, offset & 0x3f); |
517 | | //if (!space.debugger_access()) logerror("VIC\n"); |
518 | | } |
519 | | else if (!datxen && !sidcs) |
520 | | { |
521 | | data = m_sid->read(space, offset & 0x1f); |
522 | | //if (!space.debugger_access()) logerror("SID\n"); |
523 | | } |
524 | | else if (!datxen && !ciacs) |
525 | | { |
526 | | data = m_cia->read(space, offset & 0x0f); |
527 | | //if (!space.debugger_access()) logerror("CIA\n"); |
528 | | } |
529 | | else if (!datxen && !aciacs) |
530 | | { |
531 | | data = m_acia->read(space, offset & 0x03); |
532 | | //if (!space.debugger_access()) logerror("ACIA\n"); |
533 | | } |
534 | | else if (!datxen && !tript1cs) |
535 | | { |
536 | | data = m_tpi1->read(space, offset & 0x07); |
537 | | //if (!space.debugger_access()) logerror("TPI1\n"); |
538 | | } |
539 | | else if (!datxen && !tript2cs) |
540 | | { |
541 | | data = m_tpi2->read(space, offset & 0x07); |
542 | | //if (!space.debugger_access()) logerror("TPI2\n"); |
543 | | } |
544 | | //else //if (!space.debugger_access()) logerror("\n"); |
545 | 579 | |
546 | | if (!datxen) data = m_exp->read(space, offset & 0x1fff, data, csbank1, csbank2, csbank3); |
547 | | |
548 | 580 | return data; |
549 | 581 | } |
550 | 582 | |
r18116 | r18117 | |
577 | 609 | csbank1, csbank2, csbank3, basiclocs, basichics, kernalcs, |
578 | 610 | cs1, sidcs, extprtcs, ciacs, aciacs, tript1cs, tript2cs, aec, vsysaden); |
579 | 611 | */ |
580 | | if (!aec && !datxen && !_64kcasen) |
| 612 | |
| 613 | if (clrniben) |
581 | 614 | { |
582 | | //if (!space.debugger_access()) logerror("64K RAM\n"); |
583 | | m_ram->pointer()[offset & 0xffff] = data; |
| 615 | if (!clrnibcs && !vsysaden) |
| 616 | { |
| 617 | m_color_ram[offset & 0x3ff] = data & 0x0f; |
| 618 | } |
584 | 619 | } |
585 | | else if (!dramxen && casenb && !P3) |
| 620 | |
| 621 | if (!dramxen) |
586 | 622 | { |
587 | | //if (!space.debugger_access()) logerror("CASENB\n"); |
588 | | switch ((offset >> 15) & 0x07) |
| 623 | if (casenb) |
589 | 624 | { |
590 | | case 1: m_ram->pointer()[0x10000 + (offset & 0xffff)] = data; break; |
591 | | case 2: if (m_ram->size() > 0x20000) m_ram->pointer()[0x20000 + (offset & 0xffff)] = data; break; |
592 | | case 3: if (m_ram->size() > 0x30000) m_ram->pointer()[0x30000 + (offset & 0xffff)] = data; break; |
| 625 | switch (offset >> 16) |
| 626 | { |
| 627 | case 1: m_ram->pointer()[0x10000 + (offset & 0xffff)] = data; break; |
| 628 | case 2: if (m_ram->size() > 0x20000) m_ram->pointer()[0x20000 + (offset & 0xffff)] = data; break; |
| 629 | case 3: if (m_ram->size() > 0x30000) m_ram->pointer()[0x30000 + (offset & 0xffff)] = data; break; |
| 630 | } |
593 | 631 | } |
594 | 632 | } |
595 | | else if (!datxen && !buframcs) |
| 633 | |
| 634 | if (!datxen) |
596 | 635 | { |
597 | | //if (!space.debugger_access()) logerror("BUFRAM\n"); |
598 | | m_buffer_ram[offset & 0x7ff] = data; |
| 636 | if (!_64kcasen && !aec) |
| 637 | { |
| 638 | m_ram->pointer()[offset & 0xffff] = data; |
| 639 | } |
| 640 | if (!buframcs) |
| 641 | { |
| 642 | m_buffer_ram[offset & 0x7ff] = data; |
| 643 | } |
| 644 | if (!vidmatcs && !vsysaden && !viddaten && !viddat_tr) |
| 645 | { |
| 646 | m_video_ram[offset & 0x3ff] = data; |
| 647 | } |
| 648 | if (!viccs && !viddaten && !viddat_tr) |
| 649 | { |
| 650 | m_vic->write(space, offset & 0x3f, data); |
| 651 | } |
| 652 | if (!sidcs) |
| 653 | { |
| 654 | m_sid->write(space, offset & 0x1f, data); |
| 655 | } |
| 656 | if (!ciacs) |
| 657 | { |
| 658 | m_cia->write(space, offset & 0x0f, data); |
| 659 | } |
| 660 | if (!aciacs) |
| 661 | { |
| 662 | m_acia->write(space, offset & 0x03, data); |
| 663 | } |
| 664 | if (!tript1cs) |
| 665 | { |
| 666 | m_tpi1->write(space, offset & 0x07, data); |
| 667 | } |
| 668 | if (!tript2cs) |
| 669 | { |
| 670 | m_tpi2->write(space, offset & 0x07, data); |
| 671 | } |
| 672 | |
| 673 | m_exp->write(space, offset & 0x1fff, data, csbank1, csbank2, csbank3); |
599 | 674 | } |
600 | | else if (!vsysaden && clrniben && !clrnibcs) |
601 | | { |
602 | | //if (!space.debugger_access()) logerror("CLRNIB\n"); |
603 | | m_color_ram[offset & 0x3ff] = data; |
604 | | } |
605 | | else if (!datxen && !vsysaden && !viddaten && !viddat_tr && !vidmatcs) |
606 | | { |
607 | | //if (!space.debugger_access()) logerror("VIDMAT\n"); |
608 | | m_video_ram[offset & 0x3ff] = data; |
609 | | } |
610 | | else if (vsysaden && !vidmatcs) |
611 | | { |
612 | | //if (!space.debugger_access()) logerror("VIDMAT\n"); |
613 | | m_video_ram[va & 0x3ff] = data; |
614 | | } |
615 | | else if (!datxen && !viddaten && !viddat_tr && !viccs) |
616 | | { |
617 | | //if (!space.debugger_access()) logerror("VIC\n"); |
618 | | m_vic->write(space, offset & 0x3f, data); |
619 | | } |
620 | | else if (!datxen && !sidcs) |
621 | | { |
622 | | //if (!space.debugger_access()) logerror("SID\n"); |
623 | | m_sid->write(space, offset & 0x1f, data); |
624 | | } |
625 | | else if (!datxen && !ciacs) |
626 | | { |
627 | | //if (!space.debugger_access()) logerror("CIA\n"); |
628 | | m_cia->write(space, offset & 0x0f, data); |
629 | | } |
630 | | else if (!datxen && !aciacs) |
631 | | { |
632 | | //if (!space.debugger_access()) logerror("ACIA\n"); |
633 | | m_acia->write(space, offset & 0x03, data); |
634 | | } |
635 | | else if (!datxen && !tript1cs) |
636 | | { |
637 | | //if (!space.debugger_access()) logerror("TPI1\n"); |
638 | | m_tpi1->write(space, offset & 0x07, data); |
639 | | } |
640 | | else if (!datxen && !tript2cs) |
641 | | { |
642 | | //if (!space.debugger_access()) logerror("TPI2\n"); |
643 | | m_tpi2->write(space, offset & 0x07, data); |
644 | | } |
645 | | //else //if (!space.debugger_access()) logerror("\n"); |
646 | | |
647 | | if (!datxen) m_exp->write(space, offset & 0x1fff, data, csbank1, csbank2, csbank3); |
648 | 675 | } |
649 | 676 | |
650 | 677 | |
r18116 | r18117 | |
656 | 683 | { |
657 | 684 | int sphi0 = 1, sphi1 = 0, sphi2 = 1, ba = 0, ae = 1, bras = 1, bcas = 0; |
658 | 685 | offs_t va = 0xffff; |
| 686 | UINT8 clrnib = 0xf; |
659 | 687 | |
660 | | return read_memory(space, offset, va, sphi0, sphi1, sphi2, ba, ae, bras, bcas); |
| 688 | return read_memory(space, offset, va, sphi0, sphi1, sphi2, ba, ae, bras, bcas, &clrnib); |
661 | 689 | } |
662 | 690 | |
663 | 691 | |
r18116 | r18117 | |
679 | 707 | |
680 | 708 | READ8_MEMBER( p500_state::vic_videoram_r ) |
681 | 709 | { |
682 | | /* int sphi0 = 0, sphi1 = 1, sphi2 = 0, ba = 1, ae = 0, bras = 0, bcas = 0; |
| 710 | /* |
| 711 | int sphi0 = 0, sphi1 = 1, sphi2 = 0, ba = 1, ae = 0, bras = 0, bcas = 0; |
683 | 712 | offs_t va = offset; |
684 | 713 | |
685 | | return read_memory(space, 0, va, sphi0, sphi1, sphi2, ba, ae, bras, bcas);*/ |
| 714 | return read_memory(space, 0, va, sphi0, sphi1, sphi2, ba, ae, bras, bcas); |
| 715 | */ |
| 716 | /* |
| 717 | int ba = 1, ae = 0, bras = 1, bcas = 0; |
| 718 | UINT8 clrnib = 0xf; |
686 | 719 | |
687 | 720 | if (offset < 0x1000) |
688 | 721 | { |
| 722 | return read_memory(space, 0, offset, 0, 1, 0, ba, ae, bras, bcas, &clrnib); |
| 723 | } |
| 724 | else |
| 725 | { |
| 726 | return read_memory(space, 0, offset, 1, 0, 1, ba, ae, bras, bcas, &clrnib); |
| 727 | } |
| 728 | */ |
| 729 | |
| 730 | if (offset < 0x1000) |
| 731 | { |
689 | 732 | return m_charom[offset & 0xfff]; |
690 | 733 | } |
691 | 734 | else |
r18116 | r18117 | |
889 | 932 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("Keypad ENTER") PORT_CODE(KEYCODE_ENTER_PAD) PORT_CHAR(UCHAR_MAMEKEY(ENTER_PAD)) |
890 | 933 | PORT_BIT( 0x20, IP_ACTIVE_LOW, IPT_UNUSED ) |
891 | 934 | PORT_BIT( 0xc0, IP_ACTIVE_LOW, IPT_UNUSED ) |
| 935 | |
| 936 | PORT_START("LOCK") |
| 937 | PORT_BIT( 0x10, IP_ACTIVE_LOW, IPT_KEYBOARD ) PORT_NAME("SHIFT LOCK") PORT_CODE(KEYCODE_CAPSLOCK) PORT_CHAR(UCHAR_MAMEKEY(CAPSLOCK)) PORT_TOGGLE |
| 938 | PORT_BIT( 0xef, IP_ACTIVE_LOW, IPT_UNUSED ) |
892 | 939 | INPUT_PORTS_END |
893 | 940 | |
894 | 941 | |
r18116 | r18117 | |
1261 | 1308 | if (!BIT(m_tpi2_pa, 5)) data &= ioport("PA5")->read(); |
1262 | 1309 | if (!BIT(m_tpi2_pa, 6)) data &= ioport("PA6")->read(); |
1263 | 1310 | if (!BIT(m_tpi2_pa, 7)) data &= ioport("PA7")->read(); |
1264 | | if (!BIT(m_tpi2_pb, 0)) data &= ioport("PB0")->read(); |
| 1311 | if (!BIT(m_tpi2_pb, 0)) data &= ioport("PB0")->read() & ioport("LOCK")->read(); |
1265 | 1312 | if (!BIT(m_tpi2_pb, 1)) data &= ioport("PB1")->read(); |
1266 | 1313 | if (!BIT(m_tpi2_pb, 2)) data &= ioport("PB2")->read(); |
1267 | 1314 | if (!BIT(m_tpi2_pb, 3)) data &= ioport("PB3")->read(); |
r18116 | r18117 | |
1602 | 1649 | |
1603 | 1650 | MACHINE_START_MEMBER( cbm2_state, cbm2_ntsc ) |
1604 | 1651 | { |
1605 | | m_video_ram_size = 0x800; |
1606 | 1652 | m_ntsc = 1; |
1607 | 1653 | |
1608 | 1654 | MACHINE_START_CALL_MEMBER(cbm2); |
r18116 | r18117 | |
1615 | 1661 | |
1616 | 1662 | MACHINE_START_MEMBER( cbm2_state, cbm2_pal ) |
1617 | 1663 | { |
1618 | | m_video_ram_size = 0x800; |
1619 | 1664 | m_ntsc = 0; |
1620 | 1665 | |
1621 | 1666 | MACHINE_START_CALL_MEMBER(cbm2); |
r18116 | r18117 | |
1629 | 1674 | MACHINE_START_MEMBER( p500_state, p500 ) |
1630 | 1675 | { |
1631 | 1676 | m_video_ram_size = 0x400; |
1632 | | m_ntsc = 1; |
1633 | 1677 | |
1634 | 1678 | MACHINE_START_CALL_MEMBER(cbm2); |
1635 | 1679 | |
r18116 | r18117 | |
1642 | 1686 | |
1643 | 1687 | |
1644 | 1688 | //------------------------------------------------- |
| 1689 | // MACHINE_START( p500_ntsc ) |
| 1690 | //------------------------------------------------- |
| 1691 | |
| 1692 | MACHINE_START_MEMBER( p500_state, p500_ntsc ) |
| 1693 | { |
| 1694 | m_ntsc = 1; |
| 1695 | |
| 1696 | MACHINE_START_CALL_MEMBER(p500); |
| 1697 | } |
| 1698 | |
| 1699 | |
| 1700 | //------------------------------------------------- |
| 1701 | // MACHINE_START( p500_pal ) |
| 1702 | //------------------------------------------------- |
| 1703 | |
| 1704 | MACHINE_START_MEMBER( p500_state, p500_pal ) |
| 1705 | { |
| 1706 | m_ntsc = 0; |
| 1707 | |
| 1708 | MACHINE_START_CALL_MEMBER(p500); |
| 1709 | } |
| 1710 | |
| 1711 | |
| 1712 | //------------------------------------------------- |
1645 | 1713 | // MACHINE_RESET( cbm2 ) |
1646 | 1714 | //------------------------------------------------- |
1647 | 1715 | |
r18116 | r18117 | |
1689 | 1757 | //------------------------------------------------- |
1690 | 1758 | |
1691 | 1759 | static MACHINE_CONFIG_FRAGMENT( 128k ) |
1692 | | // internal ram |
1693 | 1760 | MCFG_RAM_ADD(RAM_TAG) |
1694 | 1761 | MCFG_RAM_DEFAULT_SIZE("128K") |
1695 | 1762 | MCFG_RAM_EXTRA_OPTIONS("256K") |
r18116 | r18117 | |
1701 | 1768 | //------------------------------------------------- |
1702 | 1769 | |
1703 | 1770 | static MACHINE_CONFIG_FRAGMENT( 256k ) |
1704 | | // internal ram |
1705 | 1771 | MCFG_RAM_ADD(RAM_TAG) |
1706 | 1772 | MCFG_RAM_DEFAULT_SIZE("256K") |
1707 | 1773 | MACHINE_CONFIG_END |
1708 | 1774 | |
1709 | 1775 | |
1710 | 1776 | //------------------------------------------------- |
1711 | | // MACHINE_CONFIG( p500 ) |
| 1777 | // MACHINE_CONFIG( p500_ntsc ) |
1712 | 1778 | //------------------------------------------------- |
1713 | 1779 | |
1714 | | static MACHINE_CONFIG_START( p500, p500_state ) |
1715 | | MCFG_MACHINE_START_OVERRIDE(p500_state, p500) |
| 1780 | static MACHINE_CONFIG_START( p500_ntsc, p500_state ) |
| 1781 | MCFG_MACHINE_START_OVERRIDE(p500_state, p500_ntsc) |
1716 | 1782 | MCFG_MACHINE_RESET_OVERRIDE(p500_state, p500) |
1717 | 1783 | |
1718 | 1784 | // basic hardware |
r18116 | r18117 | |
1738 | 1804 | MCFG_TPI6525_ADD(MOS6525_2_TAG, p500_tpi2_intf) |
1739 | 1805 | MCFG_ACIA6551_ADD(MOS6551A_TAG) |
1740 | 1806 | MCFG_MOS6526R1_ADD(MOS6526_TAG, VIC6567_CLOCK, 60, cia_intf) |
1741 | | MCFG_CBM_IEEE488_ADD(ieee488_intf, "sfd1001") |
| 1807 | MCFG_CBM_IEEE488_ADD(ieee488_intf, "c8050") |
1742 | 1808 | MCFG_PET_DATASSETTE_PORT_ADD(PET_DATASSETTE_PORT_TAG, datassette_intf, cbm_datassette_devices, NULL, NULL) |
1743 | 1809 | MCFG_VCS_CONTROL_PORT_ADD(CONTROL1_TAG, vcs_control_port_devices, NULL, NULL) |
1744 | 1810 | MCFG_VCS_CONTROL_PORT_ADD(CONTROL2_TAG, vcs_control_port_devices, NULL, NULL) |
r18116 | r18117 | |
1748 | 1814 | |
1749 | 1815 | // internal ram |
1750 | 1816 | MCFG_FRAGMENT_ADD(128k) |
| 1817 | |
| 1818 | // software list |
| 1819 | MCFG_SOFTWARE_LIST_ADD("flop_list", "p500_flop") |
| 1820 | MCFG_SOFTWARE_LIST_ADD("cart_list", "cbm2_cart") |
1751 | 1821 | MACHINE_CONFIG_END |
1752 | 1822 | |
1753 | 1823 | |
1754 | 1824 | //------------------------------------------------- |
| 1825 | // MACHINE_CONFIG( p500_pal ) |
| 1826 | //------------------------------------------------- |
| 1827 | |
| 1828 | static MACHINE_CONFIG_START( p500_pal, p500_state ) |
| 1829 | MCFG_MACHINE_START_OVERRIDE(p500_state, p500_pal) |
| 1830 | MCFG_MACHINE_RESET_OVERRIDE(p500_state, p500) |
| 1831 | |
| 1832 | // basic hardware |
| 1833 | MCFG_CPU_ADD(M6509_TAG, M6509, VIC6569_CLOCK) |
| 1834 | MCFG_CPU_PROGRAM_MAP(p500_mem) |
| 1835 | MCFG_QUANTUM_PERFECT_CPU(M6509_TAG) |
| 1836 | |
| 1837 | // video hardware |
| 1838 | MCFG_MOS6569_ADD(MOS6569_TAG, SCREEN_TAG, VIC6569_CLOCK, vic_intf, vic_videoram_map, vic_colorram_map) |
| 1839 | |
| 1840 | // sound hardware |
| 1841 | MCFG_SPEAKER_STANDARD_MONO("mono") |
| 1842 | MCFG_SOUND_ADD(MOS6851_TAG, SID6581, VIC6569_CLOCK) |
| 1843 | MCFG_SOUND_CONFIG(sid_intf) |
| 1844 | MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 1.00) |
| 1845 | MCFG_SOUND_ADD("dac", DAC, 0) |
| 1846 | MCFG_SOUND_ROUTE(ALL_OUTPUTS, "mono", 0.25) |
| 1847 | |
| 1848 | // devices |
| 1849 | MCFG_PLS100_ADD(PLA1_TAG) |
| 1850 | MCFG_PLS100_ADD(PLA2_TAG) |
| 1851 | MCFG_TPI6525_ADD(MOS6525_1_TAG, p500_tpi1_intf) |
| 1852 | MCFG_TPI6525_ADD(MOS6525_2_TAG, p500_tpi2_intf) |
| 1853 | MCFG_ACIA6551_ADD(MOS6551A_TAG) |
| 1854 | MCFG_MOS6526R1_ADD(MOS6526_TAG, VIC6569_CLOCK, 50, cia_intf) |
| 1855 | MCFG_CBM_IEEE488_ADD(ieee488_intf, "c8050") |
| 1856 | MCFG_PET_DATASSETTE_PORT_ADD(PET_DATASSETTE_PORT_TAG, datassette_intf, cbm_datassette_devices, NULL, NULL) |
| 1857 | MCFG_VCS_CONTROL_PORT_ADD(CONTROL1_TAG, vcs_control_port_devices, NULL, NULL) |
| 1858 | MCFG_VCS_CONTROL_PORT_ADD(CONTROL2_TAG, vcs_control_port_devices, NULL, NULL) |
| 1859 | MCFG_CBM2_EXPANSION_SLOT_ADD(CBM2_EXPANSION_SLOT_TAG, VIC6569_CLOCK, cbm2_expansion_cards, NULL, NULL) |
| 1860 | //MCFG_CBM2_USER_PORT_ADD(CBM2_USER_PORT_TAG, user_intf, cbm2_user_port_cards, NULL, NULL) |
| 1861 | //MCFG_CBM2_SYSTEM_PORT_ADD(CBM2_SYSTEM_PORT_TAG, system_intf, cbm2_system_port_cards, NULL, NULL) |
| 1862 | |
| 1863 | // internal ram |
| 1864 | MCFG_FRAGMENT_ADD(128k) |
| 1865 | |
| 1866 | // software list |
| 1867 | MCFG_SOFTWARE_LIST_ADD("flop_list", "p500_flop") |
| 1868 | MCFG_SOFTWARE_LIST_ADD("cart_list", "cbm2_cart") |
| 1869 | MACHINE_CONFIG_END |
| 1870 | |
| 1871 | |
| 1872 | //------------------------------------------------- |
1755 | 1873 | // MACHINE_CONFIG( cbm2lp_ntsc ) |
1756 | 1874 | //------------------------------------------------- |
1757 | 1875 | |
r18116 | r18117 | |
1789 | 1907 | MCFG_TPI6525_ADD(MOS6525_2_TAG, tpi2_intf) |
1790 | 1908 | MCFG_ACIA6551_ADD(MOS6551A_TAG) |
1791 | 1909 | MCFG_MOS6526R1_ADD(MOS6526_TAG, XTAL_18MHz/8, 60, cia_intf) |
1792 | | MCFG_CBM_IEEE488_ADD(ieee488_intf, "sfd1001") |
| 1910 | MCFG_CBM_IEEE488_ADD(ieee488_intf, "c8050") |
1793 | 1911 | MCFG_PET_DATASSETTE_PORT_ADD(PET_DATASSETTE_PORT_TAG, datassette_intf, cbm_datassette_devices, NULL, NULL) |
1794 | 1912 | MCFG_VCS_CONTROL_PORT_ADD(CONTROL1_TAG, vcs_control_port_devices, NULL, NULL) |
1795 | 1913 | MCFG_VCS_CONTROL_PORT_ADD(CONTROL2_TAG, vcs_control_port_devices, NULL, NULL) |
r18116 | r18117 | |
1798 | 1916 | //MCFG_CBM2_SYSTEM_PORT_ADD(CBM2_SYSTEM_PORT_TAG, system_intf, cbm2_system_port_cards, NULL, NULL) |
1799 | 1917 | |
1800 | 1918 | // software list |
| 1919 | MCFG_SOFTWARE_LIST_ADD("flop_list", "cbm2_flop") |
1801 | 1920 | MCFG_SOFTWARE_LIST_ADD("cart_list", "cbm2_cart") |
1802 | 1921 | MACHINE_CONFIG_END |
1803 | 1922 | |
r18116 | r18117 | |
1960 | 2079 | //************************************************************************** |
1961 | 2080 | |
1962 | 2081 | //------------------------------------------------- |
1963 | | // ROM( p500 ) |
| 2082 | // ROM( p500n ) |
1964 | 2083 | //------------------------------------------------- |
1965 | 2084 | |
1966 | | ROM_START( p500 ) |
| 2085 | ROM_START( p500n ) |
1967 | 2086 | ROM_REGION( 0x4000, "basic", 0 ) |
1968 | 2087 | ROM_DEFAULT_BIOS("r2") |
1969 | 2088 | ROM_SYSTEM_BIOS( 0, "r1", "Revision 1" ) |
r18116 | r18117 | |
1989 | 2108 | |
1990 | 2109 | |
1991 | 2110 | //------------------------------------------------- |
| 2111 | // ROM( p500p ) |
| 2112 | //------------------------------------------------- |
| 2113 | |
| 2114 | #define rom_p500p rom_p500n |
| 2115 | |
| 2116 | |
| 2117 | //------------------------------------------------- |
1992 | 2118 | // ROM( b500 ) |
1993 | 2119 | //------------------------------------------------- |
1994 | 2120 | |
r18116 | r18117 | |
2215 | 2341 | //************************************************************************** |
2216 | 2342 | |
2217 | 2343 | // YEAR NAME PARENT COMPAT MACHINE INPUT INIT COMPANY FULLNAME FLAGS |
2218 | | COMP( 1983, p500, 0, 0, p500, cbm2, driver_device, 0, "Commodore Business Machines", "P500 ~ C128-40 ~ PET-II (NTSC)", GAME_NOT_WORKING ) |
| 2344 | COMP( 1983, p500n, 0, 0, p500_ntsc, cbm2, driver_device, 0, "Commodore Business Machines", "P500 ~ C128-40 ~ PET-II (NTSC)", GAME_NOT_WORKING ) |
| 2345 | COMP( 1983, p500p, p500n, 0, p500_pal, cbm2, driver_device, 0, "Commodore Business Machines", "P500 ~ C128-40 ~ PET-II (PAL)", GAME_NOT_WORKING ) |
2219 | 2346 | |
2220 | | COMP( 1983, b500, p500, 0, b128, cbm2, driver_device, 0, "Commodore Business Machines", "B500 (NTSC)", GAME_NOT_WORKING ) |
2221 | | COMP( 1983, b128, p500, 0, b128, cbm2, driver_device, 0, "Commodore Business Machines", "B128 (NTSC)", GAME_NOT_WORKING ) |
2222 | | COMP( 1983, b256, p500, 0, b256, cbm2, driver_device, 0, "Commodore Business Machines", "B256 (NTSC)", GAME_NOT_WORKING ) |
2223 | | COMP( 1983, cbm610, p500, 0, cbm610, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 610 (PAL)", GAME_NOT_WORKING ) |
2224 | | COMP( 1983, cbm620, p500, 0, cbm620, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 620 (PAL)", GAME_NOT_WORKING ) |
2225 | | COMP( 1983, cbm620hu, p500, 0, cbm620, cbm2hu, driver_device, 0, "Commodore Business Machines", "CBM 620 (Hungary)", GAME_NOT_WORKING ) |
| 2347 | COMP( 1983, b500, p500n, 0, b128, cbm2, driver_device, 0, "Commodore Business Machines", "B500 (NTSC)", GAME_NOT_WORKING ) |
| 2348 | COMP( 1983, b128, p500n, 0, b128, cbm2, driver_device, 0, "Commodore Business Machines", "B128 (NTSC)", GAME_NOT_WORKING ) |
| 2349 | COMP( 1983, b256, p500n, 0, b256, cbm2, driver_device, 0, "Commodore Business Machines", "B256 (NTSC)", GAME_NOT_WORKING ) |
| 2350 | COMP( 1983, cbm610, p500n, 0, cbm610, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 610 (PAL)", GAME_NOT_WORKING ) |
| 2351 | COMP( 1983, cbm620, p500n, 0, cbm620, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 620 (PAL)", GAME_NOT_WORKING ) |
| 2352 | COMP( 1983, cbm620hu, p500n, 0, cbm620, cbm2hu, driver_device, 0, "Commodore Business Machines", "CBM 620 (Hungary)", GAME_NOT_WORKING ) |
2226 | 2353 | |
2227 | | COMP( 1983, b128hp, p500, 0, b128hp, cbm2, driver_device, 0, "Commodore Business Machines", "B128-80HP (NTSC)", GAME_NOT_WORKING ) |
2228 | | COMP( 1983, b256hp, p500, 0, b256hp, cbm2, driver_device, 0, "Commodore Business Machines", "B256-80HP (NTSC)", GAME_NOT_WORKING ) |
2229 | | COMP( 1983, bx256hp, p500, 0, bx256hp, cbm2, driver_device, 0, "Commodore Business Machines", "BX256-80HP (NTSC)", GAME_NOT_WORKING ) |
2230 | | COMP( 1983, cbm710, p500, 0, cbm710, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 710 (PAL)", GAME_NOT_WORKING ) |
2231 | | COMP( 1983, cbm720, p500, 0, cbm720, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 720 (PAL)", GAME_NOT_WORKING ) |
2232 | | COMP( 1983, cbm720sw, p500, 0, cbm720, cbm2sw, driver_device, 0, "Commodore Business Machines", "CBM 720 (Sweden/Finland)", GAME_NOT_WORKING ) |
2233 | | COMP( 1983, cbm730, p500, 0, cbm730, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 730 (PAL)", GAME_NOT_WORKING ) |
| 2354 | COMP( 1983, b128hp, p500n, 0, b128hp, cbm2, driver_device, 0, "Commodore Business Machines", "B128-80HP (NTSC)", GAME_NOT_WORKING ) |
| 2355 | COMP( 1983, b256hp, p500n, 0, b256hp, cbm2, driver_device, 0, "Commodore Business Machines", "B256-80HP (NTSC)", GAME_NOT_WORKING ) |
| 2356 | COMP( 1983, bx256hp, p500n, 0, bx256hp, cbm2, driver_device, 0, "Commodore Business Machines", "BX256-80HP (NTSC)", GAME_NOT_WORKING ) |
| 2357 | COMP( 1983, cbm710, p500n, 0, cbm710, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 710 (PAL)", GAME_NOT_WORKING ) |
| 2358 | COMP( 1983, cbm720, p500n, 0, cbm720, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 720 (PAL)", GAME_NOT_WORKING ) |
| 2359 | COMP( 1983, cbm720sw, p500n, 0, cbm720, cbm2sw, driver_device, 0, "Commodore Business Machines", "CBM 720 (Sweden/Finland)", GAME_NOT_WORKING ) |
| 2360 | COMP( 1983, cbm730, p500n, 0, cbm730, cbm2, driver_device, 0, "Commodore Business Machines", "CBM 730 (PAL)", GAME_NOT_WORKING ) |