src/mess/drivers/smc777.c
| r8554 | r8555 | |
| 9 | 9 | guesses ... |
| 10 | 10 | - video emulation is just hacked up together to show something simple, |
| 11 | 11 | dunno yet how it really works. |
| 12 | - Drop M6845 support and write custom code in place of it. |
| 12 | 13 | |
| 13 | 14 | ****************************************************************************/ |
| 14 | 15 | |
| r8554 | r8555 | |
| 80 | 81 | static WRITE8_HANDLER( smc777_vram_w ) |
| 81 | 82 | { |
| 82 | 83 | static UINT8 *vram = memory_region(space->machine, "vram"); |
| 84 | static UINT16 vram_index; |
| 83 | 85 | |
| 84 | | vram[cursor_addr] = data; |
| 86 | vram_index = cpu_get_reg(devtag_get_device(space->machine, "maincpu"), Z80_B); |
| 87 | |
| 88 | vram[vram_index | offset*0x100] = data; |
| 85 | 89 | } |
| 86 | 90 | |
| 87 | 91 | static WRITE8_HANDLER( smc777_attr_w ) |
| 88 | 92 | { |
| 89 | 93 | static UINT8 *attr = memory_region(space->machine, "attr"); |
| 94 | static UINT16 vram_index; |
| 90 | 95 | |
| 91 | | attr[cursor_addr] = data; |
| 96 | vram_index = cpu_get_reg(devtag_get_device(space->machine, "maincpu"), Z80_B); |
| 97 | |
| 98 | attr[vram_index | offset*0x100] = data; |
| 92 | 99 | } |
| 93 | 100 | |
| 94 | 101 | static ADDRESS_MAP_START(smc777_mem, ADDRESS_SPACE_PROGRAM, 8) |
| r8554 | r8555 | |
| 167 | 174 | MDRV_SCREEN_REFRESH_RATE(50) |
| 168 | 175 | MDRV_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(2500)) /* not accurate */ |
| 169 | 176 | MDRV_SCREEN_FORMAT(BITMAP_FORMAT_INDEXED16) |
| 170 | | MDRV_SCREEN_SIZE(640, 480) |
| 171 | | MDRV_SCREEN_VISIBLE_AREA(0, 640-1, 0, 480-1) |
| 177 | MDRV_SCREEN_SIZE(640, 200) |
| 178 | MDRV_SCREEN_VISIBLE_AREA(0, 320-1, 0, 200-1) |
| 172 | 179 | MDRV_PALETTE_LENGTH(2) |
| 173 | 180 | MDRV_PALETTE_INIT(black_and_white) |
| 174 | 181 | MDRV_GFXDECODE(smc777) |