Previous 15994 Revisions Next

r2180 Monday 31st March, 2008 at 07:40:32 UTC by Robbbert
[ZX] Removed machine->pens. Updated palette code. Marked all as NOT WORKING. Enabled testdrivers.
[src/mess]messdriv.c
[src/mess/drivers]zx.c
[src/mess/video]zx.c

src/mess/video/zx.c
r2179r2180
6363            r.min_x = old_x;
6464            r.max_x = new_x;
6565            r.min_y = r.max_y = y;
66            fillbitmap(bitmap, machine->pens[color], &r);
66            fillbitmap(bitmap, color, &r);
6767            break;
6868         }
6969         else
r2179r2180
7171            r.min_x = old_x;
7272            r.max_x = visarea->max_x;
7373            r.min_y = r.max_y = y;
74            fillbitmap(bitmap, machine->pens[color], &r);
74            fillbitmap(bitmap, color, &r);
7575            old_x = 0;
7676         }
7777         if (++y == height)
r2179r2180
107107   bitmap_t *bitmap = tmpbitmap;
108108
109109   r.min_y = r.max_y = video_screen_get_vpos(machine->primary_screen);
110   fillbitmap(bitmap, machine->pens[1], &r);
110   fillbitmap(bitmap, 1, &r);
111111   logerror("ULA %3d[%d] NMI, R:$%02X, $%04x\n", video_screen_get_vpos(machine->primary_screen), ula_scancode_count, (unsigned) cpunum_get_reg(0, Z80_R), (unsigned) cpunum_get_reg(0, Z80_PC));
112112   cpunum_set_input_line(machine, 0, INPUT_LINE_NMI, PULSE_LINE);
113113   if (++ula_scanline_count == height)
src/mess/messdriv.c
r2179r2180
418418   DRIVER( pc8300 )   /* Your Computer - PC8300                     */
419419   DRIVER( pow3000 )   /* Creon Enterprises - Power 3000               */
420420   DRIVER( lambda )   /* Lambda 8300                              */
421TESTDRIVER( h4th )      /* Sinclair ZX-81 Forth by David Husband         */
422TESTDRIVER( tree4th )   /* Sinclair ZX-81 Tree-Forth by Tree Systems      */
421   DRIVER( h4th )      /* Sinclair ZX-81 Forth by David Husband         */
422   DRIVER( tree4th )   /* Sinclair ZX-81 Tree-Forth by Tree Systems      */
423423
424424   DRIVER( spectrum )   /* 1982 ZX Spectrum                           */
425425   DRIVER( specpls4 )   /* 2000 ZX Spectrum +4                        */
src/mess/drivers/zx.c
r2179r2180
1919    hi-res and hi-res modes.
2020    Some memory packs are unemulated.
2121
22Current issues: 4th and tree4th need their address maps worked out (eg, the stack is set to FD80)
23      All drivers: Broken screen
24
25
2226****************************************************************************/
2327
2428#include "driver.h"
r2179r2180
334338
335339/* Palette Initialization */
336340
337static const unsigned char zx80_palette[] =
338{
339   255,255,255,   /* white */
340     0,  0,  0,   /* black */
341};
342341
343static const unsigned char zx81_palette[] =
344{
345   255,255,255,   /* white */
346     0,  0,  0,   /* black */
347};
348
349static const unsigned char ts1000_palette[] =
350{
351    64,244,244,   /* cyan */
352     0,  0,  0,   /* black */
353};
354
355342static PALETTE_INIT( zx80 )
356343{
357   int i;
358
359   for ( i = 0; i < sizeof(zx80_palette) / 3; i++ ) {
360      palette_set_color_rgb(machine, i, zx80_palette[i*3], zx80_palette[i*3+1], zx80_palette[i*3+2]);
361   }
344   palette_set_color(machine,0,RGB_WHITE); /* white */
345   palette_set_color(machine,1,RGB_BLACK); /* black */
346   palette_set_color(machine,2,RGB_BLACK); /* black */
347   palette_set_color(machine,3,RGB_WHITE); /* white */
362348}
363349
364static PALETTE_INIT( zx81 )
365{
366   int i;
367
368   for ( i = 0; i < sizeof(zx81_palette) / 3; i++ ) {
369      palette_set_color_rgb(machine, i, zx81_palette[i*3], zx81_palette[i*3+1], zx81_palette[i*3+2]);
370   }
371}
372
373350static PALETTE_INIT( ts1000 )
374351{
375   int i;
376
377   for ( i = 0; i < sizeof(ts1000_palette) / 3; i++ ) {
378      palette_set_color_rgb(machine, i, ts1000_palette[i*3], ts1000_palette[i*3+1], ts1000_palette[i*3+2]);
379   }
352   palette_set_color(machine,0,MAKE_RGB(64, 244, 244)); /* cyan */   
353   palette_set_color(machine,1,RGB_BLACK); /* black */
354   palette_set_color(machine,2,RGB_BLACK); /* black */
355   palette_set_color(machine,3,MAKE_RGB(64, 244, 244)); /* cyan */
380356}
381357
382358
383
384359#define ZX81_CPU_CLOCK         3250000
385360#define ZX81_CYCLES_PER_SCANLINE   207
386361#define ZX81_PIXELS_PER_SCANLINE   256
r2179r2180
434409   MDRV_MACHINE_RESET(zx81)
435410
436411   MDRV_GFXDECODE(zx81)
437   MDRV_PALETTE_INIT(zx81)
438412MACHINE_DRIVER_END
439413
440414static MACHINE_DRIVER_START( ts1000 )
r2179r2180
456430
457431   MDRV_MACHINE_RESET(pc8300)
458432   MDRV_GFXDECODE(pc8300)
459   MDRV_PALETTE_INIT(zx81)
433   MDRV_PALETTE_INIT(zx80)
460434MACHINE_DRIVER_END
461435
462436static MACHINE_DRIVER_START( pow3000 )
r2179r2180
467441
468442   MDRV_MACHINE_RESET(pc8300)
469443   MDRV_GFXDECODE(pow3000)
470   MDRV_PALETTE_INIT(zx81)
444   MDRV_PALETTE_INIT(zx80)
471445MACHINE_DRIVER_END
472446
473447/* ROMs */
r2179r2180
597571/* Game Drivers */
598572
599573/*    YEAR  NAME        PARENT  COMPAT  MACHINE     INPUT       INIT    CONFIG  COMPANY                     FULLNAME                                        FLAGS */
600COMP( 1980, zx80,       0,      0,      zx80,       zx80,       zx,     zx80,   "Sinclair Research",        "ZX-80",                                        0 )
601COMP( 1981, aszmic,     zx80,   0,      zx80,       zx80,       zx,     zx80,   "Sinclair Research",        "ZX.Aszmic",                                    0 )
602COMP( 1981, zx81,       0,      0,      zx81,       zx81,       zx,     zx81,   "Sinclair Research",        "ZX-81",                                        0 )
574COMP( 1980, zx80,       0,      0,      zx80,       zx80,       zx,     zx80,   "Sinclair Research",        "ZX-80",                                        GAME_NOT_WORKING )
575COMP( 1981, aszmic,     zx80,   0,      zx80,       zx80,       zx,     zx80,   "Sinclair Research",        "ZX.Aszmic",                                    GAME_NOT_WORKING )
576COMP( 1981, zx81,       0,      0,      zx81,       zx81,       zx,     zx81,   "Sinclair Research",        "ZX-81",                                        GAME_NOT_WORKING )
603577COMP( 198?, h4th,       zx81,   0,      zx81,       zx81,       zx,     zx81,   "Sinclair Research",        "Sinclair ZX-81 Forth by David Husband",        GAME_NOT_WORKING )
604578COMP( 198?, tree4th,    zx81,   0,      zx81,       zx81,       zx,     zx81,   "Sinclair Research",        "Sinclair ZX-81 Tree-Forth by Tree Systems",    GAME_NOT_WORKING )
605COMP( 1982, ts1000,     zx81,   0,      ts1000,     zx81,       zx,     zx81,   "Timex Sinclair",           "Timex Sinclair 1000",                          0 )
606COMP( 1984, pc8300,     zx81,   0,      pc8300,     pow3000,    zx,     pc8300, "Your Computer",            "PC8300",                                       0 )
607COMP( 1983, pow3000,    zx81,   0,      pow3000,    pow3000,    zx,     pc8300, "Creon Enterprises",        "Power 3000",                                   0 )
608COMP( 1982, lambda,     zx81,   0,      pc8300,     pow3000,    zx,     zx81,   "Lambda Electronics Ltd",   "Lambda 8300",                                  0 )
579COMP( 1982, ts1000,     zx81,   0,      ts1000,     zx81,       zx,     zx81,   "Timex Sinclair",           "Timex Sinclair 1000",                          GAME_NOT_WORKING )
580COMP( 1984, pc8300,     zx81,   0,      pc8300,     pow3000,    zx,     pc8300, "Your Computer",            "PC8300",                                       GAME_NOT_WORKING )
581COMP( 1983, pow3000,    zx81,   0,      pow3000,    pow3000,    zx,     pc8300, "Creon Enterprises",        "Power 3000",                                   GAME_NOT_WORKING )
582COMP( 1982, lambda,     zx81,   0,      pc8300,     pow3000,    zx,     zx81,   "Lambda Electronics Ltd",   "Lambda 8300",                                  GAME_NOT_WORKING )

Previous 15994 Revisions Next


© 1998-2018 The MESS Team