Previous 15994 Revisions Next

r1523 Wednesday 16th January, 2008 at 13:01:34 UTC by Dirk Best
[NASCOM1] Converted to use the common black and white palette
[src/mess/drivers]nascom1.c

src/mess/drivers/nascom1.c
r1522r1523
4949************************************************************************/
5050
5151#include "driver.h"
52#include "cpu/z80/z80.h"
5352#include "includes/nascom1.h"
53#include "cpu/z80/z80.h"
5454#include "devices/cartslot.h"
55#include "mslegacy.h"
5655
56
5757/* Memory w/r functions */
5858static ADDRESS_MAP_START( nascom1_mem , ADDRESS_SPACE_PROGRAM, 8)
5959   AM_RANGE(0x0000, 0x07ff) AM_ROM
r1522r1523
108108   GFXDECODE_ENTRY( REGION_GFX1, 0x0000, nascom2_charlayout, 0, 1 )
109109GFXDECODE_END
110110
111static const unsigned char nascom1_palette[] =
112{
113   0x00, 0x00, 0x00,   /* Black */
114   0xff, 0xff, 0xff   /* White */
115};
116111
117static const unsigned short nascom1_colortable[] =
118{
119   0, 1
120};
121
122static PALETTE_INIT( nascom1 )
123{
124   palette_set_colors_rgb(machine, 0, nascom1_palette, sizeof(nascom1_palette) / 3);
125   memcpy(colortable, nascom1_colortable, sizeof (nascom1_colortable));
126}
127
128112/* Keyboard input */
129113
130114static INPUT_PORTS_START (nascom1)
r1522r1523
226210   MDRV_CPU_VBLANK_INT(nascom_interrupt, 1)
227211   MDRV_SCREEN_REFRESH_RATE(50)
228212   MDRV_SCREEN_VBLANK_TIME(DEFAULT_REAL_60HZ_VBLANK_DURATION)
229   MDRV_INTERLEAVE(1)
230213
231214   MDRV_MACHINE_RESET( nascom1 )
232215
r1522r1523
236219   MDRV_SCREEN_SIZE(48 * 8, 16 * 16)
237220   MDRV_SCREEN_VISIBLE_AREA(0, 48 * 8 - 1, 0, 16 * 16 - 1)
238221   MDRV_GFXDECODE( nascom1 )
239   MDRV_PALETTE_LENGTH( sizeof (nascom1_palette) / 3 )
240   MDRV_COLORTABLE_LENGTH( sizeof (nascom1_colortable) )
241   MDRV_PALETTE_INIT( nascom1 )
222   MDRV_PALETTE_LENGTH(2)
223   MDRV_PALETTE_INIT(black_and_white)
242224
243225   MDRV_VIDEO_START( generic )
244226   MDRV_VIDEO_UPDATE( nascom1 )

Previous 15994 Revisions Next


© 1998-2018 The MESS Team